[Pkg-php-commits] [php/debian-sid] Adapted (and removed upstream-applied) patches to php 5.3.5
Ondřej Surý
ondrej at sury.org
Wed Feb 16 15:12:46 UTC 2011
---
debian/patches/006-debian_quirks.patch | 10 +-
debian/patches/017-pread_pwrite_disable.patch | 8 +-
debian/patches/034-apache2_umask_fix.patch | 6 +-
debian/patches/036-fd_setsize_fix.patch | 14 +-
debian/patches/052-phpinfo_no_configure.patch | 2 +-
debian/patches/115-autoconf_ftbfs.patch | 6 +-
debian/patches/CVE-2010-2950.patch | 11 -
debian/patches/CVE-2010-3436.patch | 18 -
debian/patches/CVE-2010-3709.patch | 12 -
debian/patches/CVE-2010-3710.patch | 35 -
debian/patches/CVE-2010-3870.patch | 187 --
debian/patches/CVE-2010-4150.patch | 15 -
debian/patches/CVE-2010-4156.patch | 13 -
debian/patches/CVE-2010-4409.patch | 71 -
debian/patches/bug50481.patch | 27 -
debian/patches/bug52487.patch | 11 -
debian/patches/bug52573.patch | 15 -
debian/patches/bug52827.patch | 45 -
debian/patches/bug52843.patch | 11 -
debian/patches/bug52947.patch | 10 -
debian/patches/bug53070.patch | 20 +-
debian/patches/bug53323.patch | 22 -
debian/patches/crash_in_zip_extract.patch | 12 -
.../do-not-overwrite-GLOBALS-and-this.patch | 43 -
debian/patches/dont-gitclean-in-build.patch | 4 +-
.../fix-crash-if-aa-steps-are-invalid.patch | 4 +-
...x-for-NULL-deref-in-zend_language_scanner.patch | 13 -
.../patches/fix-infinite-loop-with-x87-cpu.patch | 24 -
...bug-when-passing-the-callback-as-variable.patch | 11 -
.../fix-memory-leak-inside-highlight_string.patch | 2509 +-------------------
.../fix-open_basedir-with-separator-r305698.patch | 21 -
...fix-segfault-when-extending-SplFixedArray.patch | 40 -
...columnName-segfaults-on-bad-column_number.patch | 57 -
debian/patches/fix_broken_sha2_test.patch | 1 -
debian/patches/fix_crash_in_GC.patch | 55 -
debian/patches/fpm-config.patch | 41 +-
debian/patches/fpm_gcc_atomics.patch | 31 -
debian/patches/gentoo/009_ob-memory-leaks.patch | 24 +-
debian/patches/libdb_is_-ldb | 6 +-
debian/patches/php-5.3.4-ini.patch | 30 -
.../patches/php-fpm-man-section-and-cleanup.patch | 18 +-
debian/patches/php_crypt_revamped.patch | 44 +-
debian/patches/qdbm-is-usr_include_qdbm.patch | 6 +-
.../reject-filenames-with-null-r305507.patch | 918 +-------
debian/patches/series | 30 -
debian/patches/session_save_path.patch | 8 +-
.../patches/shtool_mkdir_-p_-race-condition.patch | 8 +-
debian/patches/unaligned_memory_access.patch | 27 -
.../unaligned_memory_access_in_hash_tiger.c.patch | 13 -
debian/patches/use_embedded_timezonedb.patch | 10 +-
debian/patches/use_embedded_timezonedb_fixes.patch | 2 +-
debian/patches/use_system_crypt_fixes.patch | 2 +-
debian/patches/zend_int_overflow.patch | 42 +-
53 files changed, 170 insertions(+), 4453 deletions(-)
delete mode 100644 debian/patches/CVE-2010-2950.patch
delete mode 100644 debian/patches/CVE-2010-3436.patch
delete mode 100644 debian/patches/CVE-2010-3709.patch
delete mode 100644 debian/patches/CVE-2010-3710.patch
delete mode 100644 debian/patches/CVE-2010-3870.patch
delete mode 100644 debian/patches/CVE-2010-4150.patch
delete mode 100644 debian/patches/CVE-2010-4156.patch
delete mode 100644 debian/patches/CVE-2010-4409.patch
delete mode 100644 debian/patches/bug50481.patch
delete mode 100644 debian/patches/bug52487.patch
delete mode 100644 debian/patches/bug52573.patch
delete mode 100644 debian/patches/bug52827.patch
delete mode 100644 debian/patches/bug52843.patch
delete mode 100644 debian/patches/bug52947.patch
delete mode 100644 debian/patches/bug53323.patch
delete mode 100644 debian/patches/crash_in_zip_extract.patch
delete mode 100644 debian/patches/do-not-overwrite-GLOBALS-and-this.patch
delete mode 100644 debian/patches/fix-for-NULL-deref-in-zend_language_scanner.patch
delete mode 100644 debian/patches/fix-infinite-loop-with-x87-cpu.patch
delete mode 100644 debian/patches/fix-leaks-and-crash-bug-when-passing-the-callback-as-variable.patch
delete mode 100644 debian/patches/fix-open_basedir-with-separator-r305698.patch
delete mode 100644 debian/patches/fix-segfault-when-extending-SplFixedArray.patch
delete mode 100644 debian/patches/fix-sqlite3-columnName-segfaults-on-bad-column_number.patch
delete mode 100644 debian/patches/fix_crash_in_GC.patch
delete mode 100644 debian/patches/fpm_gcc_atomics.patch
delete mode 100644 debian/patches/php-5.3.4-ini.patch
delete mode 100644 debian/patches/unaligned_memory_access.patch
delete mode 100644 debian/patches/unaligned_memory_access_in_hash_tiger.c.patch
diff --git a/debian/patches/006-debian_quirks.patch b/debian/patches/006-debian_quirks.patch
index bb946ac..0f998d4 100644
--- a/debian/patches/006-debian_quirks.patch
+++ b/debian/patches/006-debian_quirks.patch
@@ -81,7 +81,7 @@ Last-Update: 2010-01-18
;
; Windows: "\path1;\path2"
;include_path = ".;c:\php\includes"
-@@ -938,53 +938,6 @@ default_socket_timeout = 60
+@@ -938,49 +938,6 @@ default_socket_timeout = 60
; If you only provide the name of the extension, PHP will look for it in its
; default extension directory.
;
@@ -93,8 +93,6 @@ Last-Update: 2010-01-18
-;
-;extension=php_bz2.dll
-;extension=php_curl.dll
--;extension=php_dba.dll
--;extension=php_exif.dll
-;extension=php_fileinfo.dll
-;extension=php_gd2.dll
-;extension=php_gettext.dll
@@ -104,8 +102,7 @@ Last-Update: 2010-01-18
-;extension=php_interbase.dll
-;extension=php_ldap.dll
-;extension=php_mbstring.dll
--;extension=php_ming.dll
--;extension=php_mssql.dll
+-;extension=php_exif.dll ; Must be after mbstring as it depends on it
-;extension=php_mysql.dll
-;extension=php_mysqli.dll
-;extension=php_oci8.dll ; Use with Oracle 10gR2 Instant Client
@@ -119,7 +116,6 @@ Last-Update: 2010-01-18
-;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
-;extension=php_snmp.dll
@@ -161,7 +157,7 @@ Last-Update: 2010-01-18
*** Pike version: $PIKE_VERSION"
--- a/sapi/cli/php.1.in
+++ b/sapi/cli/php.1.in
-@@ -309,13 +309,14 @@ Shows configuration for extension
+@@ -336,13 +336,14 @@ Shows configuration for extension
Show configuration file names
.SH FILES
.TP 15
diff --git a/debian/patches/017-pread_pwrite_disable.patch b/debian/patches/017-pread_pwrite_disable.patch
index 704cab4..2ab7adb 100644
--- a/debian/patches/017-pread_pwrite_disable.patch
+++ b/debian/patches/017-pread_pwrite_disable.patch
@@ -6,9 +6,9 @@ Bug-Debian: http://bugs.debian.org/261311
Forwarded: no
Last-Update: 2010-01-18
---- pkg-php.orig/acinclude.m4
-+++ pkg-php/acinclude.m4
-@@ -1219,7 +1219,7 @@ $1
+--- a/acinclude.m4
++++ b/acinclude.m4
+@@ -1224,7 +1224,7 @@ $1
}
],[
@@ -17,7 +17,7 @@ Last-Update: 2010-01-18
],[
ac_cv_pwrite=no
],[
-@@ -1248,7 +1248,7 @@ $1
+@@ -1253,7 +1253,7 @@ $1
exit(0);
}
],[
diff --git a/debian/patches/034-apache2_umask_fix.patch b/debian/patches/034-apache2_umask_fix.patch
index abb1173..6bee78c 100644
--- a/debian/patches/034-apache2_umask_fix.patch
+++ b/debian/patches/034-apache2_umask_fix.patch
@@ -9,7 +9,7 @@ Last-Update: 2010-01-18
--- a/sapi/apache2handler/sapi_apache2.c
+++ b/sapi/apache2handler/sapi_apache2.c
-@@ -455,6 +455,19 @@ static apr_status_t php_server_context_c
+@@ -469,6 +469,19 @@ static apr_status_t php_server_context_c
return APR_SUCCESS;
}
@@ -29,7 +29,7 @@ Last-Update: 2010-01-18
static int php_apache_request_ctor(request_rec *r, php_struct *ctx TSRMLS_DC)
{
char *content_length;
-@@ -646,6 +659,8 @@ zend_first_try {
+@@ -660,6 +673,8 @@ zend_first_try {
} else {
zend_file_handle zfd;
@@ -38,7 +38,7 @@ Last-Update: 2010-01-18
zfd.type = ZEND_HANDLE_FILENAME;
zfd.filename = (char *) r->filename;
zfd.free_filename = 0;
-@@ -657,6 +672,9 @@ zend_first_try {
+@@ -671,6 +686,9 @@ zend_first_try {
zend_execute_scripts(ZEND_INCLUDE TSRMLS_CC, NULL, 1, &zfd);
}
diff --git a/debian/patches/036-fd_setsize_fix.patch b/debian/patches/036-fd_setsize_fix.patch
index c740c07..7283126 100644
--- a/debian/patches/036-fd_setsize_fix.patch
+++ b/debian/patches/036-fd_setsize_fix.patch
@@ -3,10 +3,8 @@ Origin: vendor
Forwarded: no
Last-Update: 2010-01-18
-Index: php-5.3.3RC3/ext/sockets/sockets.c
-===================================================================
---- php-5.3.3RC3.orig/ext/sockets/sockets.c
-+++ php-5.3.3RC3/ext/sockets/sockets.c
+--- a/ext/sockets/sockets.c
++++ b/ext/sockets/sockets.c
@@ -720,6 +720,7 @@ static int php_sock_array_to_fd_set(zval
php_sock = (php_socket*) zend_fetch_resource(element TSRMLS_CC, -1, le_socket_name, NULL, 1, le_socket);
@@ -15,11 +13,9 @@ Index: php-5.3.3RC3/ext/sockets/sockets.c
PHP_SAFE_FD_SET(php_sock->bsd_socket, fds);
if (php_sock->bsd_socket > *max_fd) {
-Index: php-5.3.3RC3/ext/standard/streamsfuncs.c
-===================================================================
---- php-5.3.3RC3.orig/ext/standard/streamsfuncs.c
-+++ php-5.3.3RC3/ext/standard/streamsfuncs.c
-@@ -610,6 +610,8 @@ static int stream_array_to_fd_set(zval *
+--- a/ext/standard/streamsfuncs.c
++++ b/ext/standard/streamsfuncs.c
+@@ -628,6 +628,8 @@ static int stream_array_to_fd_set(zval *
* is not displayed.
* */
if (SUCCESS == php_stream_cast(stream, PHP_STREAM_AS_FD_FOR_SELECT | PHP_STREAM_CAST_INTERNAL, (void*)&this_fd, 1) && this_fd >= 0) {
diff --git a/debian/patches/052-phpinfo_no_configure.patch b/debian/patches/052-phpinfo_no_configure.patch
index 57c09c2..49ce73a 100644
--- a/debian/patches/052-phpinfo_no_configure.patch
+++ b/debian/patches/052-phpinfo_no_configure.patch
@@ -12,7 +12,7 @@ Last-Update: 2010-01-18
--- a/ext/standard/info.c
+++ b/ext/standard/info.c
-@@ -693,7 +693,7 @@ PHPAPI void php_print_info(int flag TSRM
+@@ -704,7 +704,7 @@ PHPAPI void php_print_info(int flag TSRM
#ifdef ARCHITECTURE
php_info_print_table_row(2, "Architecture", ARCHITECTURE);
#endif
diff --git a/debian/patches/115-autoconf_ftbfs.patch b/debian/patches/115-autoconf_ftbfs.patch
index a073a69..f345e0a 100644
--- a/debian/patches/115-autoconf_ftbfs.patch
+++ b/debian/patches/115-autoconf_ftbfs.patch
@@ -1,7 +1,7 @@
--- a/configure.in
+++ b/configure.in
@@ -1,7 +1,7 @@
- ## $Id: configure.in 295792 2010-03-03 16:36:07Z johannes $ -*- autoconf -*-
+ ## $Id: configure.in 307133 2011-01-05 16:35:33Z johannes $ -*- autoconf -*-
dnl ## Process this file with autoconf to produce a configure script.
-divert(1)
@@ -48,14 +48,14 @@
--- a/ext/standard/config.m4
+++ b/ext/standard/config.m4
@@ -1,6 +1,6 @@
- dnl $Id: config.m4 295350 2010-02-22 00:34:22Z pajoye $ -*- autoconf -*-
+ dnl $Id: config.m4 300511 2010-06-17 10:22:03Z pajoye $ -*- autoconf -*-
-divert(3)dnl
+dnl divert(3)dnl
dnl
dnl Check if flush should be called explicitly after buffered io
-@@ -333,7 +333,7 @@ dnl
+@@ -342,7 +342,7 @@ dnl
AC_CHECK_FUNCS(getcwd getwd asinh acosh atanh log1p hypot glob strfmon nice fpclass isinf isnan mempcpy strpncpy)
AC_FUNC_FNMATCH
diff --git a/debian/patches/CVE-2010-2950.patch b/debian/patches/CVE-2010-2950.patch
deleted file mode 100644
index ca9b051..0000000
--- a/debian/patches/CVE-2010-2950.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/ext/phar/stream.c 2010/08/20 15:44:57 302564
-+++ b/ext/phar/stream.c 2010/08/20 16:37:33 302565
-@@ -470,7 +470,7 @@
- if (stream->mode[0] == 'w' || (stream->mode[0] == 'r' && stream->mode[1] == '+')) {
- ret = phar_flush(((phar_entry_data *)stream->abstract)->phar, 0, 0, 0, &error TSRMLS_CC);
- if (error) {
-- php_stream_wrapper_log_error(stream->wrapper, REPORT_ERRORS TSRMLS_CC, error);
-+ php_stream_wrapper_log_error(stream->wrapper, REPORT_ERRORS TSRMLS_CC, "%s", error);
- efree(error);
- }
- return ret;
diff --git a/debian/patches/CVE-2010-3436.patch b/debian/patches/CVE-2010-3436.patch
deleted file mode 100644
index 0486615..0000000
--- a/debian/patches/CVE-2010-3436.patch
+++ /dev/null
@@ -1,18 +0,0 @@
---- a/main/fopen_wrappers.c
-+++ b/main/fopen_wrappers.c
-@@ -239,8 +239,13 @@ PHPAPI int php_check_specific_open_based
- #else
- if (strncmp(resolved_basedir, resolved_name, resolved_basedir_len) == 0) {
- #endif
-- /* File is in the right directory */
-- return 0;
-+ if (resolved_name_len > resolved_basedir_len &&
-+ resolved_name[resolved_basedir_len] != PHP_DIR_SEPARATOR) {
-+ return -1;
-+ } else {
-+ /* File is in the right directory */
-+ return 0;
-+ }
- } else {
- /* /openbasedir/ and /openbasedir are the same directory */
- if (resolved_basedir_len == (resolved_name_len + 1) && resolved_basedir[resolved_basedir_len - 1] == PHP_DIR_SEPARATOR) {
diff --git a/debian/patches/CVE-2010-3709.patch b/debian/patches/CVE-2010-3709.patch
deleted file mode 100644
index 540cc90..0000000
--- a/debian/patches/CVE-2010-3709.patch
+++ /dev/null
@@ -1,12 +0,0 @@
---- a/ext/zip/php_zip.c
-+++ b/ext/zip/php_zip.c
-@@ -1961,6 +1961,9 @@ static ZIPARCHIVE_METHOD(getArchiveComme
- }
-
- comment = zip_get_archive_comment(intern, &comment_len, (int)flags);
-+ if(comment==NULL) {
-+ RETURN_FALSE;
-+ }
- RETURN_STRINGL((char *)comment, (long)comment_len, 1);
- }
- /* }}} */
diff --git a/debian/patches/CVE-2010-3710.patch b/debian/patches/CVE-2010-3710.patch
deleted file mode 100644
index 29ac37d..0000000
--- a/debian/patches/CVE-2010-3710.patch
+++ /dev/null
@@ -1,35 +0,0 @@
---- /dev/null
-+++ b/ext/filter/tests/bug52929.phpt
-@@ -0,0 +1,18 @@
-+--TEST--
-+Bug #52929 (Segfault in filter_var with FILTER_VALIDATE_EMAIL with large amount of data)
-+--SKIPIF--
-+<?php if (!extension_loaded("filter")) die("skip"); ?>
-+--FILE--
-+<?php
-+var_dump(filter_var('valid at email.address', FILTER_VALIDATE_EMAIL));
-+
-+// Beyond the allowable limit for an e-mail address.
-+var_dump(filter_var('xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx at yyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyy.zz', FILTER_VALIDATE_EMAIL));
-+
-+// An invalid address likely to crash PHP due to stack exhaustion if it goes to
-+// the validation regex.
-+var_dump(filter_var(str_repeat('x', 8000), FILTER_VALIDATE_EMAIL));
-+--EXPECT--
-+string(19) "valid at email.address"
-+bool(false)
-+bool(false)
---- a/ext/filter/logical_filters.c
-+++ b/ext/filter/logical_filters.c
-@@ -531,6 +531,11 @@ void php_filter_validate_email(PHP_INPUT
- int matches;
-
-
-+ /* The maximum length of an e-mail address is 320 octets, per RFC 2821. */
-+ if (Z_STRLEN_P(value) > 320) {
-+ RETURN_VALIDATION_FAILED
-+ }
-+
- re = pcre_get_compiled_regex((char *)regexp, &pcre_extra, &preg_options TSRMLS_CC);
- if (!re) {
- RETURN_VALIDATION_FAILED
diff --git a/debian/patches/CVE-2010-3870.patch b/debian/patches/CVE-2010-3870.patch
deleted file mode 100644
index 758e894..0000000
--- a/debian/patches/CVE-2010-3870.patch
+++ /dev/null
@@ -1,187 +0,0 @@
---- a/ext/xml/xml.c
-+++ b/ext/xml/xml.c
-@@ -659,10 +659,111 @@ PHPAPI char *xml_utf8_encode(const char
- }
- /* }}} */
-
-+/* copied from trunk's implementation of get_next_char in ext/standard/html.c */
-+#define MB_FAILURE(pos, advance) do { \
-+ *cursor = pos + (advance); \
-+ *status = FAILURE; \
-+ return 0; \
-+} while (0)
-+
-+#define CHECK_LEN(pos, chars_need) ((str_len - (pos)) >= (chars_need))
-+#define utf8_lead(c) ((c) < 0x80 || ((c) >= 0xC2 && (c) <= 0xF4))
-+#define utf8_trail(c) ((c) >= 0x80 && (c) <= 0xBF)
-+
-+/* {{{ php_next_utf8_char
-+ */
-+static inline unsigned int php_next_utf8_char(
-+ const unsigned char *str,
-+ size_t str_len,
-+ size_t *cursor,
-+ int *status)
-+{
-+ size_t pos = *cursor;
-+ unsigned int this_char = 0;
-+ unsigned char c;
-+
-+ *status = SUCCESS;
-+
-+ if (!CHECK_LEN(pos, 1))
-+ MB_FAILURE(pos, 1);
-+
-+ /* We'll follow strategy 2. from section 3.6.1 of UTR #36:
-+ * "In a reported illegal byte sequence, do not include any
-+ * non-initial byte that encodes a valid character or is a leading
-+ * byte for a valid sequence.» */
-+ c = str[pos];
-+ if (c < 0x80) {
-+ this_char = c;
-+ pos++;
-+ } else if (c < 0xc2) {
-+ MB_FAILURE(pos, 1);
-+ } else if (c < 0xe0) {
-+ if (!CHECK_LEN(pos, 2))
-+ MB_FAILURE(pos, 1);
-+
-+ if (!utf8_trail(str[pos + 1])) {
-+ MB_FAILURE(pos, utf8_lead(str[pos + 1]) ? 1 : 2);
-+ }
-+ this_char = ((c & 0x1f) << 6) | (str[pos + 1] & 0x3f);
-+ if (this_char < 0x80) { /* non-shortest form */
-+ MB_FAILURE(pos, 2);
-+ }
-+ pos += 2;
-+ } else if (c < 0xf0) {
-+ size_t avail = str_len - pos;
-+
-+ if (avail < 3 ||
-+ !utf8_trail(str[pos + 1]) || !utf8_trail(str[pos + 2])) {
-+ if (avail < 2 || utf8_lead(str[pos + 1]))
-+ MB_FAILURE(pos, 1);
-+ else if (avail < 3 || utf8_lead(str[pos + 2]))
-+ MB_FAILURE(pos, 2);
-+ else
-+ MB_FAILURE(pos, 3);
-+ }
-+
-+ this_char = ((c & 0x0f) << 12) | ((str[pos + 1] & 0x3f) << 6) | (str[pos + 2] & 0x3f);
-+ if (this_char < 0x800) { /* non-shortest form */
-+ MB_FAILURE(pos, 3);
-+ } else if (this_char >= 0xd800 && this_char <= 0xdfff) { /* surrogate */
-+ MB_FAILURE(pos, 3);
-+ }
-+ pos += 3;
-+ } else if (c < 0xf5) {
-+ size_t avail = str_len - pos;
-+
-+ if (avail < 4 ||
-+ !utf8_trail(str[pos + 1]) || !utf8_trail(str[pos + 2]) ||
-+ !utf8_trail(str[pos + 3])) {
-+ if (avail < 2 || utf8_lead(str[pos + 1]))
-+ MB_FAILURE(pos, 1);
-+ else if (avail < 3 || utf8_lead(str[pos + 2]))
-+ MB_FAILURE(pos, 2);
-+ else if (avail < 4 || utf8_lead(str[pos + 3]))
-+ MB_FAILURE(pos, 3);
-+ else
-+ MB_FAILURE(pos, 4);
-+ }
-+
-+ this_char = ((c & 0x07) << 18) | ((str[pos + 1] & 0x3f) << 12) | ((str[pos + 2] & 0x3f) << 6) | (str[pos + 3] & 0x3f);
-+ if (this_char < 0x10000 || this_char > 0x10FFFF) { /* non-shortest form or outside range */
-+ MB_FAILURE(pos, 4);
-+ }
-+ pos += 4;
-+ } else {
-+ MB_FAILURE(pos, 1);
-+ }
-+
-+ *cursor = pos;
-+ return this_char;
-+}
-+/* }}} */
-+
-+
- /* {{{ xml_utf8_decode */
- PHPAPI char *xml_utf8_decode(const XML_Char *s, int len, int *newlen, const XML_Char *encoding)
- {
-- int pos = len;
-+ size_t pos = 0;
- char *newbuf = emalloc(len + 1);
- unsigned int c;
- char (*decoder)(unsigned short) = NULL;
-@@ -681,36 +782,15 @@ PHPAPI char *xml_utf8_decode(const XML_C
- newbuf[*newlen] = '\0';
- return newbuf;
- }
-- while (pos > 0) {
-- c = (unsigned char)(*s);
-- if (c >= 0xf0) { /* four bytes encoded, 21 bits */
-- if(pos-4 >= 0) {
-- c = ((s[0]&7)<<18) | ((s[1]&63)<<12) | ((s[2]&63)<<6) | (s[3]&63);
-- } else {
-- c = '?';
-- }
-- s += 4;
-- pos -= 4;
-- } else if (c >= 0xe0) { /* three bytes encoded, 16 bits */
-- if(pos-3 >= 0) {
-- c = ((s[0]&63)<<12) | ((s[1]&63)<<6) | (s[2]&63);
-- } else {
-- c = '?';
-- }
-- s += 3;
-- pos -= 3;
-- } else if (c >= 0xc0) { /* two bytes encoded, 11 bits */
-- if(pos-2 >= 0) {
-- c = ((s[0]&63)<<6) | (s[1]&63);
-- } else {
-- c = '?';
-- }
-- s += 2;
-- pos -= 2;
-- } else {
-- s++;
-- pos--;
-+
-+ while (pos < (size_t)len) {
-+ int status = FAILURE;
-+ c = php_next_utf8_char((const unsigned char*)s, (size_t) len, &pos, &status);
-+
-+ if (status == FAILURE || c > 0xFFU) {
-+ c = '?';
- }
-+
- newbuf[*newlen] = decoder ? decoder(c) : c;
- ++*newlen;
- }
---- /dev/null
-+++ b/ext/xml/tests/bug49687.phpt
-@@ -0,0 +1,24 @@
-+--TEST--
-+Bug #49687 Several utf8_decode deficiencies and vulnerabilities
-+--SKIPIF--
-+<?php
-+require_once("skipif.inc");
-+if (!extension_loaded('xml')) die ("skip xml extension not available");
-+?>
-+--FILE--
-+<?php
-+
-+$tests = array(
-+ "\x41\xC2\x3E\x42",
-+ "\xE3\x80\x22",
-+ "\x41\x98\xBA\x42\xE2\x98\x43\xE2\x98\xBA\xE2\x98",
-+);
-+foreach ($tests as $t) {
-+ echo bin2hex(utf8_decode($t)), "\n";
-+}
-+echo "Done.\n";
-+--EXPECT--
-+413f3e42
-+3f22
-+413f3f423f433f3f
-+Done.
diff --git a/debian/patches/CVE-2010-4150.patch b/debian/patches/CVE-2010-4150.patch
deleted file mode 100644
index 249286a..0000000
--- a/debian/patches/CVE-2010-4150.patch
+++ /dev/null
@@ -1,15 +0,0 @@
---- a/ext/imap/php_imap.c
-+++ b/ext/imap/php_imap.c
-@@ -1209,10 +1209,12 @@ static void php_imap_do_open(INTERNAL_FU
-
- if (IMAPG(imap_user)) {
- efree(IMAPG(imap_user));
-+ IMAPG(imap_user) = 0;
- }
-
- if (IMAPG(imap_password)) {
- efree(IMAPG(imap_password));
-+ IMAPG(imap_password) = 0;
- }
-
- /* local filename, need to perform open_basedir and safe_mode checks */
diff --git a/debian/patches/CVE-2010-4156.patch b/debian/patches/CVE-2010-4156.patch
deleted file mode 100644
index fc43ca5..0000000
--- a/debian/patches/CVE-2010-4156.patch
+++ /dev/null
@@ -1,13 +0,0 @@
---- a/ext/mbstring/libmbfl/mbfl/mbfilter.c 2010/03/12 04:55:37 296101
-+++ b/ext/mbstring/libmbfl/mbfl/mbfilter.c 2010/11/09 03:23:04 305214
-@@ -1397,6 +1397,10 @@
- start = string->val + from;
- end = start + (length & -4);
- } else if ((encoding->flag & MBFL_ENCTYPE_SBCS)) {
-+ if (from + length >= string->len) {
-+ length = string->len - from;
-+ }
-+
- start = string->val + from;
- end = start + length;
- } else if (encoding->mblen_table != NULL) {
diff --git a/debian/patches/CVE-2010-4409.patch b/debian/patches/CVE-2010-4409.patch
deleted file mode 100644
index 86eda13..0000000
--- a/debian/patches/CVE-2010-4409.patch
+++ /dev/null
@@ -1,71 +0,0 @@
---- a/ext/intl/dateformat/dateformat_attr.c
-+++ b/ext/intl/dateformat/dateformat_attr.c
-@@ -309,6 +309,7 @@ PHP_FUNCTION( datefmt_get_locale )
- DATE_FORMAT_METHOD_FETCH_OBJECT;
-
- loc = (char *)udat_getLocaleByType(DATE_FORMAT_OBJECT(dfo), loc_type,&INTL_DATA_ERROR_CODE(dfo));
-+ INTL_METHOD_CHECK_STATUS(dfo, "Error getting locale");
- RETURN_STRING(loc, 1);
- }
- /* }}} */
---- a/ext/intl/tests/dateformat_get_locale.phpt
-+++ b/ext/intl/tests/dateformat_get_locale.phpt
-@@ -29,6 +29,12 @@ function ut_main()
- $res_str .= "\nAfter call to get_locale : locale= $locale";
- $res_str .= "\n";
- }
-+ $badvals = array(100, -1, 4294901761);
-+ foreach($badvals as $badval) {
-+ if(ut_datefmt_get_locale($fmt, $badval)) {
-+ $res_str .= "datefmt_get_locale should return false for bad argument $badval\n";
-+ }
-+ }
-
- return $res_str;
-
---- a/ext/intl/tests/formatter_get_set_symbol.phpt
-+++ b/ext/intl/tests/formatter_get_set_symbol.phpt
-@@ -73,7 +73,12 @@ function ut_main()
- // Restore attribute's symbol.
- ut_nfmt_set_symbol( $fmt, $symb, $orig_val );
- }
--
-+ $badvals = array(2147483648, -2147483648, -1, 4294901761);
-+ foreach($badvals as $badval) {
-+ if(ut_nfmt_get_symbol( $fmt, 2147483648 )) {
-+ $res_str .= "Bad value $badval should return false!\n";
-+ }
-+ }
- return $res_str;
- }
-
---- a/ext/intl/formatter/formatter_attr.c
-+++ b/ext/intl/formatter/formatter_attr.c
-@@ -250,7 +250,7 @@ PHP_FUNCTION( numfmt_get_symbol )
- long symbol;
- UChar value_buf[4];
- UChar *value = value_buf;
-- int length = USIZE(value);
-+ int length = USIZE(value_buf);
- FORMATTER_METHOD_INIT_VARS;
-
- /* Parse parameters. */
-@@ -262,12 +262,17 @@ PHP_FUNCTION( numfmt_get_symbol )
-
- RETURN_FALSE;
- }
-+
-+ if(symbol >= UNUM_FORMAT_SYMBOL_COUNT || symbol < 0) {
-+ intl_error_set( NULL, U_ILLEGAL_ARGUMENT_ERROR, "numfmt_get_symbol: invalid symbol value", 0 TSRMLS_CC );
-+ RETURN_FALSE;
-+ }
-
- /* Fetch the object. */
- FORMATTER_METHOD_FETCH_OBJECT;
-
- length = unum_getSymbol(FORMATTER_OBJECT(nfo), symbol, value_buf, length, &INTL_DATA_ERROR_CODE(nfo));
-- if(INTL_DATA_ERROR_CODE(nfo) == U_BUFFER_OVERFLOW_ERROR && length >= USIZE( value )) {
-+ if(INTL_DATA_ERROR_CODE(nfo) == U_BUFFER_OVERFLOW_ERROR && length >= USIZE( value_buf )) {
- ++length; /* to avoid U_STRING_NOT_TERMINATED_WARNING */
- INTL_DATA_ERROR_CODE(nfo) = U_ZERO_ERROR;
- value = eumalloc(length);
diff --git a/debian/patches/bug50481.patch b/debian/patches/bug50481.patch
deleted file mode 100644
index 723e1d3..0000000
--- a/debian/patches/bug50481.patch
+++ /dev/null
@@ -1,27 +0,0 @@
---- a/ext/spl/spl_fixedarray.c
-+++ b/ext/spl/spl_fixedarray.c
-@@ -158,6 +158,9 @@ static HashTable* spl_fixedarray_object_
- zend_hash_index_update(intern->std.properties, 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(intern->std.properties, i, (void *)&EG(uninitialized_zval_ptr), sizeof(zval *), NULL);
- Z_ADDREF_P(EG(uninitialized_zval_ptr));
- }
---- /dev/null
-+++ b/ext/spl/tests/bug52573.phpt
-@@ -0,0 +1,12 @@
-+--TEST--
-+Bug #52573 (SplFileObject::fscanf Segmentation fault)
-+--FILE--
-+<?php
-+
-+$result = null;
-+$f = new SplFileObject(__FILE__, 'r');
-+$f->fscanf('<?php // %s', $result);
-+
-+?>
-+--EXPECTF--
-+Warning: Parameter 3 to fscanf() expected to be a reference, value given in %s on line 5
diff --git a/debian/patches/bug52487.patch b/debian/patches/bug52487.patch
deleted file mode 100644
index ec7eb3f..0000000
--- a/debian/patches/bug52487.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/ext/pdo/pdo_stmt.c 2010/07/29 22:07:00 301705
-+++ b/ext/pdo/pdo_stmt.c 2010/07/29 23:38:55 301706
-@@ -1887,7 +1887,7 @@
- switch (stmt->default_fetch_type) {
- case PDO_FETCH_INTO:
- if (stmt->fetch.into) {
-- Z_DELREF_P(stmt->fetch.into);
-+ zval_ptr_dtor(&stmt->fetch.into);
- stmt->fetch.into = NULL;
- }
- break;
diff --git a/debian/patches/bug52573.patch b/debian/patches/bug52573.patch
deleted file mode 100644
index e89b496..0000000
--- a/debian/patches/bug52573.patch
+++ /dev/null
@@ -1,15 +0,0 @@
---- a/ext/spl/spl_directory.c 2010/08/10 21:52:14 302084
-+++ b/ext/spl/spl_directory.c 2010/08/10 22:37:24 302085
-@@ -1862,7 +1862,11 @@
-
- result = zend_call_function(&fci, &fcic TSRMLS_CC);
-
-- ZVAL_ZVAL(return_value, retval, 1, 1);
-+ if (result == FAILURE) {
-+ RETVAL_FALSE;
-+ } else {
-+ ZVAL_ZVAL(return_value, retval, 1, 1);
-+ }
-
- efree(params);
- return result;
diff --git a/debian/patches/bug52827.patch b/debian/patches/bug52827.patch
deleted file mode 100644
index 03571d6..0000000
--- a/debian/patches/bug52827.patch
+++ /dev/null
@@ -1,45 +0,0 @@
---- a/ext/curl/interface.c
-+++ b/ext/curl/interface.c
-@@ -1816,7 +1816,6 @@ static int _php_curl_setopt(php_curl *ch
- }
- zval_add_ref(zvalue);
- ch->handlers->std_err = *zvalue;
-- zend_list_addref(Z_LVAL_PP(zvalue));
- } else {
- php_error_docref(NULL TSRMLS_CC, E_WARNING, "the provided file handle is not writable");
- RETVAL_FALSE;
---- /dev/null
-+++ b/ext/curl/tests/bug52827.phpt
-@@ -0,0 +1,32 @@
-+--TEST--
-+Bug #52827 (curl_setopt with CURLOPT_STDERR erroneously increments the resource refcount)
-+--SKIPIF--
-+<?php
-+
-+if (!extension_loaded('curl')) {
-+ exit("skip curl extension not loaded");
-+}
-+
-+?>
-+--FILE--
-+<?php
-+$s = fopen('php://temp/maxmemory=1024','wb+');
-+
-+/* force conversion of inner stream to STDIO.
-+ * This is not necessary in Windows because the
-+ * cast to a FILE* handle in curl_setopt already
-+ * forces the conversion in that platform. The
-+ * reason for this conversion is that the memory
-+ * stream has an ugly but working mechanism to
-+ * prevent being double freed when it's encapsulated,
-+ * while STDIO streams don't. */
-+$i = 0;
-+while ($i++ < 5000) {
-+fwrite($s, str_repeat('a',1024));
-+}
-+$handle=curl_init('http://www.example.com');
-+curl_setopt($handle, CURLOPT_STDERR, $s);
-+
-+echo "Done.";
-+--EXPECTF--
-+Done.
diff --git a/debian/patches/bug52843.patch b/debian/patches/bug52843.patch
deleted file mode 100644
index 8df705e..0000000
--- a/debian/patches/bug52843.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/ext/mssql/php_mssql.c
-+++ b/ext/mssql/php_mssql.c
-@@ -571,7 +571,7 @@ PHP_MINFO_FUNCTION(mssql)
- static void php_mssql_do_connect(INTERNAL_FUNCTION_PARAMETERS, int persistent)
- {
- char *host = NULL, *user = NULL, *passwd = NULL;
-- int host_len, user_len, passwd_len;
-+ int host_len = 0, user_len = 0, passwd_len = 0;
- zend_bool new_link = 0;
- char *hashed_details;
- int hashed_details_length;
diff --git a/debian/patches/bug52947.patch b/debian/patches/bug52947.patch
deleted file mode 100644
index d1aad12..0000000
--- a/debian/patches/bug52947.patch
+++ /dev/null
@@ -1,10 +0,0 @@
---- a/ext/openssl/xp_ssl.c 2010/09/29 00:55:43 303838
-+++ b/ext/openssl/xp_ssl.c 2010/09/29 01:25:35 303839
-@@ -502,7 +502,6 @@
- zend_list_insert(mycert,
- php_openssl_get_x509_list_id()));
- add_next_index_zval(arr, zcert);
-- FREE_ZVAL(zcert);
- }
-
- } else {
diff --git a/debian/patches/bug53070.patch b/debian/patches/bug53070.patch
index 056dfd5..8806700 100644
--- a/debian/patches/bug53070.patch
+++ b/debian/patches/bug53070.patch
@@ -1,20 +1,20 @@
---- a/ext/enchant/enchant.c 2010/10/16 17:30:27 304446
-+++ b/ext/enchant/enchant.c 2010/10/16 17:52:01 304447
-@@ -433,6 +433,8 @@
- if (!value_len) {
+--- a/ext/enchant/enchant.c
++++ b/ext/enchant/enchant.c
+@@ -429,6 +429,8 @@ PHP_FUNCTION(enchant_broker_set_dict_pat
+ if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rls", &broker, &dict_type, &value, &value_len) == FAILURE) {
RETURN_FALSE;
}
+
+ PHP_ENCHANT_GET_BROKER;
- switch (dict_type) {
- case PHP_ENCHANT_MYSPELL:
-@@ -466,6 +468,8 @@
- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rl", &broker, &dict_type) == FAILURE) {
+ if (!value_len) {
RETURN_FALSE;
+@@ -485,6 +487,8 @@ PHP_FUNCTION(enchant_broker_get_dict_pat
+ default:
+ RETURN_FALSE;
}
+
+ PHP_ENCHANT_GET_BROKER;
- switch (dict_type) {
- case PHP_ENCHANT_MYSPELL:
+ RETURN_STRING(value, 1);
+ }
diff --git a/debian/patches/bug53323.patch b/debian/patches/bug53323.patch
deleted file mode 100644
index 53cfd55..0000000
--- a/debian/patches/bug53323.patch
+++ /dev/null
@@ -1,22 +0,0 @@
---- a/ext/pdo_firebird/firebird_driver.c
-+++ b/ext/pdo_firebird/firebird_driver.c
-@@ -547,7 +547,7 @@ static int firebird_handle_get_attribute
- pdo_firebird_db_handle *H = (pdo_firebird_db_handle *)dbh->driver_data;
-
- switch (attr) {
-- char tmp[200];
-+ char tmp[512];
-
- case PDO_ATTR_AUTOCOMMIT:
- ZVAL_LONG(val,dbh->auto_commit);
-@@ -590,6 +590,10 @@ static int firebird_handle_get_attribute
- ZVAL_STRING(val,tmp,1);
- return 1;
- }
-+
-+ case PDO_ATTR_FETCH_TABLE_NAMES:
-+ ZVAL_BOOL(val, H->fetch_table_names);
-+ return 1;
- }
- return 0;
- }
diff --git a/debian/patches/crash_in_zip_extract.patch b/debian/patches/crash_in_zip_extract.patch
deleted file mode 100644
index 597c4b0..0000000
--- a/debian/patches/crash_in_zip_extract.patch
+++ /dev/null
@@ -1,12 +0,0 @@
---- a/ext/zip/php_zip.c
-+++ b/ext/zip/php_zip.c
-@@ -162,6 +162,9 @@ static int php_zip_extract_file(struct z
- */
- virtual_file_ex(&new_state, file, NULL, CWD_EXPAND);
- path_cleaned = php_zip_make_relative_path(new_state.cwd, new_state.cwd_length);
-+ if(!path_cleaned) {
-+ return 0;
-+ }
- path_cleaned_len = strlen(path_cleaned);
-
- if (path_cleaned_len >= MAXPATHLEN || zip_stat(za, file, 0, &sb) != 0) {
diff --git a/debian/patches/do-not-overwrite-GLOBALS-and-this.patch b/debian/patches/do-not-overwrite-GLOBALS-and-this.patch
deleted file mode 100644
index 3a22fdb..0000000
--- a/debian/patches/do-not-overwrite-GLOBALS-and-this.patch
+++ /dev/null
@@ -1,43 +0,0 @@
---- a/ext/standard/array.c
-+++ b/ext/standard/array.c
-@@ -1389,10 +1389,10 @@ PHP_FUNCTION(extract)
-
- case EXTR_OVERWRITE:
- /* GLOBALS protection */
-- if (var_exists && var_name_len == sizeof("GLOBALS") && !strcmp(var_name, "GLOBALS")) {
-+ if (var_exists && var_name_len == sizeof("GLOBALS")-1 && !strcmp(var_name, "GLOBALS")) {
- break;
- }
-- if (var_exists && var_name_len == sizeof("this") && !strcmp(var_name, "this") && EG(scope) && EG(scope)->name_length != 0) {
-+ if (var_exists && var_name_len == sizeof("this")-1 && !strcmp(var_name, "this") && EG(scope) && EG(scope)->name_length != 0) {
- break;
- }
- ZVAL_STRINGL(&final_name, var_name, var_name_len, 1);
---- /dev/null
-+++ b/ext/standard/tests/array/extract_safety.phpt
-@@ -0,0 +1,24 @@
-+--TEST--
-+Test extract() for overwrite of GLOBALS
-+--FILE--
-+<?php
-+$str = "John";
-+debug_zval_dump($GLOBALS["str"]);
-+
-+/* Extracting Global Variables */
-+$splat = array("foo" => "bar");
-+var_dump(extract(array("GLOBALS" => $splat, EXTR_OVERWRITE)));
-+
-+unset ($splat);
-+
-+debug_zval_dump($GLOBALS["str"]);
-+
-+echo "\nDone";
-+?>
-+
-+--EXPECTF--
-+string(4) "John" refcount(2)
-+int(0)
-+string(4) "John" refcount(2)
-+
-+Done
-\ No newline at end of file
diff --git a/debian/patches/dont-gitclean-in-build.patch b/debian/patches/dont-gitclean-in-build.patch
index b89d065..1eccdac 100644
--- a/debian/patches/dont-gitclean-in-build.patch
+++ b/debian/patches/dont-gitclean-in-build.patch
@@ -7,8 +7,8 @@ Description: Don't run git-clean via buildconf
.
This patch doesn't need to go upstream, as they likely don't want to support
having a patch system on top of their source.
---- php.orig/build/build.mk
-+++ php/build/build.mk
+--- a/build/build.mk
++++ b/build/build.mk
@@ -76,6 +76,5 @@ gitclean-work:
@if (test ! -f '.git/info/exclude' || grep -s "git-ls-files" .git/info/exclude); then \
(echo "Rebuild .git/info/exclude" && echo '*.o' > .git/info/exclude && git svn propget svn:ignore | grep -v config.nice >> .git/info/exclude); \
diff --git a/debian/patches/fix-crash-if-aa-steps-are-invalid.patch b/debian/patches/fix-crash-if-aa-steps-are-invalid.patch
index a347afd..0c36adf 100644
--- a/debian/patches/fix-crash-if-aa-steps-are-invalid.patch
+++ b/debian/patches/fix-crash-if-aa-steps-are-invalid.patch
@@ -1,7 +1,7 @@
--- a/ext/gd/gd.c
+++ b/ext/gd/gd.c
-@@ -4228,6 +4228,11 @@ PHP_FUNCTION(imagepstext)
- return;
+@@ -4233,6 +4233,11 @@ PHP_FUNCTION(imagepstext)
+ RETURN_FALSE;
}
+ if (aa_steps != 4 && aa_steps != 16) {
diff --git a/debian/patches/fix-for-NULL-deref-in-zend_language_scanner.patch b/debian/patches/fix-for-NULL-deref-in-zend_language_scanner.patch
deleted file mode 100644
index e79e4c6..0000000
--- a/debian/patches/fix-for-NULL-deref-in-zend_language_scanner.patch
+++ /dev/null
@@ -1,13 +0,0 @@
---- a/Zend/zend_language_scanner.l
-+++ b/Zend/zend_language_scanner.l
-@@ -284,6 +284,10 @@ ZEND_API int open_file_for_scanning(zend
- SCNG(script_filtered_size) = SCNG(script_org_size);
- } else {
- SCNG(input_filter)(&SCNG(script_filtered), &SCNG(script_filtered_size), SCNG(script_org), SCNG(script_org_size) TSRMLS_CC);
-+ if (SCNG(script_filtered) == NULL) {
-+ zend_error_noreturn(E_COMPILE_ERROR, "Could not convert the script from the detected "
-+ "encoding \"%s\" to a compatible encoding", LANG_SCNG(script_encoding)->name);
-+ }
- }
- SCNG(yy_start) = SCNG(script_filtered) - offset;
- yy_scan_buffer((char *)SCNG(script_filtered), SCNG(script_filtered_size) TSRMLS_CC);
diff --git a/debian/patches/fix-infinite-loop-with-x87-cpu.patch b/debian/patches/fix-infinite-loop-with-x87-cpu.patch
deleted file mode 100644
index 7ae3400..0000000
--- a/debian/patches/fix-infinite-loop-with-x87-cpu.patch
+++ /dev/null
@@ -1,24 +0,0 @@
---- /dev/null
-+++ b/Zend/tests/bug53632.phpt
-@@ -0,0 +1,10 @@
-+--TEST--
-+zend_strtod() hangs with 2.2250738585072011e-308
-+--FILE--
-+<?php
-+$d = 2.2250738585072011e-308;
-+
-+echo "Done\n";
-+?>
-+--EXPECTF--
-+Done
---- a/Zend/zend_strtod.c
-+++ b/Zend/zend_strtod.c
-@@ -2045,7 +2045,7 @@ ZEND_API double zend_strtod (CONST char
- int bb2, bb5, bbe, bd2, bd5, bbbits, bs2, c, dsign,
- e, e1, esign, i, j, k, nd, nd0, nf, nz, nz0, sign;
- CONST char *s, *s0, *s1;
-- double aadj, aadj1, adj;
-+ volatile double aadj, aadj1, adj;
- volatile _double rv, rv0;
- Long L;
- ULong y, z;
diff --git a/debian/patches/fix-leaks-and-crash-bug-when-passing-the-callback-as-variable.patch b/debian/patches/fix-leaks-and-crash-bug-when-passing-the-callback-as-variable.patch
deleted file mode 100644
index 5a96670..0000000
--- a/debian/patches/fix-leaks-and-crash-bug-when-passing-the-callback-as-variable.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/main/output.c
-+++ b/main/output.c
-@@ -745,7 +745,7 @@ PHP_FUNCTION(ob_start)
- long chunk_size=0;
- zend_bool erase=1;
-
-- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|zlb", &output_handler, &chunk_size, &erase) == FAILURE) {
-+ if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|z/lb", &output_handler, &chunk_size, &erase) == FAILURE) {
- return;
- }
-
diff --git a/debian/patches/fix-memory-leak-inside-highlight_string.patch b/debian/patches/fix-memory-leak-inside-highlight_string.patch
index ec47f50..bbed854 100644
--- a/debian/patches/fix-memory-leak-inside-highlight_string.patch
+++ b/debian/patches/fix-memory-leak-inside-highlight_string.patch
@@ -1,20 +1,6 @@
---- 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 Tue Jun 29 08:18:52 2010 */
-+/* Generated by re2c 0.13.5 on Mon Jan 3 05:56:03 2011 */
- #line 3 "Zend/zend_language_scanner_defs.h"
-
- enum YYCONDTYPE {
--- a/Zend/zend_language_scanner.c
+++ b/Zend/zend_language_scanner.c
-@@ -1,4 +1,4 @@
--/* Generated by re2c 0.13.5 on Tue Jun 29 23:22:29 2010 */
-+/* Generated by re2c 0.13.5 on Mon Jan 3 05:56:03 2011 */
- #line 1 "Zend/zend_language_scanner.l"
- /*
- +----------------------------------------------------------------------+
-@@ -229,6 +229,12 @@ ZEND_API void zend_restore_lexical_state
+@@ -228,6 +228,12 @@ ZEND_API void zend_restore_lexical_state
SCNG(script_encoding) = lex_state->script_encoding;
SCNG(internal_encoding) = lex_state->internal_encoding;
#endif /* ZEND_MULTIBYTE */
@@ -27,2499 +13,6 @@
}
ZEND_API void zend_destroy_file_handle(zend_file_handle *file_handle TSRMLS_DC)
-@@ -286,6 +292,10 @@ ZEND_API int open_file_for_scanning(zend
- SCNG(script_filtered_size) = SCNG(script_org_size);
- } else {
- SCNG(input_filter)(&SCNG(script_filtered), &SCNG(script_filtered_size), SCNG(script_org), SCNG(script_org_size) TSRMLS_CC);
-+ if (SCNG(script_filtered) == NULL) {
-+ zend_error_noreturn(E_COMPILE_ERROR, "Could not convert the script from the detected "
-+ "encoding \"%s\" to a compatible encoding", LANG_SCNG(script_encoding)->name);
-+ }
- }
- SCNG(yy_start) = SCNG(script_filtered) - offset;
- yy_scan_buffer((char *)SCNG(script_filtered), SCNG(script_filtered_size) TSRMLS_CC);
-@@ -846,7 +856,7 @@ restart:
- yymore_restart:
-
-
--#line 850 "Zend/zend_language_scanner.c"
-+#line 860 "Zend/zend_language_scanner.c"
- {
- YYCTYPE yych;
- unsigned int yyaccept = 0;
-@@ -945,7 +955,7 @@ yyc_INITIAL:
- yy3:
- YYDEBUG(3, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1574 "Zend/zend_language_scanner.l"
-+#line 1584 "Zend/zend_language_scanner.l"
- {
- if (YYCURSOR > YYLIMIT) {
- return 0;
-@@ -1010,7 +1020,7 @@ inline_html:
- HANDLE_NEWLINES(yytext, yyleng);
- return T_INLINE_HTML;
- }
--#line 1014 "Zend/zend_language_scanner.c"
-+#line 1024 "Zend/zend_language_scanner.c"
- yy4:
- YYDEBUG(4, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -1028,7 +1038,7 @@ yy5:
- yy6:
- YYDEBUG(6, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1562 "Zend/zend_language_scanner.l"
-+#line 1572 "Zend/zend_language_scanner.l"
- {
- if (CG(short_tags)) {
- zendlval->value.str.val = yytext; /* no copying - intentional */
-@@ -1040,14 +1050,14 @@ yy6:
- goto inline_char_handler;
- }
- }
--#line 1044 "Zend/zend_language_scanner.c"
-+#line 1054 "Zend/zend_language_scanner.c"
- yy7:
- YYDEBUG(7, *YYCURSOR);
- ++YYCURSOR;
- if ((yych = *YYCURSOR) == '=') goto yy43;
- YYDEBUG(8, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1539 "Zend/zend_language_scanner.l"
-+#line 1549 "Zend/zend_language_scanner.l"
- {
- if (CG(asp_tags)) {
- zendlval->value.str.val = yytext; /* no copying - intentional */
-@@ -1059,7 +1069,7 @@ yy7:
- goto inline_char_handler;
- }
- }
--#line 1063 "Zend/zend_language_scanner.c"
-+#line 1073 "Zend/zend_language_scanner.c"
- yy9:
- YYDEBUG(9, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -1245,7 +1255,7 @@ yy35:
- ++YYCURSOR;
- YYDEBUG(38, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1495 "Zend/zend_language_scanner.l"
-+#line 1505 "Zend/zend_language_scanner.l"
- {
- YYCTYPE *bracket = zend_memrchr(yytext, '<', yyleng - (sizeof("script language=php>") - 1));
-
-@@ -1262,7 +1272,7 @@ yy35:
- BEGIN(ST_IN_SCRIPTING);
- return T_OPEN_TAG;
- }
--#line 1266 "Zend/zend_language_scanner.c"
-+#line 1276 "Zend/zend_language_scanner.c"
- yy39:
- YYDEBUG(39, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -1289,7 +1299,7 @@ yy43:
- ++YYCURSOR;
- YYDEBUG(44, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1513 "Zend/zend_language_scanner.l"
-+#line 1523 "Zend/zend_language_scanner.l"
- {
- if (CG(asp_tags)) {
- zendlval->value.str.val = yytext; /* no copying - intentional */
-@@ -1301,13 +1311,13 @@ yy43:
- goto inline_char_handler;
- }
- }
--#line 1305 "Zend/zend_language_scanner.c"
-+#line 1315 "Zend/zend_language_scanner.c"
- yy45:
- YYDEBUG(45, *YYCURSOR);
- ++YYCURSOR;
- YYDEBUG(46, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1526 "Zend/zend_language_scanner.l"
-+#line 1536 "Zend/zend_language_scanner.l"
- {
- if (CG(short_tags)) {
- zendlval->value.str.val = yytext; /* no copying - intentional */
-@@ -1319,7 +1329,7 @@ yy45:
- goto inline_char_handler;
- }
- }
--#line 1323 "Zend/zend_language_scanner.c"
-+#line 1333 "Zend/zend_language_scanner.c"
- yy47:
- YYDEBUG(47, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -1346,7 +1356,7 @@ yy50:
- yy51:
- YYDEBUG(51, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1552 "Zend/zend_language_scanner.l"
-+#line 1562 "Zend/zend_language_scanner.l"
- {
- zendlval->value.str.val = yytext; /* no copying - intentional */
- zendlval->value.str.len = yyleng;
-@@ -1355,7 +1365,7 @@ yy51:
- BEGIN(ST_IN_SCRIPTING);
- return T_OPEN_TAG;
- }
--#line 1359 "Zend/zend_language_scanner.c"
-+#line 1369 "Zend/zend_language_scanner.c"
- yy52:
- YYDEBUG(52, *YYCURSOR);
- ++YYCURSOR;
-@@ -1426,7 +1436,7 @@ yyc_ST_BACKQUOTE:
- yy56:
- YYDEBUG(56, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 2032 "Zend/zend_language_scanner.l"
-+#line 2042 "Zend/zend_language_scanner.l"
- {
- if (YYCURSOR > YYLIMIT) {
- return 0;
-@@ -1467,7 +1477,7 @@ yy56:
- zend_scan_escape_string(zendlval, yytext, yyleng, '`' TSRMLS_CC);
- return T_ENCAPSED_AND_WHITESPACE;
- }
--#line 1471 "Zend/zend_language_scanner.c"
-+#line 1481 "Zend/zend_language_scanner.c"
- yy57:
- YYDEBUG(57, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -1478,12 +1488,12 @@ yy58:
- ++YYCURSOR;
- YYDEBUG(59, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1976 "Zend/zend_language_scanner.l"
-+#line 1986 "Zend/zend_language_scanner.l"
- {
- BEGIN(ST_IN_SCRIPTING);
- return '`';
- }
--#line 1487 "Zend/zend_language_scanner.c"
-+#line 1497 "Zend/zend_language_scanner.c"
- yy60:
- YYDEBUG(60, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -1493,14 +1503,14 @@ yy61:
- ++YYCURSOR;
- YYDEBUG(62, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1963 "Zend/zend_language_scanner.l"
-+#line 1973 "Zend/zend_language_scanner.l"
- {
- zendlval->value.lval = (long) '{';
- yy_push_state(ST_IN_SCRIPTING TSRMLS_CC);
- yyless(1);
- return T_CURLY_OPEN;
- }
--#line 1504 "Zend/zend_language_scanner.c"
-+#line 1514 "Zend/zend_language_scanner.c"
- yy63:
- YYDEBUG(63, *YYCURSOR);
- yyaccept = 0;
-@@ -1516,24 +1526,24 @@ yy63:
- yy65:
- YYDEBUG(65, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1661 "Zend/zend_language_scanner.l"
-+#line 1671 "Zend/zend_language_scanner.l"
- {
- zend_copy_value(zendlval, (yytext+1), (yyleng-1));
- zendlval->type = IS_STRING;
- return T_VARIABLE;
- }
--#line 1526 "Zend/zend_language_scanner.c"
-+#line 1536 "Zend/zend_language_scanner.c"
- yy66:
- YYDEBUG(66, *YYCURSOR);
- ++YYCURSOR;
- YYDEBUG(67, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1288 "Zend/zend_language_scanner.l"
-+#line 1298 "Zend/zend_language_scanner.l"
- {
- yy_push_state(ST_LOOKING_FOR_VARNAME TSRMLS_CC);
- return T_DOLLAR_OPEN_CURLY_BRACES;
- }
--#line 1537 "Zend/zend_language_scanner.c"
-+#line 1547 "Zend/zend_language_scanner.c"
- yy68:
- YYDEBUG(68, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -1547,7 +1557,7 @@ yy70:
- ++YYCURSOR;
- YYDEBUG(71, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1653 "Zend/zend_language_scanner.l"
-+#line 1663 "Zend/zend_language_scanner.l"
- {
- yyless(yyleng - 1);
- yy_push_state(ST_VAR_OFFSET TSRMLS_CC);
-@@ -1555,7 +1565,7 @@ yy70:
- zendlval->type = IS_STRING;
- return T_VARIABLE;
- }
--#line 1559 "Zend/zend_language_scanner.c"
-+#line 1569 "Zend/zend_language_scanner.c"
- yy72:
- YYDEBUG(72, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -1573,7 +1583,7 @@ yy73:
- ++YYCURSOR;
- YYDEBUG(74, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1643 "Zend/zend_language_scanner.l"
-+#line 1653 "Zend/zend_language_scanner.l"
- {
- yyless(yyleng - 3);
- yy_push_state(ST_LOOKING_FOR_PROPERTY TSRMLS_CC);
-@@ -1581,7 +1591,7 @@ yy73:
- zendlval->type = IS_STRING;
- return T_VARIABLE;
- }
--#line 1585 "Zend/zend_language_scanner.c"
-+#line 1595 "Zend/zend_language_scanner.c"
- }
- /* *********************************** */
- yyc_ST_DOUBLE_QUOTES:
-@@ -1649,7 +1659,7 @@ yy77:
- yy78:
- YYDEBUG(78, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1982 "Zend/zend_language_scanner.l"
-+#line 1992 "Zend/zend_language_scanner.l"
- {
- if (GET_DOUBLE_QUOTES_SCANNED_LENGTH()) {
- YYCURSOR += GET_DOUBLE_QUOTES_SCANNED_LENGTH() - 1;
-@@ -1698,7 +1708,7 @@ double_quotes_scan_done:
- zend_scan_escape_string(zendlval, yytext, yyleng, '"' TSRMLS_CC);
- return T_ENCAPSED_AND_WHITESPACE;
- }
--#line 1702 "Zend/zend_language_scanner.c"
-+#line 1712 "Zend/zend_language_scanner.c"
- yy79:
- YYDEBUG(79, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -1709,12 +1719,12 @@ yy80:
- ++YYCURSOR;
- YYDEBUG(81, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1971 "Zend/zend_language_scanner.l"
-+#line 1981 "Zend/zend_language_scanner.l"
- {
- BEGIN(ST_IN_SCRIPTING);
- return '"';
- }
--#line 1718 "Zend/zend_language_scanner.c"
-+#line 1728 "Zend/zend_language_scanner.c"
- yy82:
- YYDEBUG(82, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -1724,14 +1734,14 @@ yy83:
- ++YYCURSOR;
- YYDEBUG(84, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1963 "Zend/zend_language_scanner.l"
-+#line 1973 "Zend/zend_language_scanner.l"
- {
- zendlval->value.lval = (long) '{';
- yy_push_state(ST_IN_SCRIPTING TSRMLS_CC);
- yyless(1);
- return T_CURLY_OPEN;
- }
--#line 1735 "Zend/zend_language_scanner.c"
-+#line 1745 "Zend/zend_language_scanner.c"
- yy85:
- YYDEBUG(85, *YYCURSOR);
- yyaccept = 0;
-@@ -1747,24 +1757,24 @@ yy85:
- yy87:
- YYDEBUG(87, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1661 "Zend/zend_language_scanner.l"
-+#line 1671 "Zend/zend_language_scanner.l"
- {
- zend_copy_value(zendlval, (yytext+1), (yyleng-1));
- zendlval->type = IS_STRING;
- return T_VARIABLE;
- }
--#line 1757 "Zend/zend_language_scanner.c"
-+#line 1767 "Zend/zend_language_scanner.c"
- yy88:
- YYDEBUG(88, *YYCURSOR);
- ++YYCURSOR;
- YYDEBUG(89, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1288 "Zend/zend_language_scanner.l"
-+#line 1298 "Zend/zend_language_scanner.l"
- {
- yy_push_state(ST_LOOKING_FOR_VARNAME TSRMLS_CC);
- return T_DOLLAR_OPEN_CURLY_BRACES;
- }
--#line 1768 "Zend/zend_language_scanner.c"
-+#line 1778 "Zend/zend_language_scanner.c"
- yy90:
- YYDEBUG(90, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -1778,7 +1788,7 @@ yy92:
- ++YYCURSOR;
- YYDEBUG(93, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1653 "Zend/zend_language_scanner.l"
-+#line 1663 "Zend/zend_language_scanner.l"
- {
- yyless(yyleng - 1);
- yy_push_state(ST_VAR_OFFSET TSRMLS_CC);
-@@ -1786,7 +1796,7 @@ yy92:
- zendlval->type = IS_STRING;
- return T_VARIABLE;
- }
--#line 1790 "Zend/zend_language_scanner.c"
-+#line 1800 "Zend/zend_language_scanner.c"
- yy94:
- YYDEBUG(94, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -1804,7 +1814,7 @@ yy95:
- ++YYCURSOR;
- YYDEBUG(96, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1643 "Zend/zend_language_scanner.l"
-+#line 1653 "Zend/zend_language_scanner.l"
- {
- yyless(yyleng - 3);
- yy_push_state(ST_LOOKING_FOR_PROPERTY TSRMLS_CC);
-@@ -1812,7 +1822,7 @@ yy95:
- zendlval->type = IS_STRING;
- return T_VARIABLE;
- }
--#line 1816 "Zend/zend_language_scanner.c"
-+#line 1826 "Zend/zend_language_scanner.c"
- }
- /* *********************************** */
- yyc_ST_END_HEREDOC:
-@@ -1823,7 +1833,7 @@ yyc_ST_END_HEREDOC:
- ++YYCURSOR;
- YYDEBUG(100, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1950 "Zend/zend_language_scanner.l"
-+#line 1960 "Zend/zend_language_scanner.l"
- {
- YYCURSOR += CG(heredoc_len) - 1;
- yyleng = CG(heredoc_len);
-@@ -1835,7 +1845,7 @@ yyc_ST_END_HEREDOC:
- BEGIN(ST_IN_SCRIPTING);
- return T_END_HEREDOC;
- }
--#line 1839 "Zend/zend_language_scanner.c"
-+#line 1849 "Zend/zend_language_scanner.c"
- /* *********************************** */
- yyc_ST_HEREDOC:
- {
-@@ -1897,7 +1907,7 @@ yy103:
- yy104:
- YYDEBUG(104, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 2074 "Zend/zend_language_scanner.l"
-+#line 2084 "Zend/zend_language_scanner.l"
- {
- int newline = 0;
-
-@@ -1968,7 +1978,7 @@ heredoc_scan_done:
- zend_scan_escape_string(zendlval, yytext, yyleng - newline, 0 TSRMLS_CC);
- return T_ENCAPSED_AND_WHITESPACE;
- }
--#line 1972 "Zend/zend_language_scanner.c"
-+#line 1982 "Zend/zend_language_scanner.c"
- yy105:
- YYDEBUG(105, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -1983,14 +1993,14 @@ yy107:
- ++YYCURSOR;
- YYDEBUG(108, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1963 "Zend/zend_language_scanner.l"
-+#line 1973 "Zend/zend_language_scanner.l"
- {
- zendlval->value.lval = (long) '{';
- yy_push_state(ST_IN_SCRIPTING TSRMLS_CC);
- yyless(1);
- return T_CURLY_OPEN;
- }
--#line 1994 "Zend/zend_language_scanner.c"
-+#line 2004 "Zend/zend_language_scanner.c"
- yy109:
- YYDEBUG(109, *YYCURSOR);
- yyaccept = 0;
-@@ -2006,24 +2016,24 @@ yy109:
- yy111:
- YYDEBUG(111, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1661 "Zend/zend_language_scanner.l"
-+#line 1671 "Zend/zend_language_scanner.l"
- {
- zend_copy_value(zendlval, (yytext+1), (yyleng-1));
- zendlval->type = IS_STRING;
- return T_VARIABLE;
- }
--#line 2016 "Zend/zend_language_scanner.c"
-+#line 2026 "Zend/zend_language_scanner.c"
- yy112:
- YYDEBUG(112, *YYCURSOR);
- ++YYCURSOR;
- YYDEBUG(113, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1288 "Zend/zend_language_scanner.l"
-+#line 1298 "Zend/zend_language_scanner.l"
- {
- yy_push_state(ST_LOOKING_FOR_VARNAME TSRMLS_CC);
- return T_DOLLAR_OPEN_CURLY_BRACES;
- }
--#line 2027 "Zend/zend_language_scanner.c"
-+#line 2037 "Zend/zend_language_scanner.c"
- yy114:
- YYDEBUG(114, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -2037,7 +2047,7 @@ yy116:
- ++YYCURSOR;
- YYDEBUG(117, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1653 "Zend/zend_language_scanner.l"
-+#line 1663 "Zend/zend_language_scanner.l"
- {
- yyless(yyleng - 1);
- yy_push_state(ST_VAR_OFFSET TSRMLS_CC);
-@@ -2045,7 +2055,7 @@ yy116:
- zendlval->type = IS_STRING;
- return T_VARIABLE;
- }
--#line 2049 "Zend/zend_language_scanner.c"
-+#line 2059 "Zend/zend_language_scanner.c"
- yy118:
- YYDEBUG(118, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -2063,7 +2073,7 @@ yy119:
- ++YYCURSOR;
- YYDEBUG(120, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1643 "Zend/zend_language_scanner.l"
-+#line 1653 "Zend/zend_language_scanner.l"
- {
- yyless(yyleng - 3);
- yy_push_state(ST_LOOKING_FOR_PROPERTY TSRMLS_CC);
-@@ -2071,7 +2081,7 @@ yy119:
- zendlval->type = IS_STRING;
- return T_VARIABLE;
- }
--#line 2075 "Zend/zend_language_scanner.c"
-+#line 2085 "Zend/zend_language_scanner.c"
- }
- /* *********************************** */
- yyc_ST_IN_SCRIPTING:
-@@ -2252,13 +2262,13 @@ yy123:
- yy124:
- YYDEBUG(124, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1684 "Zend/zend_language_scanner.l"
-+#line 1694 "Zend/zend_language_scanner.l"
- {
- zend_copy_value(zendlval, yytext, yyleng);
- zendlval->type = IS_STRING;
- return T_STRING;
- }
--#line 2262 "Zend/zend_language_scanner.c"
-+#line 2272 "Zend/zend_language_scanner.c"
- yy125:
- YYDEBUG(125, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -2484,11 +2494,11 @@ yy137:
- yy138:
- YYDEBUG(138, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1277 "Zend/zend_language_scanner.l"
-+#line 1287 "Zend/zend_language_scanner.l"
- {
- return yytext[0];
- }
--#line 2492 "Zend/zend_language_scanner.c"
-+#line 2502 "Zend/zend_language_scanner.c"
- yy139:
- YYDEBUG(139, *YYCURSOR);
- ++YYCURSOR;
-@@ -2497,7 +2507,7 @@ yy139:
- yy140:
- YYDEBUG(140, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1012 "Zend/zend_language_scanner.l"
-+#line 1022 "Zend/zend_language_scanner.l"
- {
- zendlval->value.str.val = yytext; /* no copying - intentional */
- zendlval->value.str.len = yyleng;
-@@ -2505,7 +2515,7 @@ yy140:
- HANDLE_NEWLINES(yytext, yyleng);
- return T_WHITESPACE;
- }
--#line 2509 "Zend/zend_language_scanner.c"
-+#line 2519 "Zend/zend_language_scanner.c"
- yy141:
- YYDEBUG(141, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -2516,11 +2526,11 @@ yy142:
- ++YYCURSOR;
- YYDEBUG(143, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1041 "Zend/zend_language_scanner.l"
-+#line 1051 "Zend/zend_language_scanner.l"
- {
- return T_NS_SEPARATOR;
- }
--#line 2524 "Zend/zend_language_scanner.c"
-+#line 2534 "Zend/zend_language_scanner.c"
- yy144:
- YYDEBUG(144, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -2748,18 +2758,18 @@ yy167:
- ++YYCURSOR;
- YYDEBUG(168, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1282 "Zend/zend_language_scanner.l"
-+#line 1292 "Zend/zend_language_scanner.l"
- {
- yy_push_state(ST_IN_SCRIPTING TSRMLS_CC);
- return '{';
- }
--#line 2757 "Zend/zend_language_scanner.c"
-+#line 2767 "Zend/zend_language_scanner.c"
- yy169:
- YYDEBUG(169, *YYCURSOR);
- ++YYCURSOR;
- YYDEBUG(170, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1294 "Zend/zend_language_scanner.l"
-+#line 1304 "Zend/zend_language_scanner.l"
- {
- RESET_DOC_COMMENT();
- if (!zend_stack_is_empty(&SCNG(state_stack))) {
-@@ -2767,7 +2777,7 @@ yy169:
- }
- return '}';
- }
--#line 2771 "Zend/zend_language_scanner.c"
-+#line 2781 "Zend/zend_language_scanner.c"
- yy171:
- YYDEBUG(171, *YYCURSOR);
- yyaccept = 2;
-@@ -2790,7 +2800,7 @@ yy171:
- yy172:
- YYDEBUG(172, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1320 "Zend/zend_language_scanner.l"
-+#line 1330 "Zend/zend_language_scanner.l"
- {
- if (yyleng < MAX_LENGTH_OF_LONG - 1) { /* Won't overflow */
- zendlval->value.lval = strtol(yytext, NULL, 0);
-@@ -2811,7 +2821,7 @@ yy172:
- zendlval->type = IS_LONG;
- return T_LNUMBER;
- }
--#line 2815 "Zend/zend_language_scanner.c"
-+#line 2825 "Zend/zend_language_scanner.c"
- yy173:
- YYDEBUG(173, *YYCURSOR);
- yyaccept = 2;
-@@ -2839,7 +2849,7 @@ yy175:
- yy176:
- YYDEBUG(176, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1691 "Zend/zend_language_scanner.l"
-+#line 1701 "Zend/zend_language_scanner.l"
- {
- while (YYCURSOR < YYLIMIT) {
- switch (*YYCURSOR++) {
-@@ -2873,14 +2883,14 @@ yy176:
-
- return T_COMMENT;
- }
--#line 2877 "Zend/zend_language_scanner.c"
-+#line 2887 "Zend/zend_language_scanner.c"
- yy177:
- YYDEBUG(177, *YYCURSOR);
- ++YYCURSOR;
- yy178:
- YYDEBUG(178, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1782 "Zend/zend_language_scanner.l"
-+#line 1792 "Zend/zend_language_scanner.l"
- {
- register char *s, *t;
- char *end;
-@@ -2950,14 +2960,14 @@ yy178:
- #endif /* ZEND_MULTIBYTE */
- return T_CONSTANT_ENCAPSED_STRING;
- }
--#line 2954 "Zend/zend_language_scanner.c"
-+#line 2964 "Zend/zend_language_scanner.c"
- yy179:
- YYDEBUG(179, *YYCURSOR);
- ++YYCURSOR;
- yy180:
- YYDEBUG(180, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1853 "Zend/zend_language_scanner.l"
-+#line 1863 "Zend/zend_language_scanner.l"
- {
- int bprefix = (yytext[0] != '"') ? 1 : 0;
-
-@@ -2998,24 +3008,24 @@ yy180:
- BEGIN(ST_DOUBLE_QUOTES);
- return '"';
- }
--#line 3002 "Zend/zend_language_scanner.c"
-+#line 3012 "Zend/zend_language_scanner.c"
- yy181:
- YYDEBUG(181, *YYCURSOR);
- ++YYCURSOR;
- YYDEBUG(182, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1944 "Zend/zend_language_scanner.l"
-+#line 1954 "Zend/zend_language_scanner.l"
- {
- BEGIN(ST_BACKQUOTE);
- return '`';
- }
--#line 3013 "Zend/zend_language_scanner.c"
-+#line 3023 "Zend/zend_language_scanner.c"
- yy183:
- YYDEBUG(183, *YYCURSOR);
- ++YYCURSOR;
- YYDEBUG(184, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 2202 "Zend/zend_language_scanner.l"
-+#line 2212 "Zend/zend_language_scanner.l"
- {
- if (YYCURSOR > YYLIMIT) {
- return 0;
-@@ -3024,7 +3034,7 @@ yy183:
- zend_error(E_COMPILE_WARNING,"Unexpected character in input: '%c' (ASCII=%d) state=%d", yytext[0], yytext[0], YYSTATE);
- goto restart;
- }
--#line 3028 "Zend/zend_language_scanner.c"
-+#line 3038 "Zend/zend_language_scanner.c"
- yy185:
- YYDEBUG(185, *YYCURSOR);
- ++YYCURSOR;
-@@ -3051,13 +3061,13 @@ yy187:
- yy189:
- YYDEBUG(189, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1381 "Zend/zend_language_scanner.l"
-+#line 1391 "Zend/zend_language_scanner.l"
- {
- zendlval->value.dval = zend_strtod(yytext, NULL);
- zendlval->type = IS_DOUBLE;
- return T_DNUMBER;
- }
--#line 3061 "Zend/zend_language_scanner.c"
-+#line 3071 "Zend/zend_language_scanner.c"
- yy190:
- YYDEBUG(190, *YYCURSOR);
- yyaccept = 2;
-@@ -3142,7 +3152,7 @@ yy198:
- }
- YYDEBUG(200, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1341 "Zend/zend_language_scanner.l"
-+#line 1351 "Zend/zend_language_scanner.l"
- {
- char *hex = yytext + 2; /* Skip "0x" */
- int len = yyleng - 2;
-@@ -3163,7 +3173,7 @@ yy198:
- return T_DNUMBER;
- }
- }
--#line 3167 "Zend/zend_language_scanner.c"
-+#line 3177 "Zend/zend_language_scanner.c"
- yy201:
- YYDEBUG(201, *YYCURSOR);
- ++YYCURSOR;
-@@ -3172,7 +3182,7 @@ yy201:
- yy202:
- YYDEBUG(202, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1759 "Zend/zend_language_scanner.l"
-+#line 1769 "Zend/zend_language_scanner.l"
- {
- zendlval->value.str.val = yytext; /* no copying - intentional */
- zendlval->value.str.len = yyleng;
-@@ -3180,7 +3190,7 @@ yy202:
- BEGIN(INITIAL);
- return T_CLOSE_TAG; /* implicit ';' at php-end tag */
- }
--#line 3184 "Zend/zend_language_scanner.c"
-+#line 3194 "Zend/zend_language_scanner.c"
- yy203:
- YYDEBUG(203, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -3214,13 +3224,13 @@ yy205:
- yy207:
- YYDEBUG(207, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1661 "Zend/zend_language_scanner.l"
-+#line 1671 "Zend/zend_language_scanner.l"
- {
- zend_copy_value(zendlval, (yytext+1), (yyleng-1));
- zendlval->type = IS_STRING;
- return T_VARIABLE;
- }
--#line 3224 "Zend/zend_language_scanner.c"
-+#line 3234 "Zend/zend_language_scanner.c"
- yy208:
- YYDEBUG(208, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -3234,11 +3244,11 @@ yy209:
- }
- YYDEBUG(210, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1265 "Zend/zend_language_scanner.l"
-+#line 1275 "Zend/zend_language_scanner.l"
- {
- return T_LOGICAL_XOR;
- }
--#line 3242 "Zend/zend_language_scanner.c"
-+#line 3252 "Zend/zend_language_scanner.c"
- yy211:
- YYDEBUG(211, *YYCURSOR);
- ++YYCURSOR;
-@@ -3247,61 +3257,61 @@ yy211:
- }
- YYDEBUG(212, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1257 "Zend/zend_language_scanner.l"
-+#line 1267 "Zend/zend_language_scanner.l"
- {
- return T_LOGICAL_OR;
- }
--#line 3255 "Zend/zend_language_scanner.c"
-+#line 3265 "Zend/zend_language_scanner.c"
- yy213:
- YYDEBUG(213, *YYCURSOR);
- ++YYCURSOR;
- YYDEBUG(214, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1245 "Zend/zend_language_scanner.l"
-+#line 1255 "Zend/zend_language_scanner.l"
- {
- return T_XOR_EQUAL;
- }
--#line 3265 "Zend/zend_language_scanner.c"
-+#line 3275 "Zend/zend_language_scanner.c"
- yy215:
- YYDEBUG(215, *YYCURSOR);
- ++YYCURSOR;
- YYDEBUG(216, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1249 "Zend/zend_language_scanner.l"
-+#line 1259 "Zend/zend_language_scanner.l"
- {
- return T_BOOLEAN_OR;
- }
--#line 3275 "Zend/zend_language_scanner.c"
-+#line 3285 "Zend/zend_language_scanner.c"
- yy217:
- YYDEBUG(217, *YYCURSOR);
- ++YYCURSOR;
- YYDEBUG(218, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1241 "Zend/zend_language_scanner.l"
-+#line 1251 "Zend/zend_language_scanner.l"
- {
- return T_OR_EQUAL;
- }
--#line 3285 "Zend/zend_language_scanner.c"
-+#line 3295 "Zend/zend_language_scanner.c"
- yy219:
- YYDEBUG(219, *YYCURSOR);
- ++YYCURSOR;
- YYDEBUG(220, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1253 "Zend/zend_language_scanner.l"
-+#line 1263 "Zend/zend_language_scanner.l"
- {
- return T_BOOLEAN_AND;
- }
--#line 3295 "Zend/zend_language_scanner.c"
-+#line 3305 "Zend/zend_language_scanner.c"
- yy221:
- YYDEBUG(221, *YYCURSOR);
- ++YYCURSOR;
- YYDEBUG(222, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1237 "Zend/zend_language_scanner.l"
-+#line 1247 "Zend/zend_language_scanner.l"
- {
- return T_AND_EQUAL;
- }
--#line 3305 "Zend/zend_language_scanner.c"
-+#line 3315 "Zend/zend_language_scanner.c"
- yy223:
- YYDEBUG(223, *YYCURSOR);
- ++YYCURSOR;
-@@ -3310,7 +3320,7 @@ yy223:
- yy224:
- YYDEBUG(224, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1768 "Zend/zend_language_scanner.l"
-+#line 1778 "Zend/zend_language_scanner.l"
- {
- if (CG(asp_tags)) {
- BEGIN(INITIAL);
-@@ -3323,17 +3333,17 @@ yy224:
- return yytext[0];
- }
- }
--#line 3327 "Zend/zend_language_scanner.c"
-+#line 3337 "Zend/zend_language_scanner.c"
- yy225:
- YYDEBUG(225, *YYCURSOR);
- ++YYCURSOR;
- YYDEBUG(226, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1225 "Zend/zend_language_scanner.l"
-+#line 1235 "Zend/zend_language_scanner.l"
- {
- return T_MOD_EQUAL;
- }
--#line 3337 "Zend/zend_language_scanner.c"
-+#line 3347 "Zend/zend_language_scanner.c"
- yy227:
- YYDEBUG(227, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -3364,11 +3374,11 @@ yy231:
- ++YYCURSOR;
- YYDEBUG(232, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1221 "Zend/zend_language_scanner.l"
-+#line 1231 "Zend/zend_language_scanner.l"
- {
- return T_CONCAT_EQUAL;
- }
--#line 3372 "Zend/zend_language_scanner.c"
-+#line 3382 "Zend/zend_language_scanner.c"
- yy233:
- YYDEBUG(233, *YYCURSOR);
- yyaccept = 4;
-@@ -3377,7 +3387,7 @@ yy233:
- yy234:
- YYDEBUG(234, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1725 "Zend/zend_language_scanner.l"
-+#line 1735 "Zend/zend_language_scanner.l"
- {
- int doc_com;
-
-@@ -3411,7 +3421,7 @@ yy234:
-
- return T_COMMENT;
- }
--#line 3415 "Zend/zend_language_scanner.c"
-+#line 3425 "Zend/zend_language_scanner.c"
- yy235:
- YYDEBUG(235, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -3421,11 +3431,11 @@ yy236:
- ++YYCURSOR;
- YYDEBUG(237, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1217 "Zend/zend_language_scanner.l"
-+#line 1227 "Zend/zend_language_scanner.l"
- {
- return T_DIV_EQUAL;
- }
--#line 3429 "Zend/zend_language_scanner.c"
-+#line 3439 "Zend/zend_language_scanner.c"
- yy238:
- YYDEBUG(238, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -3448,42 +3458,42 @@ yy241:
- ++YYCURSOR;
- YYDEBUG(242, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1213 "Zend/zend_language_scanner.l"
-+#line 1223 "Zend/zend_language_scanner.l"
- {
- return T_MUL_EQUAL;
- }
--#line 3456 "Zend/zend_language_scanner.c"
-+#line 3466 "Zend/zend_language_scanner.c"
- yy243:
- YYDEBUG(243, *YYCURSOR);
- ++YYCURSOR;
- if ((yych = *YYCURSOR) == '=') goto yy247;
- YYDEBUG(244, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1273 "Zend/zend_language_scanner.l"
-+#line 1283 "Zend/zend_language_scanner.l"
- {
- return T_SR;
- }
--#line 3467 "Zend/zend_language_scanner.c"
-+#line 3477 "Zend/zend_language_scanner.c"
- yy245:
- YYDEBUG(245, *YYCURSOR);
- ++YYCURSOR;
- YYDEBUG(246, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1201 "Zend/zend_language_scanner.l"
-+#line 1211 "Zend/zend_language_scanner.l"
- {
- return T_IS_GREATER_OR_EQUAL;
- }
--#line 3477 "Zend/zend_language_scanner.c"
-+#line 3487 "Zend/zend_language_scanner.c"
- yy247:
- YYDEBUG(247, *YYCURSOR);
- ++YYCURSOR;
- YYDEBUG(248, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1233 "Zend/zend_language_scanner.l"
-+#line 1243 "Zend/zend_language_scanner.l"
- {
- return T_SR_EQUAL;
- }
--#line 3487 "Zend/zend_language_scanner.c"
-+#line 3497 "Zend/zend_language_scanner.c"
- yy249:
- YYDEBUG(249, *YYCURSOR);
- yyaccept = 5;
-@@ -3494,11 +3504,11 @@ yy249:
- yy250:
- YYDEBUG(250, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1269 "Zend/zend_language_scanner.l"
-+#line 1279 "Zend/zend_language_scanner.l"
- {
- return T_SL;
- }
--#line 3502 "Zend/zend_language_scanner.c"
-+#line 3512 "Zend/zend_language_scanner.c"
- yy251:
- YYDEBUG(251, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -3510,22 +3520,22 @@ yy252:
- ++YYCURSOR;
- YYDEBUG(253, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1197 "Zend/zend_language_scanner.l"
-+#line 1207 "Zend/zend_language_scanner.l"
- {
- return T_IS_SMALLER_OR_EQUAL;
- }
--#line 3518 "Zend/zend_language_scanner.c"
-+#line 3528 "Zend/zend_language_scanner.c"
- yy254:
- YYDEBUG(254, *YYCURSOR);
- ++YYCURSOR;
- yy255:
- YYDEBUG(255, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1193 "Zend/zend_language_scanner.l"
-+#line 1203 "Zend/zend_language_scanner.l"
- {
- return T_IS_NOT_EQUAL;
- }
--#line 3529 "Zend/zend_language_scanner.c"
-+#line 3539 "Zend/zend_language_scanner.c"
- yy256:
- YYDEBUG(256, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -3576,11 +3586,11 @@ yy263:
- ++YYCURSOR;
- YYDEBUG(264, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1229 "Zend/zend_language_scanner.l"
-+#line 1239 "Zend/zend_language_scanner.l"
- {
- return T_SL_EQUAL;
- }
--#line 3584 "Zend/zend_language_scanner.c"
-+#line 3594 "Zend/zend_language_scanner.c"
- yy265:
- YYDEBUG(265, *YYCURSOR);
- ++YYCURSOR;
-@@ -3685,7 +3695,7 @@ yy274:
- yy275:
- YYDEBUG(275, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1895 "Zend/zend_language_scanner.l"
-+#line 1905 "Zend/zend_language_scanner.l"
- {
- char *s;
- int bprefix = (yytext[0] != '<') ? 1 : 0;
-@@ -3733,7 +3743,7 @@ yy275:
-
- return T_START_HEREDOC;
- }
--#line 3737 "Zend/zend_language_scanner.c"
-+#line 3747 "Zend/zend_language_scanner.c"
- yy276:
- YYDEBUG(276, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -3773,31 +3783,31 @@ yy279:
- ++YYCURSOR;
- YYDEBUG(281, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1185 "Zend/zend_language_scanner.l"
-+#line 1195 "Zend/zend_language_scanner.l"
- {
- return T_IS_NOT_IDENTICAL;
- }
--#line 3781 "Zend/zend_language_scanner.c"
-+#line 3791 "Zend/zend_language_scanner.c"
- yy282:
- YYDEBUG(282, *YYCURSOR);
- ++YYCURSOR;
- YYDEBUG(283, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1205 "Zend/zend_language_scanner.l"
-+#line 1215 "Zend/zend_language_scanner.l"
- {
- return T_PLUS_EQUAL;
- }
--#line 3791 "Zend/zend_language_scanner.c"
-+#line 3801 "Zend/zend_language_scanner.c"
- yy284:
- YYDEBUG(284, *YYCURSOR);
- ++YYCURSOR;
- YYDEBUG(285, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1173 "Zend/zend_language_scanner.l"
-+#line 1183 "Zend/zend_language_scanner.l"
- {
- return T_INC;
- }
--#line 3801 "Zend/zend_language_scanner.c"
-+#line 3811 "Zend/zend_language_scanner.c"
- yy286:
- YYDEBUG(286, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -3816,42 +3826,42 @@ yy288:
- }
- YYDEBUG(289, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1165 "Zend/zend_language_scanner.l"
-+#line 1175 "Zend/zend_language_scanner.l"
- {
- return T_LIST;
- }
--#line 3824 "Zend/zend_language_scanner.c"
-+#line 3834 "Zend/zend_language_scanner.c"
- yy290:
- YYDEBUG(290, *YYCURSOR);
- ++YYCURSOR;
- if ((yych = *YYCURSOR) == '=') goto yy294;
- YYDEBUG(291, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1189 "Zend/zend_language_scanner.l"
-+#line 1199 "Zend/zend_language_scanner.l"
- {
- return T_IS_EQUAL;
- }
--#line 3835 "Zend/zend_language_scanner.c"
-+#line 3845 "Zend/zend_language_scanner.c"
- yy292:
- YYDEBUG(292, *YYCURSOR);
- ++YYCURSOR;
- YYDEBUG(293, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1161 "Zend/zend_language_scanner.l"
-+#line 1171 "Zend/zend_language_scanner.l"
- {
- return T_DOUBLE_ARROW;
- }
--#line 3845 "Zend/zend_language_scanner.c"
-+#line 3855 "Zend/zend_language_scanner.c"
- yy294:
- YYDEBUG(294, *YYCURSOR);
- ++YYCURSOR;
- YYDEBUG(295, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1181 "Zend/zend_language_scanner.l"
-+#line 1191 "Zend/zend_language_scanner.l"
- {
- return T_IS_IDENTICAL;
- }
--#line 3855 "Zend/zend_language_scanner.c"
-+#line 3865 "Zend/zend_language_scanner.c"
- yy296:
- YYDEBUG(296, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -3973,7 +3983,7 @@ yy311:
- }
- YYDEBUG(314, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1485 "Zend/zend_language_scanner.l"
-+#line 1495 "Zend/zend_language_scanner.l"
- {
- if (CG(current_namespace)) {
- *zendlval = *CG(current_namespace);
-@@ -3983,7 +3993,7 @@ yy311:
- }
- return T_NS_C;
- }
--#line 3987 "Zend/zend_language_scanner.c"
-+#line 3997 "Zend/zend_language_scanner.c"
- yy315:
- YYDEBUG(315, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -4003,7 +4013,7 @@ yy316:
- }
- YYDEBUG(319, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1458 "Zend/zend_language_scanner.l"
-+#line 1468 "Zend/zend_language_scanner.l"
- {
- char *filename = zend_get_compiled_filename(TSRMLS_C);
- const size_t filename_len = strlen(filename);
-@@ -4030,7 +4040,7 @@ yy316:
- zendlval->type = IS_STRING;
- return T_DIR;
- }
--#line 4034 "Zend/zend_language_scanner.c"
-+#line 4044 "Zend/zend_language_scanner.c"
- yy320:
- YYDEBUG(320, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -4055,13 +4065,13 @@ yy322:
- }
- YYDEBUG(325, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1440 "Zend/zend_language_scanner.l"
-+#line 1450 "Zend/zend_language_scanner.l"
- {
- zendlval->value.lval = CG(zend_lineno);
- zendlval->type = IS_LONG;
- return T_LINE;
- }
--#line 4065 "Zend/zend_language_scanner.c"
-+#line 4075 "Zend/zend_language_scanner.c"
- yy326:
- YYDEBUG(326, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -4096,7 +4106,7 @@ yy330:
- }
- YYDEBUG(333, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1419 "Zend/zend_language_scanner.l"
-+#line 1429 "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;
-@@ -4117,7 +4127,7 @@ yy330:
- zendlval->type = IS_STRING;
- return T_METHOD_C;
- }
--#line 4121 "Zend/zend_language_scanner.c"
-+#line 4131 "Zend/zend_language_scanner.c"
- yy334:
- YYDEBUG(334, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -4168,7 +4178,7 @@ yy341:
- }
- YYDEBUG(344, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1403 "Zend/zend_language_scanner.l"
-+#line 1413 "Zend/zend_language_scanner.l"
- {
- char *func_name = NULL;
-
-@@ -4184,7 +4194,7 @@ yy341:
- zendlval->type = IS_STRING;
- return T_FUNC_C;
- }
--#line 4188 "Zend/zend_language_scanner.c"
-+#line 4198 "Zend/zend_language_scanner.c"
- yy345:
- YYDEBUG(345, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -4204,7 +4214,7 @@ yy346:
- }
- YYDEBUG(349, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1446 "Zend/zend_language_scanner.l"
-+#line 1456 "Zend/zend_language_scanner.l"
- {
- char *filename = zend_get_compiled_filename(TSRMLS_C);
-
-@@ -4216,7 +4226,7 @@ yy346:
- zendlval->type = IS_STRING;
- return T_FILE;
- }
--#line 4220 "Zend/zend_language_scanner.c"
-+#line 4230 "Zend/zend_language_scanner.c"
- yy350:
- YYDEBUG(350, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -4246,7 +4256,7 @@ yy353:
- }
- YYDEBUG(356, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1387 "Zend/zend_language_scanner.l"
-+#line 1397 "Zend/zend_language_scanner.l"
- {
- char *class_name = NULL;
-
-@@ -4262,7 +4272,7 @@ yy353:
- zendlval->type = IS_STRING;
- return T_CLASS_C;
- }
--#line 4266 "Zend/zend_language_scanner.c"
-+#line 4276 "Zend/zend_language_scanner.c"
- yy357:
- YYDEBUG(357, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -4324,11 +4334,11 @@ yy368:
- }
- YYDEBUG(369, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1129 "Zend/zend_language_scanner.l"
-+#line 1139 "Zend/zend_language_scanner.l"
- {
- return T_HALT_COMPILER;
- }
--#line 4332 "Zend/zend_language_scanner.c"
-+#line 4342 "Zend/zend_language_scanner.c"
- yy370:
- YYDEBUG(370, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -4348,11 +4358,11 @@ yy372:
- }
- YYDEBUG(373, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1113 "Zend/zend_language_scanner.l"
-+#line 1123 "Zend/zend_language_scanner.l"
- {
- return T_USE;
- }
--#line 4356 "Zend/zend_language_scanner.c"
-+#line 4366 "Zend/zend_language_scanner.c"
- yy374:
- YYDEBUG(374, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -4371,11 +4381,11 @@ yy376:
- }
- YYDEBUG(377, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1157 "Zend/zend_language_scanner.l"
-+#line 1167 "Zend/zend_language_scanner.l"
- {
- return T_UNSET;
- }
--#line 4379 "Zend/zend_language_scanner.c"
-+#line 4389 "Zend/zend_language_scanner.c"
- yy378:
- YYDEBUG(378, *YYCURSOR);
- ++YYCURSOR;
-@@ -4547,11 +4557,11 @@ yy393:
- ++YYCURSOR;
- YYDEBUG(395, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1057 "Zend/zend_language_scanner.l"
-+#line 1067 "Zend/zend_language_scanner.l"
- {
- return T_INT_CAST;
- }
--#line 4555 "Zend/zend_language_scanner.c"
-+#line 4565 "Zend/zend_language_scanner.c"
- yy396:
- YYDEBUG(396, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -4595,11 +4605,11 @@ yy401:
- ++YYCURSOR;
- YYDEBUG(404, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1061 "Zend/zend_language_scanner.l"
-+#line 1071 "Zend/zend_language_scanner.l"
- {
- return T_DOUBLE_CAST;
- }
--#line 4603 "Zend/zend_language_scanner.c"
-+#line 4613 "Zend/zend_language_scanner.c"
- yy405:
- YYDEBUG(405, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -4669,11 +4679,11 @@ yy415:
- ++YYCURSOR;
- YYDEBUG(418, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1065 "Zend/zend_language_scanner.l"
-+#line 1075 "Zend/zend_language_scanner.l"
- {
- return T_STRING_CAST;
- }
--#line 4677 "Zend/zend_language_scanner.c"
-+#line 4687 "Zend/zend_language_scanner.c"
- yy419:
- YYDEBUG(419, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -4706,11 +4716,11 @@ yy422:
- ++YYCURSOR;
- YYDEBUG(425, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1073 "Zend/zend_language_scanner.l"
-+#line 1083 "Zend/zend_language_scanner.l"
- {
- return T_ARRAY_CAST;
- }
--#line 4714 "Zend/zend_language_scanner.c"
-+#line 4724 "Zend/zend_language_scanner.c"
- yy426:
- YYDEBUG(426, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -4748,11 +4758,11 @@ yy430:
- ++YYCURSOR;
- YYDEBUG(433, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1077 "Zend/zend_language_scanner.l"
-+#line 1087 "Zend/zend_language_scanner.l"
- {
- return T_OBJECT_CAST;
- }
--#line 4756 "Zend/zend_language_scanner.c"
-+#line 4766 "Zend/zend_language_scanner.c"
- yy434:
- YYDEBUG(434, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -4793,11 +4803,11 @@ yy439:
- ++YYCURSOR;
- YYDEBUG(441, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1081 "Zend/zend_language_scanner.l"
-+#line 1091 "Zend/zend_language_scanner.l"
- {
- return T_BOOL_CAST;
- }
--#line 4801 "Zend/zend_language_scanner.c"
-+#line 4811 "Zend/zend_language_scanner.c"
- yy442:
- YYDEBUG(442, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -4841,11 +4851,11 @@ yy447:
- ++YYCURSOR;
- YYDEBUG(450, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1069 "Zend/zend_language_scanner.l"
-+#line 1079 "Zend/zend_language_scanner.l"
- {
- return T_STRING_CAST;
- }
--#line 4849 "Zend/zend_language_scanner.c"
-+#line 4859 "Zend/zend_language_scanner.c"
- yy451:
- YYDEBUG(451, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -4878,11 +4888,11 @@ yy454:
- ++YYCURSOR;
- YYDEBUG(457, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1085 "Zend/zend_language_scanner.l"
-+#line 1095 "Zend/zend_language_scanner.l"
- {
- return T_UNSET_CAST;
- }
--#line 4886 "Zend/zend_language_scanner.c"
-+#line 4896 "Zend/zend_language_scanner.c"
- yy458:
- YYDEBUG(458, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -4896,11 +4906,11 @@ yy459:
- }
- YYDEBUG(460, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1053 "Zend/zend_language_scanner.l"
-+#line 1063 "Zend/zend_language_scanner.l"
- {
- return T_VAR;
- }
--#line 4904 "Zend/zend_language_scanner.c"
-+#line 4914 "Zend/zend_language_scanner.c"
- yy461:
- YYDEBUG(461, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -4920,11 +4930,11 @@ yy463:
- }
- YYDEBUG(464, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1045 "Zend/zend_language_scanner.l"
-+#line 1055 "Zend/zend_language_scanner.l"
- {
- return T_NEW;
- }
--#line 4928 "Zend/zend_language_scanner.c"
-+#line 4938 "Zend/zend_language_scanner.c"
- yy465:
- YYDEBUG(465, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -4963,21 +4973,21 @@ yy471:
- }
- YYDEBUG(472, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1109 "Zend/zend_language_scanner.l"
-+#line 1119 "Zend/zend_language_scanner.l"
- {
- return T_NAMESPACE;
- }
--#line 4971 "Zend/zend_language_scanner.c"
-+#line 4981 "Zend/zend_language_scanner.c"
- yy473:
- YYDEBUG(473, *YYCURSOR);
- ++YYCURSOR;
- YYDEBUG(474, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1037 "Zend/zend_language_scanner.l"
-+#line 1047 "Zend/zend_language_scanner.l"
- {
- return T_PAAMAYIM_NEKUDOTAYIM;
- }
--#line 4981 "Zend/zend_language_scanner.c"
-+#line 4991 "Zend/zend_language_scanner.c"
- yy475:
- YYDEBUG(475, *YYCURSOR);
- ++YYCURSOR;
-@@ -4999,32 +5009,32 @@ yy477:
- ++YYCURSOR;
- YYDEBUG(478, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1209 "Zend/zend_language_scanner.l"
-+#line 1219 "Zend/zend_language_scanner.l"
- {
- return T_MINUS_EQUAL;
- }
--#line 5007 "Zend/zend_language_scanner.c"
-+#line 5017 "Zend/zend_language_scanner.c"
- yy479:
- YYDEBUG(479, *YYCURSOR);
- ++YYCURSOR;
- YYDEBUG(480, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1177 "Zend/zend_language_scanner.l"
-+#line 1187 "Zend/zend_language_scanner.l"
- {
- return T_DEC;
- }
--#line 5017 "Zend/zend_language_scanner.c"
-+#line 5027 "Zend/zend_language_scanner.c"
- yy481:
- YYDEBUG(481, *YYCURSOR);
- ++YYCURSOR;
- YYDEBUG(482, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1007 "Zend/zend_language_scanner.l"
-+#line 1017 "Zend/zend_language_scanner.l"
- {
- yy_push_state(ST_LOOKING_FOR_PROPERTY TSRMLS_CC);
- return T_OBJECT_OPERATOR;
- }
--#line 5028 "Zend/zend_language_scanner.c"
-+#line 5038 "Zend/zend_language_scanner.c"
- yy483:
- YYDEBUG(483, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -5069,11 +5079,11 @@ yy488:
- }
- YYDEBUG(489, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1153 "Zend/zend_language_scanner.l"
-+#line 1163 "Zend/zend_language_scanner.l"
- {
- return T_PUBLIC;
- }
--#line 5077 "Zend/zend_language_scanner.c"
-+#line 5087 "Zend/zend_language_scanner.c"
- yy490:
- YYDEBUG(490, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -5128,11 +5138,11 @@ yy497:
- }
- YYDEBUG(498, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1149 "Zend/zend_language_scanner.l"
-+#line 1159 "Zend/zend_language_scanner.l"
- {
- return T_PROTECTED;
- }
--#line 5136 "Zend/zend_language_scanner.c"
-+#line 5146 "Zend/zend_language_scanner.c"
- yy499:
- YYDEBUG(499, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -5162,11 +5172,11 @@ yy503:
- }
- YYDEBUG(504, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1145 "Zend/zend_language_scanner.l"
-+#line 1155 "Zend/zend_language_scanner.l"
- {
- return T_PRIVATE;
- }
--#line 5170 "Zend/zend_language_scanner.c"
-+#line 5180 "Zend/zend_language_scanner.c"
- yy505:
- YYDEBUG(505, *YYCURSOR);
- ++YYCURSOR;
-@@ -5175,11 +5185,11 @@ yy505:
- }
- YYDEBUG(506, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 987 "Zend/zend_language_scanner.l"
-+#line 997 "Zend/zend_language_scanner.l"
- {
- return T_PRINT;
- }
--#line 5183 "Zend/zend_language_scanner.c"
-+#line 5193 "Zend/zend_language_scanner.c"
- yy507:
- YYDEBUG(507, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -5204,11 +5214,11 @@ yy510:
- }
- YYDEBUG(511, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 979 "Zend/zend_language_scanner.l"
-+#line 989 "Zend/zend_language_scanner.l"
- {
- return T_GOTO;
- }
--#line 5212 "Zend/zend_language_scanner.c"
-+#line 5222 "Zend/zend_language_scanner.c"
- yy512:
- YYDEBUG(512, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -5232,11 +5242,11 @@ yy515:
- }
- YYDEBUG(516, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1117 "Zend/zend_language_scanner.l"
-+#line 1127 "Zend/zend_language_scanner.l"
- {
- return T_GLOBAL;
- }
--#line 5240 "Zend/zend_language_scanner.c"
-+#line 5250 "Zend/zend_language_scanner.c"
- yy517:
- YYDEBUG(517, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -5273,11 +5283,11 @@ yy523:
- }
- YYDEBUG(524, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 971 "Zend/zend_language_scanner.l"
-+#line 981 "Zend/zend_language_scanner.l"
- {
- return T_BREAK;
- }
--#line 5281 "Zend/zend_language_scanner.c"
-+#line 5291 "Zend/zend_language_scanner.c"
- yy525:
- YYDEBUG(525, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -5317,11 +5327,11 @@ yy531:
- }
- YYDEBUG(532, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 955 "Zend/zend_language_scanner.l"
-+#line 965 "Zend/zend_language_scanner.l"
- {
- return T_SWITCH;
- }
--#line 5325 "Zend/zend_language_scanner.c"
-+#line 5335 "Zend/zend_language_scanner.c"
- yy533:
- YYDEBUG(533, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -5345,11 +5355,11 @@ yy536:
- }
- YYDEBUG(537, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1133 "Zend/zend_language_scanner.l"
-+#line 1143 "Zend/zend_language_scanner.l"
- {
- return T_STATIC;
- }
--#line 5353 "Zend/zend_language_scanner.c"
-+#line 5363 "Zend/zend_language_scanner.c"
- yy538:
- YYDEBUG(538, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -5376,11 +5386,11 @@ yy541:
- }
- YYDEBUG(542, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 951 "Zend/zend_language_scanner.l"
-+#line 961 "Zend/zend_language_scanner.l"
- {
- return T_AS;
- }
--#line 5384 "Zend/zend_language_scanner.c"
-+#line 5394 "Zend/zend_language_scanner.c"
- yy543:
- YYDEBUG(543, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -5399,11 +5409,11 @@ yy545:
- }
- YYDEBUG(546, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1169 "Zend/zend_language_scanner.l"
-+#line 1179 "Zend/zend_language_scanner.l"
- {
- return T_ARRAY;
- }
--#line 5407 "Zend/zend_language_scanner.c"
-+#line 5417 "Zend/zend_language_scanner.c"
- yy547:
- YYDEBUG(547, *YYCURSOR);
- ++YYCURSOR;
-@@ -5412,11 +5422,11 @@ yy547:
- }
- YYDEBUG(548, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1261 "Zend/zend_language_scanner.l"
-+#line 1271 "Zend/zend_language_scanner.l"
- {
- return T_LOGICAL_AND;
- }
--#line 5420 "Zend/zend_language_scanner.c"
-+#line 5430 "Zend/zend_language_scanner.c"
- yy549:
- YYDEBUG(549, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -5450,11 +5460,11 @@ yy554:
- }
- YYDEBUG(555, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1137 "Zend/zend_language_scanner.l"
-+#line 1147 "Zend/zend_language_scanner.l"
- {
- return T_ABSTRACT;
- }
--#line 5458 "Zend/zend_language_scanner.c"
-+#line 5468 "Zend/zend_language_scanner.c"
- yy556:
- YYDEBUG(556, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -5478,11 +5488,11 @@ yy559:
- }
- YYDEBUG(560, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 911 "Zend/zend_language_scanner.l"
-+#line 921 "Zend/zend_language_scanner.l"
- {
- return T_WHILE;
- }
--#line 5486 "Zend/zend_language_scanner.c"
-+#line 5496 "Zend/zend_language_scanner.c"
- yy561:
- YYDEBUG(561, *YYCURSOR);
- ++YYCURSOR;
-@@ -5491,11 +5501,11 @@ yy561:
- }
- YYDEBUG(562, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 895 "Zend/zend_language_scanner.l"
-+#line 905 "Zend/zend_language_scanner.l"
- {
- return T_IF;
- }
--#line 5499 "Zend/zend_language_scanner.c"
-+#line 5509 "Zend/zend_language_scanner.c"
- yy563:
- YYDEBUG(563, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -5547,11 +5557,11 @@ yy568:
- }
- YYDEBUG(569, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1121 "Zend/zend_language_scanner.l"
-+#line 1131 "Zend/zend_language_scanner.l"
- {
- return T_ISSET;
- }
--#line 5555 "Zend/zend_language_scanner.c"
-+#line 5565 "Zend/zend_language_scanner.c"
- yy570:
- YYDEBUG(570, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -5605,11 +5615,11 @@ yy576:
- yy577:
- YYDEBUG(577, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1093 "Zend/zend_language_scanner.l"
-+#line 1103 "Zend/zend_language_scanner.l"
- {
- return T_INCLUDE;
- }
--#line 5613 "Zend/zend_language_scanner.c"
-+#line 5623 "Zend/zend_language_scanner.c"
- yy578:
- YYDEBUG(578, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -5638,11 +5648,11 @@ yy582:
- }
- YYDEBUG(583, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1097 "Zend/zend_language_scanner.l"
-+#line 1107 "Zend/zend_language_scanner.l"
- {
- return T_INCLUDE_ONCE;
- }
--#line 5646 "Zend/zend_language_scanner.c"
-+#line 5656 "Zend/zend_language_scanner.c"
- yy584:
- YYDEBUG(584, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -5676,11 +5686,11 @@ yy589:
- }
- YYDEBUG(590, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 995 "Zend/zend_language_scanner.l"
-+#line 1005 "Zend/zend_language_scanner.l"
- {
- return T_INTERFACE;
- }
--#line 5684 "Zend/zend_language_scanner.c"
-+#line 5694 "Zend/zend_language_scanner.c"
- yy591:
- YYDEBUG(591, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -5719,11 +5729,11 @@ yy597:
- }
- YYDEBUG(598, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 947 "Zend/zend_language_scanner.l"
-+#line 957 "Zend/zend_language_scanner.l"
- {
- return T_INSTANCEOF;
- }
--#line 5727 "Zend/zend_language_scanner.c"
-+#line 5737 "Zend/zend_language_scanner.c"
- yy599:
- YYDEBUG(599, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -5767,11 +5777,11 @@ yy606:
- }
- YYDEBUG(607, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1003 "Zend/zend_language_scanner.l"
-+#line 1013 "Zend/zend_language_scanner.l"
- {
- return T_IMPLEMENTS;
- }
--#line 5775 "Zend/zend_language_scanner.c"
-+#line 5785 "Zend/zend_language_scanner.c"
- yy608:
- YYDEBUG(608, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -5791,11 +5801,11 @@ yy610:
- }
- YYDEBUG(611, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 883 "Zend/zend_language_scanner.l"
-+#line 893 "Zend/zend_language_scanner.l"
- {
- return T_TRY;
- }
--#line 5799 "Zend/zend_language_scanner.c"
-+#line 5809 "Zend/zend_language_scanner.c"
- yy612:
- YYDEBUG(612, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -5814,11 +5824,11 @@ yy614:
- }
- YYDEBUG(615, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 891 "Zend/zend_language_scanner.l"
-+#line 901 "Zend/zend_language_scanner.l"
- {
- return T_THROW;
- }
--#line 5822 "Zend/zend_language_scanner.c"
-+#line 5832 "Zend/zend_language_scanner.c"
- yy616:
- YYDEBUG(616, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -5879,11 +5889,11 @@ yy622:
- yy623:
- YYDEBUG(623, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1101 "Zend/zend_language_scanner.l"
-+#line 1111 "Zend/zend_language_scanner.l"
- {
- return T_REQUIRE;
- }
--#line 5887 "Zend/zend_language_scanner.c"
-+#line 5897 "Zend/zend_language_scanner.c"
- yy624:
- YYDEBUG(624, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -5912,11 +5922,11 @@ yy628:
- }
- YYDEBUG(629, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1105 "Zend/zend_language_scanner.l"
-+#line 1115 "Zend/zend_language_scanner.l"
- {
- return T_REQUIRE_ONCE;
- }
--#line 5920 "Zend/zend_language_scanner.c"
-+#line 5930 "Zend/zend_language_scanner.c"
- yy630:
- YYDEBUG(630, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -5935,11 +5945,11 @@ yy632:
- }
- YYDEBUG(633, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 879 "Zend/zend_language_scanner.l"
-+#line 889 "Zend/zend_language_scanner.l"
- {
- return T_RETURN;
- }
--#line 5943 "Zend/zend_language_scanner.c"
-+#line 5953 "Zend/zend_language_scanner.c"
- yy634:
- YYDEBUG(634, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -6020,11 +6030,11 @@ yy643:
- }
- YYDEBUG(644, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 975 "Zend/zend_language_scanner.l"
-+#line 985 "Zend/zend_language_scanner.l"
- {
- return T_CONTINUE;
- }
--#line 6028 "Zend/zend_language_scanner.c"
-+#line 6038 "Zend/zend_language_scanner.c"
- yy645:
- YYDEBUG(645, *YYCURSOR);
- ++YYCURSOR;
-@@ -6033,11 +6043,11 @@ yy645:
- }
- YYDEBUG(646, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 875 "Zend/zend_language_scanner.l"
-+#line 885 "Zend/zend_language_scanner.l"
- {
- return T_CONST;
- }
--#line 6041 "Zend/zend_language_scanner.c"
-+#line 6051 "Zend/zend_language_scanner.c"
- yy647:
- YYDEBUG(647, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -6062,11 +6072,11 @@ yy650:
- }
- YYDEBUG(651, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1049 "Zend/zend_language_scanner.l"
-+#line 1059 "Zend/zend_language_scanner.l"
- {
- return T_CLONE;
- }
--#line 6070 "Zend/zend_language_scanner.c"
-+#line 6080 "Zend/zend_language_scanner.c"
- yy652:
- YYDEBUG(652, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -6080,11 +6090,11 @@ yy653:
- }
- YYDEBUG(654, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 991 "Zend/zend_language_scanner.l"
-+#line 1001 "Zend/zend_language_scanner.l"
- {
- return T_CLASS;
- }
--#line 6088 "Zend/zend_language_scanner.c"
-+#line 6098 "Zend/zend_language_scanner.c"
- yy655:
- YYDEBUG(655, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -6104,11 +6114,11 @@ yy657:
- }
- YYDEBUG(658, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 963 "Zend/zend_language_scanner.l"
-+#line 973 "Zend/zend_language_scanner.l"
- {
- return T_CASE;
- }
--#line 6112 "Zend/zend_language_scanner.c"
-+#line 6122 "Zend/zend_language_scanner.c"
- yy659:
- YYDEBUG(659, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -6122,11 +6132,11 @@ yy660:
- }
- YYDEBUG(661, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 887 "Zend/zend_language_scanner.l"
-+#line 897 "Zend/zend_language_scanner.l"
- {
- return T_CATCH;
- }
--#line 6130 "Zend/zend_language_scanner.c"
-+#line 6140 "Zend/zend_language_scanner.c"
- yy662:
- YYDEBUG(662, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -6177,11 +6187,11 @@ yy670:
- }
- YYDEBUG(671, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 871 "Zend/zend_language_scanner.l"
-+#line 881 "Zend/zend_language_scanner.l"
- {
- return T_FUNCTION;
- }
--#line 6185 "Zend/zend_language_scanner.c"
-+#line 6195 "Zend/zend_language_scanner.c"
- yy672:
- YYDEBUG(672, *YYCURSOR);
- ++YYCURSOR;
-@@ -6205,11 +6215,11 @@ yy672:
- yy673:
- YYDEBUG(673, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 923 "Zend/zend_language_scanner.l"
-+#line 933 "Zend/zend_language_scanner.l"
- {
- return T_FOR;
- }
--#line 6213 "Zend/zend_language_scanner.c"
-+#line 6223 "Zend/zend_language_scanner.c"
- yy674:
- YYDEBUG(674, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -6233,11 +6243,11 @@ yy677:
- }
- YYDEBUG(678, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 931 "Zend/zend_language_scanner.l"
-+#line 941 "Zend/zend_language_scanner.l"
- {
- return T_FOREACH;
- }
--#line 6241 "Zend/zend_language_scanner.c"
-+#line 6251 "Zend/zend_language_scanner.c"
- yy679:
- YYDEBUG(679, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -6256,11 +6266,11 @@ yy681:
- }
- YYDEBUG(682, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1141 "Zend/zend_language_scanner.l"
-+#line 1151 "Zend/zend_language_scanner.l"
- {
- return T_FINAL;
- }
--#line 6264 "Zend/zend_language_scanner.c"
-+#line 6274 "Zend/zend_language_scanner.c"
- yy683:
- YYDEBUG(683, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -6291,11 +6301,11 @@ yy685:
- }
- YYDEBUG(686, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 919 "Zend/zend_language_scanner.l"
-+#line 929 "Zend/zend_language_scanner.l"
- {
- return T_DO;
- }
--#line 6299 "Zend/zend_language_scanner.c"
-+#line 6309 "Zend/zend_language_scanner.c"
- yy687:
- YYDEBUG(687, *YYCURSOR);
- ++YYCURSOR;
-@@ -6304,11 +6314,11 @@ yy687:
- }
- YYDEBUG(688, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 867 "Zend/zend_language_scanner.l"
-+#line 877 "Zend/zend_language_scanner.l"
- {
- return T_EXIT;
- }
--#line 6312 "Zend/zend_language_scanner.c"
-+#line 6322 "Zend/zend_language_scanner.c"
- yy689:
- YYDEBUG(689, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -6343,11 +6353,11 @@ yy694:
- }
- YYDEBUG(695, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 967 "Zend/zend_language_scanner.l"
-+#line 977 "Zend/zend_language_scanner.l"
- {
- return T_DEFAULT;
- }
--#line 6351 "Zend/zend_language_scanner.c"
-+#line 6361 "Zend/zend_language_scanner.c"
- yy696:
- YYDEBUG(696, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -6371,11 +6381,11 @@ yy699:
- }
- YYDEBUG(700, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 939 "Zend/zend_language_scanner.l"
-+#line 949 "Zend/zend_language_scanner.l"
- {
- return T_DECLARE;
- }
--#line 6379 "Zend/zend_language_scanner.c"
-+#line 6389 "Zend/zend_language_scanner.c"
- yy701:
- YYDEBUG(701, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -6455,11 +6465,11 @@ yy712:
- }
- YYDEBUG(713, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 999 "Zend/zend_language_scanner.l"
-+#line 1009 "Zend/zend_language_scanner.l"
- {
- return T_EXTENDS;
- }
--#line 6463 "Zend/zend_language_scanner.c"
-+#line 6473 "Zend/zend_language_scanner.c"
- yy714:
- YYDEBUG(714, *YYCURSOR);
- ++YYCURSOR;
-@@ -6468,11 +6478,11 @@ yy714:
- }
- YYDEBUG(715, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 863 "Zend/zend_language_scanner.l"
-+#line 873 "Zend/zend_language_scanner.l"
- {
- return T_EXIT;
- }
--#line 6476 "Zend/zend_language_scanner.c"
-+#line 6486 "Zend/zend_language_scanner.c"
- yy716:
- YYDEBUG(716, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -6486,11 +6496,11 @@ yy717:
- }
- YYDEBUG(718, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1089 "Zend/zend_language_scanner.l"
-+#line 1099 "Zend/zend_language_scanner.l"
- {
- return T_EVAL;
- }
--#line 6494 "Zend/zend_language_scanner.c"
-+#line 6504 "Zend/zend_language_scanner.c"
- yy719:
- YYDEBUG(719, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -6560,11 +6570,11 @@ yy728:
- }
- YYDEBUG(729, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 915 "Zend/zend_language_scanner.l"
-+#line 925 "Zend/zend_language_scanner.l"
- {
- return T_ENDWHILE;
- }
--#line 6568 "Zend/zend_language_scanner.c"
-+#line 6578 "Zend/zend_language_scanner.c"
- yy730:
- YYDEBUG(730, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -6593,11 +6603,11 @@ yy734:
- }
- YYDEBUG(735, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 959 "Zend/zend_language_scanner.l"
-+#line 969 "Zend/zend_language_scanner.l"
- {
- return T_ENDSWITCH;
- }
--#line 6601 "Zend/zend_language_scanner.c"
-+#line 6611 "Zend/zend_language_scanner.c"
- yy736:
- YYDEBUG(736, *YYCURSOR);
- ++YYCURSOR;
-@@ -6606,11 +6616,11 @@ yy736:
- }
- YYDEBUG(737, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 903 "Zend/zend_language_scanner.l"
-+#line 913 "Zend/zend_language_scanner.l"
- {
- return T_ENDIF;
- }
--#line 6614 "Zend/zend_language_scanner.c"
-+#line 6624 "Zend/zend_language_scanner.c"
- yy738:
- YYDEBUG(738, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -6639,11 +6649,11 @@ yy739:
- yy740:
- YYDEBUG(740, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 927 "Zend/zend_language_scanner.l"
-+#line 937 "Zend/zend_language_scanner.l"
- {
- return T_ENDFOR;
- }
--#line 6647 "Zend/zend_language_scanner.c"
-+#line 6657 "Zend/zend_language_scanner.c"
- yy741:
- YYDEBUG(741, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -6667,11 +6677,11 @@ yy744:
- }
- YYDEBUG(745, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 935 "Zend/zend_language_scanner.l"
-+#line 945 "Zend/zend_language_scanner.l"
- {
- return T_ENDFOREACH;
- }
--#line 6675 "Zend/zend_language_scanner.c"
-+#line 6685 "Zend/zend_language_scanner.c"
- yy746:
- YYDEBUG(746, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -6705,11 +6715,11 @@ yy751:
- }
- YYDEBUG(752, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 943 "Zend/zend_language_scanner.l"
-+#line 953 "Zend/zend_language_scanner.l"
- {
- return T_ENDDECLARE;
- }
--#line 6713 "Zend/zend_language_scanner.c"
-+#line 6723 "Zend/zend_language_scanner.c"
- yy753:
- YYDEBUG(753, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -6728,11 +6738,11 @@ yy755:
- }
- YYDEBUG(756, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1125 "Zend/zend_language_scanner.l"
-+#line 1135 "Zend/zend_language_scanner.l"
- {
- return T_EMPTY;
- }
--#line 6736 "Zend/zend_language_scanner.c"
-+#line 6746 "Zend/zend_language_scanner.c"
- yy757:
- YYDEBUG(757, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -6761,11 +6771,11 @@ yy758:
- yy759:
- YYDEBUG(759, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 907 "Zend/zend_language_scanner.l"
-+#line 917 "Zend/zend_language_scanner.l"
- {
- return T_ELSE;
- }
--#line 6769 "Zend/zend_language_scanner.c"
-+#line 6779 "Zend/zend_language_scanner.c"
- yy760:
- YYDEBUG(760, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -6779,11 +6789,11 @@ yy761:
- }
- YYDEBUG(762, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 899 "Zend/zend_language_scanner.l"
-+#line 909 "Zend/zend_language_scanner.l"
- {
- return T_ELSEIF;
- }
--#line 6787 "Zend/zend_language_scanner.c"
-+#line 6797 "Zend/zend_language_scanner.c"
- yy763:
- YYDEBUG(763, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -6797,11 +6807,11 @@ yy764:
- }
- YYDEBUG(765, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 983 "Zend/zend_language_scanner.l"
-+#line 993 "Zend/zend_language_scanner.l"
- {
- return T_ECHO;
- }
--#line 6805 "Zend/zend_language_scanner.c"
-+#line 6815 "Zend/zend_language_scanner.c"
- }
- /* *********************************** */
- yyc_ST_LOOKING_FOR_PROPERTY:
-@@ -6874,7 +6884,7 @@ yy768:
- yy769:
- YYDEBUG(769, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1012 "Zend/zend_language_scanner.l"
-+#line 1022 "Zend/zend_language_scanner.l"
- {
- zendlval->value.str.val = yytext; /* no copying - intentional */
- zendlval->value.str.len = yyleng;
-@@ -6882,7 +6892,7 @@ yy769:
- HANDLE_NEWLINES(yytext, yyleng);
- return T_WHITESPACE;
- }
--#line 6886 "Zend/zend_language_scanner.c"
-+#line 6896 "Zend/zend_language_scanner.c"
- yy770:
- YYDEBUG(770, *YYCURSOR);
- ++YYCURSOR;
-@@ -6890,13 +6900,13 @@ yy770:
- yy771:
- YYDEBUG(771, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1031 "Zend/zend_language_scanner.l"
-+#line 1041 "Zend/zend_language_scanner.l"
- {
- yyless(0);
- yy_pop_state(TSRMLS_C);
- goto restart;
- }
--#line 6900 "Zend/zend_language_scanner.c"
-+#line 6910 "Zend/zend_language_scanner.c"
- yy772:
- YYDEBUG(772, *YYCURSOR);
- ++YYCURSOR;
-@@ -6905,14 +6915,14 @@ yy772:
- yy773:
- YYDEBUG(773, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1024 "Zend/zend_language_scanner.l"
-+#line 1034 "Zend/zend_language_scanner.l"
- {
- yy_pop_state(TSRMLS_C);
- zend_copy_value(zendlval, yytext, yyleng);
- zendlval->type = IS_STRING;
- return T_STRING;
- }
--#line 6916 "Zend/zend_language_scanner.c"
-+#line 6926 "Zend/zend_language_scanner.c"
- yy774:
- YYDEBUG(774, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -6933,11 +6943,11 @@ yy777:
- ++YYCURSOR;
- YYDEBUG(778, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1020 "Zend/zend_language_scanner.l"
-+#line 1030 "Zend/zend_language_scanner.l"
- {
- return T_OBJECT_OPERATOR;
- }
--#line 6941 "Zend/zend_language_scanner.c"
-+#line 6951 "Zend/zend_language_scanner.c"
- yy779:
- YYDEBUG(779, *YYCURSOR);
- ++YYCURSOR;
-@@ -7007,7 +7017,7 @@ yy783:
- yy784:
- YYDEBUG(784, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1303 "Zend/zend_language_scanner.l"
-+#line 1313 "Zend/zend_language_scanner.l"
- {
- zend_copy_value(zendlval, yytext, yyleng);
- zendlval->type = IS_STRING;
-@@ -7015,20 +7025,20 @@ yy784:
- yy_push_state(ST_IN_SCRIPTING TSRMLS_CC);
- return T_STRING_VARNAME;
- }
--#line 7019 "Zend/zend_language_scanner.c"
-+#line 7029 "Zend/zend_language_scanner.c"
- yy785:
- YYDEBUG(785, *YYCURSOR);
- ++YYCURSOR;
- YYDEBUG(786, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1312 "Zend/zend_language_scanner.l"
-+#line 1322 "Zend/zend_language_scanner.l"
- {
- yyless(0);
- yy_pop_state(TSRMLS_C);
- yy_push_state(ST_IN_SCRIPTING TSRMLS_CC);
- goto restart;
- }
--#line 7032 "Zend/zend_language_scanner.c"
-+#line 7042 "Zend/zend_language_scanner.c"
- yy787:
- YYDEBUG(787, *YYCURSOR);
- ++YYCURSOR;
-@@ -7050,7 +7060,7 @@ yyc_ST_NOWDOC:
- ++YYCURSOR;
- YYDEBUG(792, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 2146 "Zend/zend_language_scanner.l"
-+#line 2156 "Zend/zend_language_scanner.l"
- {
- int newline = 0;
-
-@@ -7105,7 +7115,7 @@ nowdoc_scan_done:
- HANDLE_NEWLINES(yytext, yyleng - newline);
- return T_ENCAPSED_AND_WHITESPACE;
- }
--#line 7109 "Zend/zend_language_scanner.c"
-+#line 7119 "Zend/zend_language_scanner.c"
- /* *********************************** */
- yyc_ST_VAR_OFFSET:
- {
-@@ -7205,7 +7215,7 @@ yy795:
- yy796:
- YYDEBUG(796, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1362 "Zend/zend_language_scanner.l"
-+#line 1372 "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);
-@@ -7217,7 +7227,7 @@ yy796:
- }
- return T_NUM_STRING;
- }
--#line 7221 "Zend/zend_language_scanner.c"
-+#line 7231 "Zend/zend_language_scanner.c"
- yy797:
- YYDEBUG(797, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -7237,23 +7247,23 @@ yy798:
- yy799:
- YYDEBUG(799, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1672 "Zend/zend_language_scanner.l"
-+#line 1682 "Zend/zend_language_scanner.l"
- {
- /* Only '[' can be valid, but returning other tokens will allow a more explicit parse error */
- return yytext[0];
- }
--#line 7246 "Zend/zend_language_scanner.c"
-+#line 7256 "Zend/zend_language_scanner.c"
- yy800:
- YYDEBUG(800, *YYCURSOR);
- ++YYCURSOR;
- YYDEBUG(801, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1667 "Zend/zend_language_scanner.l"
-+#line 1677 "Zend/zend_language_scanner.l"
- {
- yy_pop_state(TSRMLS_C);
- return ']';
- }
--#line 7257 "Zend/zend_language_scanner.c"
-+#line 7267 "Zend/zend_language_scanner.c"
- yy802:
- YYDEBUG(802, *YYCURSOR);
- yych = *++YYCURSOR;
-@@ -7263,14 +7273,14 @@ yy803:
- ++YYCURSOR;
- YYDEBUG(804, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1677 "Zend/zend_language_scanner.l"
-+#line 1687 "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 7274 "Zend/zend_language_scanner.c"
-+#line 7284 "Zend/zend_language_scanner.c"
- yy805:
- YYDEBUG(805, *YYCURSOR);
- ++YYCURSOR;
-@@ -7279,19 +7289,19 @@ yy805:
- yy806:
- YYDEBUG(806, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1684 "Zend/zend_language_scanner.l"
-+#line 1694 "Zend/zend_language_scanner.l"
- {
- zend_copy_value(zendlval, yytext, yyleng);
- zendlval->type = IS_STRING;
- return T_STRING;
- }
--#line 7289 "Zend/zend_language_scanner.c"
-+#line 7299 "Zend/zend_language_scanner.c"
- yy807:
- YYDEBUG(807, *YYCURSOR);
- ++YYCURSOR;
- YYDEBUG(808, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 2202 "Zend/zend_language_scanner.l"
-+#line 2212 "Zend/zend_language_scanner.l"
- {
- if (YYCURSOR > YYLIMIT) {
- return 0;
-@@ -7300,7 +7310,7 @@ yy807:
- zend_error(E_COMPILE_WARNING,"Unexpected character in input: '%c' (ASCII=%d) state=%d", yytext[0], yytext[0], YYSTATE);
- goto restart;
- }
--#line 7304 "Zend/zend_language_scanner.c"
-+#line 7314 "Zend/zend_language_scanner.c"
- yy809:
- YYDEBUG(809, *YYCURSOR);
- ++YYCURSOR;
-@@ -7336,13 +7346,13 @@ yy811:
- yy813:
- YYDEBUG(813, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1661 "Zend/zend_language_scanner.l"
-+#line 1671 "Zend/zend_language_scanner.l"
- {
- zend_copy_value(zendlval, (yytext+1), (yyleng-1));
- zendlval->type = IS_STRING;
- return T_VARIABLE;
- }
--#line 7346 "Zend/zend_language_scanner.c"
-+#line 7356 "Zend/zend_language_scanner.c"
- yy814:
- YYDEBUG(814, *YYCURSOR);
- ++YYCURSOR;
-@@ -7374,14 +7384,14 @@ yy818:
- yy820:
- YYDEBUG(820, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
--#line 1374 "Zend/zend_language_scanner.l"
-+#line 1384 "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 7385 "Zend/zend_language_scanner.c"
-+#line 7395 "Zend/zend_language_scanner.c"
- yy821:
- YYDEBUG(821, *YYCURSOR);
- ++YYCURSOR;
-@@ -7394,6 +7404,6 @@ yy821:
- goto yy820;
- }
- }
--#line 2211 "Zend/zend_language_scanner.l"
-+#line 2221 "Zend/zend_language_scanner.l"
-
- }
--- a/Zend/zend_language_scanner.l
+++ b/Zend/zend_language_scanner.l
@@ -227,6 +227,12 @@ ZEND_API void zend_restore_lexical_state
diff --git a/debian/patches/fix-open_basedir-with-separator-r305698.patch b/debian/patches/fix-open_basedir-with-separator-r305698.patch
deleted file mode 100644
index 9ae37d3..0000000
--- a/debian/patches/fix-open_basedir-with-separator-r305698.patch
+++ /dev/null
@@ -1,21 +0,0 @@
---- a/main/fopen_wrappers.c
-+++ b/main/fopen_wrappers.c
-@@ -223,6 +223,9 @@ PHPAPI int php_check_specific_open_based
- resolved_basedir[resolved_basedir_len] = PHP_DIR_SEPARATOR;
- resolved_basedir[++resolved_basedir_len] = '\0';
- }
-+ } else {
-+ resolved_basedir[resolved_basedir_len++] = PHP_DIR_SEPARATOR;
-+ resolved_basedir[resolved_basedir_len] = '\0';
- }
-
- resolved_name_len = strlen(resolved_name);
-@@ -240,7 +243,7 @@ PHPAPI int php_check_specific_open_based
- if (strncmp(resolved_basedir, resolved_name, resolved_basedir_len) == 0) {
- #endif
- if (resolved_name_len > resolved_basedir_len &&
-- resolved_name[resolved_basedir_len] != PHP_DIR_SEPARATOR) {
-+ resolved_name[resolved_basedir_len - 1] != PHP_DIR_SEPARATOR) {
- return -1;
- } else {
- /* File is in the right directory */
diff --git a/debian/patches/fix-segfault-when-extending-SplFixedArray.patch b/debian/patches/fix-segfault-when-extending-SplFixedArray.patch
deleted file mode 100644
index a714bd5..0000000
--- a/debian/patches/fix-segfault-when-extending-SplFixedArray.patch
+++ /dev/null
@@ -1,40 +0,0 @@
---- /dev/null
-+++ b/ext/spl/tests/bug53362.phpt
-@@ -0,0 +1,22 @@
-+--TEST--
-+Bug #53362 (Segmentation fault when extending SplFixedArray)
-+--FILE--
-+<?php
-+
-+class obj extends SplFixedArray{
-+ public function offsetSet($offset, $value) {
-+ var_dump($offset);
-+ }
-+}
-+
-+$obj = new obj;
-+
-+$obj[]=2;
-+$obj[]=2;
-+$obj[]=2;
-+
-+?>
-+--EXPECTF--
-+NULL
-+NULL
-+NULL
---- a/ext/spl/spl_fixedarray.c
-+++ b/ext/spl/spl_fixedarray.c
-@@ -409,7 +409,11 @@ static void spl_fixedarray_object_write_
- intern = (spl_fixedarray_object *)zend_object_store_get_object(object TSRMLS_CC);
-
- if (intern->fptr_offset_set) {
-- SEPARATE_ARG_IF_REF(offset);
-+ if (!offset) {
-+ ALLOC_INIT_ZVAL(offset);
-+ } else {
-+ SEPARATE_ARG_IF_REF(offset);
-+ }
- SEPARATE_ARG_IF_REF(value);
- zend_call_method_with_2_params(&object, intern->std.ce, &intern->fptr_offset_set, "offsetSet", NULL, offset, value);
- zval_ptr_dtor(&value);
diff --git a/debian/patches/fix-sqlite3-columnName-segfaults-on-bad-column_number.patch b/debian/patches/fix-sqlite3-columnName-segfaults-on-bad-column_number.patch
deleted file mode 100644
index b6de540..0000000
--- a/debian/patches/fix-sqlite3-columnName-segfaults-on-bad-column_number.patch
+++ /dev/null
@@ -1,57 +0,0 @@
---- /dev/null
-+++ b/ext/sqlite3/tests/bug53463.phpt
-@@ -0,0 +1,28 @@
-+--TEST--
-+Bug #53463 (sqlite3 columnName() segfaults on bad column_number)
-+--FILE--
-+<?php
-+
-+$db = new SQLite3(':memory:');
-+
-+$db->exec('CREATE TABLE test (whatever INTEGER)');
-+$db->exec('INSERT INTO test (whatever) VALUES (1)');
-+
-+$result = $db->query('SELECT * FROM test');
-+while ($row = $result->fetchArray(SQLITE3_NUM)) {
-+ var_dump($result->columnName(0)); // string(8) "whatever"
-+
-+ // Seems returning false will be most appropriate.
-+ var_dump($result->columnName(3)); // Segmentation fault
-+}
-+
-+$result->finalize();
-+$db->close();
-+
-+echo "Done\n";
-+
-+?>
-+--EXPECT--
-+string(8) "whatever"
-+bool(false)
-+Done
-\ No newline at end of file
---- a/ext/sqlite3/sqlite3.c
-+++ b/ext/sqlite3/sqlite3.c
-@@ -1532,6 +1532,7 @@ PHP_METHOD(sqlite3result, columnName)
- php_sqlite3_result *result_obj;
- zval *object = getThis();
- long column = 0;
-+ char *column_name;
- result_obj = (php_sqlite3_result *)zend_object_store_get_object(object TSRMLS_CC);
-
- SQLITE3_CHECK_INITIALIZED(result_obj->db_obj, result_obj->stmt_obj->initialised, SQLite3Result)
-@@ -1539,8 +1540,13 @@ PHP_METHOD(sqlite3result, columnName)
- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "l", &column) == FAILURE) {
- return;
- }
-+ column_name = (char*) sqlite3_column_name(result_obj->stmt_obj->stmt, column);
-
-- RETVAL_STRING((char*)sqlite3_column_name(result_obj->stmt_obj->stmt, column), 1);
-+ if (column_name == NULL) {
-+ RETURN_FALSE;
-+ }
-+
-+ RETVAL_STRING(column_name, 1);
- }
- /* }}} */
-
diff --git a/debian/patches/fix_broken_sha2_test.patch b/debian/patches/fix_broken_sha2_test.patch
index 4e1fa86..72c0c11 100644
--- a/debian/patches/fix_broken_sha2_test.patch
+++ b/debian/patches/fix_broken_sha2_test.patch
@@ -37,4 +37,3 @@
#else
exit(0);
#endif
-
diff --git a/debian/patches/fix_crash_in_GC.patch b/debian/patches/fix_crash_in_GC.patch
deleted file mode 100644
index 539d974..0000000
--- a/debian/patches/fix_crash_in_GC.patch
+++ /dev/null
@@ -1,55 +0,0 @@
---- a/Zend/zend_execute.c
-+++ b/Zend/zend_execute.c
-@@ -714,8 +714,8 @@ static inline zval* zend_assign_to_varia
- ALLOC_ZVAL(variable_ptr);
- *variable_ptr_ptr = variable_ptr;
- *variable_ptr = *value;
-- zval_copy_ctor(variable_ptr);
- Z_SET_REFCOUNT_P(variable_ptr, 1);
-+ zval_copy_ctor(variable_ptr);
- } else {
- *variable_ptr_ptr = value;
- Z_ADDREF_P(value);
---- /dev/null
-+++ b/Zend/tests/gc_032.phpt
-@@ -0,0 +1,40 @@
-+--TEST--
-+GC 032: Crash in GC because of invalid reference counting
-+--FILE--
-+<?php
-+$a = array();
-+$b =& $a;
-+$a[0] = $a;
-+debug_zval_dump($a);
-+$a = array(array());
-+$b =& $a;
-+$a[0][0] = $a;
-+debug_zval_dump($a);
-+?>
-+--EXPECT--
-+array(1) refcount(1){
-+ [0]=>
-+ array(1) refcount(3){
-+ [0]=>
-+ array(1) refcount(3){
-+ [0]=>
-+ *RECURSION*
-+ }
-+ }
-+}
-+array(1) refcount(1){
-+ [0]=>
-+ array(1) refcount(3){
-+ [0]=>
-+ array(1) refcount(1){
-+ [0]=>
-+ array(1) refcount(3){
-+ [0]=>
-+ array(1) refcount(1){
-+ [0]=>
-+ *RECURSION*
-+ }
-+ }
-+ }
-+ }
-+}
diff --git a/debian/patches/fpm-config.patch b/debian/patches/fpm-config.patch
index 0a5091c..e279251 100644
--- a/debian/patches/fpm-config.patch
+++ b/debian/patches/fpm-config.patch
@@ -4,34 +4,33 @@ Origin: vendor
Forwarded: not-needed
Last-Update: 2010-07-30
-Index: php-5.3.3/sapi/fpm/php-fpm.conf.in
-===================================================================
---- php-5.3.3.orig/sapi/fpm/php-fpm.conf.in
-+++ php-5.3.3/sapi/fpm/php-fpm.conf.in
-@@ -8,7 +8,7 @@
- ; Include one or more files. If glob(3) exists, it is used to include a bunch of
- ; files from a glob(3) pattern. This directive can be used everywhere in the
- ; file.
--;include=@EXPANDED_SYSCONFDIR@/fpm.d/*.conf
+--- a/sapi/fpm/php-fpm.conf.in
++++ b/sapi/fpm/php-fpm.conf.in
+@@ -12,7 +12,7 @@
+ ; Relative path can also be used. They will be prefixed by:
+ ; - the global prefix if it's been set (-p arguement)
+ ; - @prefix@ otherwise
+-;include=etc/fpm.d/*.conf
+;include=@EXPANDED_SYSCONFDIR@/php5/fpm/*.conf
;;;;;;;;;;;;;;;;;;
; Global Options ;
-@@ -17,11 +17,11 @@
- [global]
+@@ -22,12 +22,12 @@
; Pid file
+ ; Note: the default prefix is @EXPANDED_LOCALSTATEDIR@
; Default Value: none
--;pid = @EXPANDED_LOCALSTATEDIR@/run/php-fpm.pid
+-;pid = run/php-fpm.pid
+pid = @EXPANDED_LOCALSTATEDIR@/run/php5-fpm.pid
; Error log file
- ; Default Value: @EXPANDED_LOCALSTATEDIR@/log/php-fpm.log
--;error_log = @EXPANDED_LOCALSTATEDIR@/log/php-fpm.log
+ ; Note: the default prefix is @EXPANDED_LOCALSTATEDIR@
+ ; Default Value: log/php-fpm.log
+-;error_log = log/php-fpm.log
+error_log = @EXPANDED_LOCALSTATEDIR@/log/php5-fpm.log
; Log level
; Possible Values: alert, error, warning, notice, debug
-@@ -61,6 +61,10 @@
+@@ -67,6 +67,10 @@
; used in logs and stats. There is no limitation on the number of pools which
; FPM can handle. Your system will tell you anyway :)
@@ -40,9 +39,9 @@ Index: php-5.3.3/sapi/fpm/php-fpm.conf.in
+include=@EXPANDED_SYSCONFDIR@/php5/fpm/pool.d/*.conf
+
; Start a new pool named 'www'.
- [www]
-
-@@ -138,12 +142,12 @@ pm.max_children = 50
+ ; the variable $pool can we used in any directive and will be replaced by the
+ ; pool name ('www' here)
+@@ -159,12 +163,12 @@ pm.max_children = 50
; 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'
@@ -57,9 +56,9 @@ Index: php-5.3.3/sapi/fpm/php-fpm.conf.in
; 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
-@@ -234,7 +238,7 @@ pm.max_children = 50
-
- ; Chdir to this directory at the start. This value must be an absolute path.
+@@ -264,7 +268,7 @@ pm.max_children = 50
+ ; Chdir to this directory at the start.
+ ; Note: relative path can be used.
; Default Value: current directory or / when chroot
-;chdir = /var/www
+chdir = /var/www
diff --git a/debian/patches/fpm_gcc_atomics.patch b/debian/patches/fpm_gcc_atomics.patch
deleted file mode 100644
index 5315e3d..0000000
--- a/debian/patches/fpm_gcc_atomics.patch
+++ /dev/null
@@ -1,31 +0,0 @@
-Description: Use GCC's atomic builtins in the FPM SAPI to allow it to
- build everywhere.
-Origin: vendor
-Forwarded: http://bugs.php.net/52407
-Last-Update: 2010-07-28
-
-Index: php-5.3.3/sapi/fpm/fpm/fpm_atomic.h
-===================================================================
---- php-5.3.3.orig/sapi/fpm/fpm/fpm_atomic.h
-+++ php-5.3.3/sapi/fpm/fpm/fpm_atomic.h
-@@ -12,7 +12,19 @@
- #endif
- #include <sched.h>
-
--#if ( __i386__ || __i386 )
-+#if (__GNUC__) && (__GNUC__ >= 4 && __GNUC_MINOR__ >= 1)
-+
-+/**
-+ * all the cases below (as provided by upstream) define:
-+ * word as atomic_int_t, and
-+ * unsigned word as atomic_uint_t
-+ * and only use volatile atomic_uint_t as atomic_t
-+ */
-+
-+typedef volatile unsigned long atomic_t;
-+#define atomic_cmp_set(a,b,c) __sync_bool_compare_and_swap(a,b,c)
-+
-+#elif ( __i386__ || __i386 )
-
- typedef int32_t atomic_int_t;
- typedef uint32_t atomic_uint_t;
diff --git a/debian/patches/gentoo/009_ob-memory-leaks.patch b/debian/patches/gentoo/009_ob-memory-leaks.patch
index 8f96b7d..49b393a 100644
--- a/debian/patches/gentoo/009_ob-memory-leaks.patch
+++ b/debian/patches/gentoo/009_ob-memory-leaks.patch
@@ -5,29 +5,31 @@ Fixed memory leak in ob_get_clean/ob_get_flush.
--- a/main/output.c
+++ b/main/output.c
-@@ -816,10 +816,12 @@ PHP_FUNCTION(ob_end_flush)
-
+@@ -809,11 +809,13 @@ PHP_FUNCTION(ob_clean)
+
if (!OG(ob_nesting_level)) {
- php_error_docref("ref.outcontrol" TSRMLS_CC, E_NOTICE, "failed to delete and flush buffer. No buffer to delete or flush.");
+ php_error_docref("ref.outcontrol" TSRMLS_CC, E_NOTICE, "failed to delete buffer. No buffer to delete");
+ zval_dtor(return_value);
RETURN_FALSE;
}
- if (OG(ob_nesting_level) && !OG(active_ob_buffer).status && !OG(active_ob_buffer).erase) {
- php_error_docref("ref.outcontrol" TSRMLS_CC, E_NOTICE, "failed to delete buffer %s.", OG(active_ob_buffer).handler_name);
+
+ if (!OG(active_ob_buffer).status && !OG(active_ob_buffer).erase) {
+ php_error_docref("ref.outcontrol" TSRMLS_CC, E_NOTICE, "failed to delete buffer %s", OG(active_ob_buffer).handler_name);
+ zval_dtor(return_value);
RETURN_FALSE;
}
-
-@@ -838,10 +840,12 @@ PHP_FUNCTION(ob_end_clean)
-
+
+@@ -832,11 +834,13 @@ PHP_FUNCTION(ob_end_flush)
+
if (!OG(ob_nesting_level)) {
- php_error_docref("ref.outcontrol" TSRMLS_CC, E_NOTICE, "failed to delete buffer. No buffer to delete.");
+ php_error_docref("ref.outcontrol" TSRMLS_CC, E_NOTICE, "failed to delete and flush buffer. No buffer to delete or flush");
+ zval_dtor(return_value);
RETURN_FALSE;
}
+
if (OG(ob_nesting_level) && !OG(active_ob_buffer).status && !OG(active_ob_buffer).erase) {
- php_error_docref("ref.outcontrol" TSRMLS_CC, E_NOTICE, "failed to delete buffer %s.", OG(active_ob_buffer).handler_name);
+ php_error_docref("ref.outcontrol" TSRMLS_CC, E_NOTICE, "failed to delete buffer %s", OG(active_ob_buffer).handler_name);
+ zval_dtor(return_value);
RETURN_FALSE;
}
-
+
diff --git a/debian/patches/libdb_is_-ldb b/debian/patches/libdb_is_-ldb
index f6c3fc9..966d423 100644
--- a/debian/patches/libdb_is_-ldb
+++ b/debian/patches/libdb_is_-ldb
@@ -4,10 +4,8 @@ Origin: vendor
Forwarded: no
Last-Update: 2010-01-18
-Index: php-5.3.3RC3/ext/dba/config.m4
-===================================================================
---- php-5.3.3RC3.orig/ext/dba/config.m4
-+++ php-5.3.3RC3/ext/dba/config.m4
+--- a/ext/dba/config.m4
++++ b/ext/dba/config.m4
@@ -323,7 +323,7 @@ if test "$PHP_DB4" != "no"; then
break
fi
diff --git a/debian/patches/php-5.3.4-ini.patch b/debian/patches/php-5.3.4-ini.patch
deleted file mode 100644
index 4ac30dd..0000000
--- a/debian/patches/php-5.3.4-ini.patch
+++ /dev/null
@@ -1,30 +0,0 @@
---- a/main/php_ini.c
-+++ b/main/php_ini.c
-@@ -201,6 +201,7 @@ PHPAPI void config_zval_dtor(zval *zvalu
- /* Reset / free active_ini_sectin global */
- #define RESET_ACTIVE_INI_HASH() do { \
- active_ini_hash = NULL; \
-+ is_special_section = 0; \
- } while (0)
- /* }}} */
-
-@@ -628,9 +629,6 @@ int php_init_config(TSRMLS_D)
- zend_llist_element *element;
- int l, total_l = 0;
-
-- /* Reset active ini section */
-- RESET_ACTIVE_INI_HASH();
--
- if ((ndir = php_scandir(php_ini_scanned_path, &namelist, 0, php_alphasort)) > 0) {
- zend_llist_init(&scanned_ini_list, sizeof(char *), (llist_dtor_func_t) free_estring, 1);
- memset(&fh, 0, sizeof(fh));
-@@ -642,6 +640,9 @@ int php_init_config(TSRMLS_D)
- free(namelist[i]);
- continue;
- }
-+ /* Reset active ini section */
-+ RESET_ACTIVE_INI_HASH();
-+
- if (IS_SLASH(php_ini_scanned_path[php_ini_scanned_path_len - 1])) {
- snprintf(ini_file, MAXPATHLEN, "%s%s", php_ini_scanned_path, namelist[i]->d_name);
- } else {
diff --git a/debian/patches/php-fpm-man-section-and-cleanup.patch b/debian/patches/php-fpm-man-section-and-cleanup.patch
index ba2b2b9..d16bd3c 100644
--- a/debian/patches/php-fpm-man-section-and-cleanup.patch
+++ b/debian/patches/php-fpm-man-section-and-cleanup.patch
@@ -5,17 +5,9 @@ Origin: vendor
Forwarded: http://bugs.php.net/52476
Last-Update: 2010-07-29
-Index: php-5.3.3/sapi/fpm/php-fpm.1.in
-===================================================================
---- php-5.3.3.orig/sapi/fpm/php-fpm.1.in
-+++ php-5.3.3/sapi/fpm/php-fpm.1.in
-@@ -1,4 +1,4 @@
--.TH PHP-FPM 1 "2009" "The PHP Group" "Scripting Language"
-+.TH PHP-FPM 8 "2009" "The PHP Group" "Scripting Language"
- .SH NAME
- .TP 15
- php-fpm \- PHP FastCGI Process Manager 'PHP-FPM'
-@@ -99,15 +99,8 @@ The configuration file for the php-fpm d
+--- a/sapi/fpm/php-fpm.8.in
++++ b/sapi/fpm/php-fpm.8.in
+@@ -112,15 +112,8 @@ The configuration file for the php-fpm d
.TP
.B php.ini
The standard php configuration file.
@@ -28,12 +20,12 @@ Index: php-5.3.3/sapi/fpm/php-fpm.1.in
-.RE
-.TP
-If your installation has no appropriate init script, launch php-fpm with no arguments. It will launch as a daemon (background process) by default. The file @php_fpm_localstatedir@/run/php-fpm.pid determines whether php-fpm is already up and running. Once started, php-fpm then responds to several POSIX signals:
-+.SH SIGNALS
++.SH SIGNAL
+Once started, php-fpm then responds to several POSIX signals:
.P
.PD 0
.RS
-@@ -121,10 +114,6 @@ If your installation has no appropriate
+@@ -134,10 +127,6 @@ If your installation has no appropriate
.RE
.PD 1
.P
diff --git a/debian/patches/php_crypt_revamped.patch b/debian/patches/php_crypt_revamped.patch
index adea8b5..0500c24 100644
--- a/debian/patches/php_crypt_revamped.patch
+++ b/debian/patches/php_crypt_revamped.patch
@@ -189,24 +189,18 @@
-#if PHP_STD_DES_CRYPT
-#define PHP_MAX_SALT_LEN 2
-+#if defined(HAVE_CRYPT_R) && (defined(_REENTRANT) || defined(_THREAD_SAFE))
-+# define PHP_USE_SYSTEM_CRYPT_R
- #endif
-
+-#endif
+-
-#if PHP_EXT_DES_CRYPT
-#undef PHP_MAX_SALT_LEN
-#define PHP_MAX_SALT_LEN 9
-#endif
-+#define PHP_MAX_STD_DES_SALT_LEN 2
-+#define PHP_MAX_STD_DES_HASH_LEN 11
-
+-
-#if PHP_MD5_CRYPT
-#undef PHP_MAX_SALT_LEN
-#define PHP_MAX_SALT_LEN 12
-#endif
-+#define PHP_MAX_EXT_DES_SALT_LEN 9
-+#define PHP_MAX_EXT_DES_HASH_LEN 11
-
+-
-#if PHP_BLOWFISH_CRYPT
-#undef PHP_MAX_SALT_LEN
-#define PHP_MAX_SALT_LEN 60
@@ -215,26 +209,36 @@
-#if PHP_SHA512_CRYPT
-#undef PHP_MAX_SALT_LEN
-#define PHP_MAX_SALT_LEN 123
++#if defined(HAVE_CRYPT_R) && (defined(_REENTRANT) || defined(_THREAD_SAFE))
++# define PHP_USE_SYSTEM_CRYPT_R
+ #endif
+
++#define PHP_MAX_STD_DES_SALT_LEN 2
++#define PHP_MAX_STD_DES_HASH_LEN 11
+
+-/* If the configure-time checks fail, we provide DES.
+- * XXX: This is a hack. Fix the real problem! */
+-
+-#ifndef PHP_MAX_SALT_LEN
+-#define PHP_MAX_SALT_LEN 2
+-#undef PHP_STD_DES_CRYPT
+-#define PHP_STD_DES_CRYPT 1
-#endif
++#define PHP_MAX_EXT_DES_SALT_LEN 9
++#define PHP_MAX_EXT_DES_HASH_LEN 11
++
+#define PHP_MAX_MD5_SALT_LEN 12
+#define PHP_MAX_MD5_HASH_LEN 22
-
++
+#define PHP_MAX_BLOWFISH_SALT_LEN 29
+#define PHP_MAX_BLOWFISH_HASH_LEN 31
+
+#define PHP_MAX_SHA256_SALT_LEN 37
+#define PHP_MAX_SHA256_HASH_LEN 43
-
--/* If the configure-time checks fail, we provide DES.
-- * XXX: This is a hack. Fix the real problem! */
++
+#define PHP_MAX_SHA512_SALT_LEN 37
+#define PHP_MAX_SHA512_HASH_LEN 86
-
--#ifndef PHP_MAX_SALT_LEN
--#define PHP_MAX_SALT_LEN 2
--#undef PHP_STD_DES_CRYPT
--#define PHP_STD_DES_CRYPT 1
--#endif
++
+/*
+ * Maximum salt length is from Blowfish
+ * Maximum hash length is from SHA512
diff --git a/debian/patches/qdbm-is-usr_include_qdbm.patch b/debian/patches/qdbm-is-usr_include_qdbm.patch
index c596e20..427715f 100644
--- a/debian/patches/qdbm-is-usr_include_qdbm.patch
+++ b/debian/patches/qdbm-is-usr_include_qdbm.patch
@@ -5,10 +5,8 @@ Origin: vendor
Forwarded: not-needed
Last-Update: 2010-02-21
-Index: php/ext/dba/config.m4
-===================================================================
---- php.orig/ext/dba/config.m4
-+++ php/ext/dba/config.m4
+--- a/ext/dba/config.m4
++++ b/ext/dba/config.m4
@@ -109,6 +109,10 @@ if test "$PHP_QDBM" != "no"; then
THIS_PREFIX=$i
THIS_INCLUDE=$i/include/depot.h
diff --git a/debian/patches/reject-filenames-with-null-r305507.patch b/debian/patches/reject-filenames-with-null-r305507.patch
index befe401..1e25b84 100644
--- a/debian/patches/reject-filenames-with-null-r305507.patch
+++ b/debian/patches/reject-filenames-with-null-r305507.patch
@@ -1,105 +1,6 @@
---- a/ext/standard/ftok.c
-+++ b/ext/standard/ftok.c
-@@ -39,6 +39,10 @@ PHP_FUNCTION(ftok)
- return;
- }
-
-+ if (strlen(pathname) != pathname_len) {
-+ RETURN_FALSE;
-+ }
-+
- if (pathname_len == 0){
- php_error_docref(NULL TSRMLS_CC, E_WARNING, "Pathname is invalid");
- RETURN_LONG(-1);
---- a/ext/standard/basic_functions.c
-+++ b/ext/standard/basic_functions.c
-@@ -4671,6 +4671,12 @@ PHP_FUNCTION(error_log)
- opt_err = erropt;
- }
-
-+ if (opt_err == 3) {
-+ if (strlen(opt) != opt_len) {
-+ RETURN_FALSE;
-+ }
-+ }
-+
- if (_php_error_log_ex(opt_err, message, message_len, opt, headers TSRMLS_CC) == FAILURE) {
- RETURN_FALSE;
- }
-@@ -5159,6 +5165,10 @@ PHP_FUNCTION(highlight_file)
- RETURN_FALSE;
- }
-
-+ if (strlen(filename) != filename_len) {
-+ RETURN_FALSE;
-+ }
-+
- if (i) {
- php_start_ob_buffer (NULL, 0, 1 TSRMLS_CC);
- }
-@@ -5205,6 +5215,10 @@ PHP_FUNCTION(php_strip_whitespace)
- RETURN_FALSE;
- }
-
-+ if (strlen(filename) != filename_len) {
-+ RETURN_FALSE;
-+ }
-+
- file_handle.type = ZEND_HANDLE_FILENAME;
- file_handle.filename = filename;
- file_handle.free_filename = 0;
-@@ -5465,6 +5479,11 @@ PHP_FUNCTION(set_include_path)
- return;
- }
-
-+ /* No nulls allowed in paths */
-+ if (strlen(new_value) != new_value_len) {
-+ RETURN_FALSE;
-+ }
-+
- old_value = zend_ini_string("include_path", sizeof("include_path"), 0);
- /* copy to return here, because alter might free it! */
- if (old_value) {
-@@ -5775,6 +5794,10 @@ PHP_FUNCTION(is_uploaded_file)
- return;
- }
-
-+ if (strlen(path) != path_len) {
-+ RETURN_FALSE;
-+ }
-+
- if (zend_hash_exists(SG(rfc1867_uploaded_files), path, path_len + 1)) {
- RETURN_TRUE;
- } else {
-@@ -5815,6 +5838,14 @@ PHP_FUNCTION(move_uploaded_file)
- RETURN_FALSE;
- }
-
-+ if (strlen(path) != path_len) {
-+ RETURN_FALSE;
-+ }
-+
-+ if (strlen(new_path) != new_path_len) {
-+ RETURN_FALSE;
-+ }
-+
- VCWD_UNLINK(new_path);
- if (VCWD_RENAME(path, new_path) == 0) {
- successful = 1;
-@@ -5958,6 +5989,10 @@ PHP_FUNCTION(parse_ini_file)
- RETURN_FALSE;
- }
-
-+ if (strlen(filename) != filename_len) {
-+ RETURN_FALSE;
-+ }
-+
- /* Set callback function */
- if (process_sections) {
- BG(active_ini_file_section) = NULL;
--- a/ext/standard/dir.c
+++ b/ext/standard/dir.c
-@@ -325,6 +325,10 @@ PHP_FUNCTION(chdir)
+@@ -329,6 +329,10 @@ PHP_FUNCTION(chdir)
RETURN_FALSE;
}
@@ -110,8 +11,8 @@
if ((PG(safe_mode) && !php_checkuid(str, NULL, CHECKUID_CHECK_FILE_AND_DIR)) || php_check_open_basedir(str TSRMLS_CC)) {
RETURN_FALSE;
}
-@@ -436,6 +440,10 @@ PHP_FUNCTION(glob)
- return;
+@@ -444,6 +448,10 @@ PHP_FUNCTION(glob)
+ RETURN_FALSE;
}
+ if (strlen(pattern) != pattern_len) {
@@ -121,33 +22,20 @@
if (pattern_len >= MAXPATHLEN) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Pattern exceeds the maximum allowed length of %d characters", MAXPATHLEN);
RETURN_FALSE;
-@@ -557,6 +565,10 @@ PHP_FUNCTION(scandir)
- return;
+@@ -566,6 +574,10 @@ PHP_FUNCTION(scandir)
}
-+ if (strlen(dirn) != dirn_len) {
+ if (strlen(dirn) != dirn_len) {
+ RETURN_FALSE;
+ }
+
- if (dirn_len < 1) {
- php_error_docref(NULL TSRMLS_CC, E_WARNING, "Directory name cannot be empty");
++ if (strlen(dirn) != dirn_len) {
RETURN_FALSE;
---- a/ext/standard/iptc.c
-+++ b/ext/standard/iptc.c
-@@ -190,6 +190,10 @@ PHP_FUNCTION(iptcembed)
- return;
}
-+ if (strlen(jpeg_file) != jpeg_file_len) {
-+ RETURN_FALSE;
-+ }
-+
- if (PG(safe_mode) && (!php_checkuid(jpeg_file, NULL, CHECKUID_CHECK_FILE_AND_DIR))) {
- RETURN_FALSE;
- }
--- a/ext/standard/filestat.c
+++ b/ext/standard/filestat.c
-@@ -379,6 +379,10 @@ PHP_FUNCTION(disk_free_space)
+@@ -383,6 +383,10 @@ PHP_FUNCTION(disk_free_space)
RETURN_FALSE;
}
@@ -158,7 +46,7 @@
if (php_disk_free_space(path, &bytesfree TSRMLS_CC) == SUCCESS) {
RETURN_DOUBLE(bytesfree);
}
-@@ -399,6 +403,10 @@ static void php_do_chgrp(INTERNAL_FUNCTI
+@@ -407,6 +411,10 @@ static void php_do_chgrp(INTERNAL_FUNCTI
RETURN_FALSE;
}
@@ -169,8 +57,8 @@
if (Z_TYPE_P(group) == IS_LONG) {
gid = (gid_t)Z_LVAL_P(group);
} else if (Z_TYPE_P(group) == IS_STRING) {
-@@ -500,6 +508,10 @@ static void php_do_chown(INTERNAL_FUNCTI
- return;
+@@ -512,6 +520,10 @@ static void php_do_chown(INTERNAL_FUNCTI
+ RETURN_FALSE;
}
+ if (strlen(filename) != filename_len) {
@@ -180,7 +68,7 @@
if (Z_TYPE_P(user) == IS_LONG) {
uid = (uid_t)Z_LVAL_P(user);
} else if (Z_TYPE_P(user) == IS_STRING) {
-@@ -607,6 +619,10 @@ PHP_FUNCTION(chmod)
+@@ -623,6 +635,10 @@ PHP_FUNCTION(chmod)
RETURN_FALSE;
}
@@ -191,8 +79,8 @@
/* Check the basedir */
if (php_check_open_basedir(filename TSRMLS_CC)) {
RETURN_FALSE;
-@@ -660,6 +676,10 @@ PHP_FUNCTION(touch)
- return;
+@@ -680,6 +696,10 @@ PHP_FUNCTION(touch)
+ RETURN_FALSE;
}
+ if (strlen(filename) != filename_len) {
@@ -202,18 +90,7 @@
switch (argc) {
case 1:
#ifdef HAVE_UTIME_NULL
-@@ -715,8 +735,9 @@ PHP_FUNCTION(touch)
- PHPAPI void php_clear_stat_cache(zend_bool clear_realpath_cache, const char *filename, int filename_len TSRMLS_DC)
- {
- /* always clear CurrentStatFile and CurrentLStatFile even if filename is not NULL
-- * as it may contains outdated data (e.g. "nlink" for a directory when deleting a file
-+ * as it may contain outdated data (e.g. "nlink" for a directory when deleting a file
- * in this directory, as shown by lstat_stat_variation9.phpt) */
-+
- if (BG(CurrentStatFile)) {
- efree(BG(CurrentStatFile));
- BG(CurrentStatFile) = NULL;
-@@ -777,6 +798,10 @@ PHPAPI void php_stat(const char *filenam
+@@ -798,6 +818,10 @@ PHPAPI void php_stat(const char *filenam
RETURN_FALSE;
}
@@ -221,434 +98,12 @@
+ RETURN_FALSE;
+ }
+
- if ((wrapper = php_stream_locate_url_wrapper(filename, &local, 0 TSRMLS_CC)) == &php_plain_files_wrapper) {
- if (php_check_open_basedir(local TSRMLS_CC)) {
- RETURN_FALSE;
---- a/ext/standard/file.c
-+++ b/ext/standard/file.c
-@@ -385,6 +385,10 @@ PHP_FUNCTION(get_meta_tags)
- return;
- }
-
-+ if (strlen(filename) != filename_len) {
-+ RETURN_FALSE;
-+ }
-+
- md.stream = php_stream_open_wrapper(filename, "rb",
- (use_include_path ? USE_PATH : 0) | ENFORCE_SAFE_MODE | REPORT_ERRORS,
- NULL);
-@@ -538,6 +542,10 @@ PHP_FUNCTION(file_get_contents)
- return;
- }
-
-+ if (strlen(filename) != filename_len) {
-+ RETURN_FALSE;
-+ }
-+
- if (ZEND_NUM_ARGS() == 5 && maxlen < 0) {
- php_error_docref(NULL TSRMLS_CC, E_WARNING, "length must be greater than or equal to zero");
- RETURN_FALSE;
-@@ -595,6 +603,10 @@ PHP_FUNCTION(file_put_contents)
- return;
- }
-
-+ if (strlen(filename) != filename_len) {
-+ RETURN_FALSE;
-+ }
-+
- if (Z_TYPE_P(data) == IS_RESOURCE) {
- php_stream_from_zval(srcstream, &data);
- }
-@@ -739,6 +751,11 @@ PHP_FUNCTION(file)
- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|lr!", &filename, &filename_len, &flags, &zcontext) == FAILURE) {
- return;
- }
-+
-+ if (strlen(filename) != filename_len) {
-+ RETURN_FALSE;
-+ }
-+
- if (flags < 0 || flags > (PHP_FILE_USE_INCLUDE_PATH | PHP_FILE_IGNORE_NEW_LINES | PHP_FILE_SKIP_EMPTY_LINES | PHP_FILE_NO_DEFAULT_CONTEXT)) {
- php_error_docref(NULL TSRMLS_CC, E_WARNING, "'%ld' flag is not supported", flags);
- RETURN_FALSE;
-@@ -836,6 +853,14 @@ PHP_FUNCTION(tempnam)
- return;
- }
-
-+ if (strlen(dir) != dir_len) {
-+ RETURN_FALSE;
-+ }
-+
-+ if (strlen(prefix) != prefix_len) {
-+ RETURN_FALSE;
-+ }
-+
- if (PG(safe_mode) &&(!php_checkuid(dir, NULL, CHECKUID_CHECK_FILE_AND_DIR))) {
- RETURN_FALSE;
- }
-@@ -894,6 +919,10 @@ PHP_NAMED_FUNCTION(php_if_fopen)
- RETURN_FALSE;
- }
-
-+ if (strlen(filename) != filename_len) {
-+ RETURN_FALSE;
-+ }
-+
- context = php_stream_context_from_zval(zcontext, 0);
-
- stream = php_stream_open_wrapper_ex(filename, mode, (use_include_path ? USE_PATH : 0) | ENFORCE_SAFE_MODE | REPORT_ERRORS, NULL, context);
-@@ -1397,6 +1426,10 @@ PHP_FUNCTION(mkdir)
- RETURN_FALSE;
- }
-
-+ if (strlen(dir) != dir_len) {
-+ RETURN_FALSE;
-+ }
-+
- context = php_stream_context_from_zval(zcontext, 0);
-
- RETURN_BOOL(php_stream_mkdir(dir, mode, (recursive ? PHP_STREAM_MKDIR_RECURSIVE : 0) | REPORT_ERRORS, context));
-@@ -1416,6 +1449,10 @@ PHP_FUNCTION(rmdir)
- RETURN_FALSE;
- }
-
-+ if (strlen(dir) != dir_len) {
-+ RETURN_FALSE;
-+ }
-+
- context = php_stream_context_from_zval(zcontext, 0);
-
- RETURN_BOOL(php_stream_rmdir(dir, REPORT_ERRORS, context));
-@@ -1438,6 +1475,10 @@ PHP_FUNCTION(readfile)
- RETURN_FALSE;
- }
-
-+ if (strlen(filename) != filename_len) {
-+ RETURN_FALSE;
-+ }
-+
- context = php_stream_context_from_zval(zcontext, 0);
-
- stream = php_stream_open_wrapper_ex(filename, "rb", (use_include_path ? USE_PATH : 0) | ENFORCE_SAFE_MODE | REPORT_ERRORS, NULL, context);
-@@ -1511,6 +1552,14 @@ PHP_FUNCTION(rename)
- RETURN_FALSE;
- }
-
-+ if (strlen(old_name) != old_name_len) {
-+ RETURN_FALSE;
-+ }
-+
-+ if (strlen(new_name) != new_name_len) {
-+ RETURN_FALSE;
-+ }
-+
- wrapper = php_stream_locate_url_wrapper(old_name, NULL, 0 TSRMLS_CC);
-
- if (!wrapper || !wrapper->wops) {
-@@ -1548,6 +1597,10 @@ PHP_FUNCTION(unlink)
- RETURN_FALSE;
- }
-
-+ if (strlen(filename) != filename_len) {
-+ RETURN_FALSE;
-+ }
-+
- context = php_stream_context_from_zval(zcontext, 0);
-
- wrapper = php_stream_locate_url_wrapper(filename, NULL, 0 TSRMLS_CC);
-@@ -1684,6 +1737,14 @@ PHP_FUNCTION(copy)
- return;
- }
-
-+ if (strlen(source) != source_len) {
-+ RETURN_FALSE;
-+ }
-+
-+ if (strlen(target) != target_len) {
-+ RETURN_FALSE;
-+ }
-+
- if (PG(safe_mode) &&(!php_checkuid(source, NULL, CHECKUID_CHECK_FILE_AND_DIR))) {
- RETURN_FALSE;
- }
-@@ -2375,6 +2436,10 @@ PHP_FUNCTION(realpath)
- return;
- }
-
-+ if (strlen(filename) != filename_len) {
-+ RETURN_FALSE;
-+ }
-+
- if (VCWD_REALPATH(filename, resolved_path_buff)) {
- if (PG(safe_mode) && (!php_checkuid(resolved_path_buff, NULL, CHECKUID_CHECK_FILE_AND_DIR))) {
- RETURN_FALSE;
-@@ -2517,6 +2582,14 @@ PHP_FUNCTION(fnmatch)
- return;
- }
-
-+ if (strlen(pattern) != pattern_len) {
-+ RETURN_FALSE;
-+ }
-+
-+ if (strlen(filename) != filename_len) {
-+ RETURN_FALSE;
-+ }
-+
- if (filename_len >= MAXPATHLEN) {
- php_error_docref(NULL TSRMLS_CC, E_WARNING, "Filename exceeds the maximum allowed length of %d characters", MAXPATHLEN);
- RETURN_FALSE;
---- a/ext/standard/link.c
-+++ b/ext/standard/link.c
-@@ -64,6 +64,10 @@ PHP_FUNCTION(readlink)
- return;
- }
-
-+ if (strlen(link) != link_len) {
-+ RETURN_FALSE;
-+ }
-+
- if (PG(safe_mode) && !php_checkuid(link, NULL, CHECKUID_CHECK_FILE_AND_DIR)) {
- RETURN_FALSE;
- }
-@@ -123,6 +127,14 @@ PHP_FUNCTION(symlink)
- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ss", &topath, &topath_len, &frompath, &frompath_len) == FAILURE) {
- return;
- }
-+
-+ if (strlen(topath) != topath_len) {
-+ RETURN_FALSE;
-+ }
-+
-+ if (strlen(frompath) != frompath_len) {
-+ RETURN_FALSE;
-+ }
-
- if (!expand_filepath(frompath, source_p TSRMLS_CC)) {
- php_error_docref(NULL TSRMLS_CC, E_WARNING, "No such file or directory");
-@@ -188,6 +200,14 @@ PHP_FUNCTION(link)
- return;
- }
-
-+ if (strlen(topath) != topath_len) {
-+ RETURN_FALSE;
-+ }
-+
-+ if (strlen(frompath) != frompath_len) {
-+ RETURN_FALSE;
-+ }
-+
- if (!expand_filepath(frompath, source_p TSRMLS_CC) || !expand_filepath(topath, dest_p TSRMLS_CC)) {
- php_error_docref(NULL TSRMLS_CC, E_WARNING, "No such file or directory");
- RETURN_FALSE;
---- a/ext/openssl/openssl.c
-+++ b/ext/openssl/openssl.c
-@@ -1771,6 +1771,10 @@ PHP_FUNCTION(openssl_pkcs12_export_to_fi
- return;
-
- RETVAL_FALSE;
-+
-+ if (strlen(filename) != filename_len) {
-+ return;
-+ }
-
- cert = php_openssl_x509_from_zval(zcert, 0, &certresource TSRMLS_CC);
- if (cert == NULL) {
-@@ -2218,6 +2222,10 @@ PHP_FUNCTION(openssl_csr_export_to_file)
- }
- RETVAL_FALSE;
-
-+ if (strlen(filename) != filename_len) {
-+ return;
-+ }
-+
- csr = php_openssl_csr_from_zval(&zcsr, 0, &csr_resource TSRMLS_CC);
- if (csr == NULL) {
- php_error_docref(NULL TSRMLS_CC, E_WARNING, "cannot get CSR from parameter 1");
-@@ -3002,6 +3010,10 @@ PHP_FUNCTION(openssl_pkey_export_to_file
- }
- RETVAL_FALSE;
-
-+ if (strlen(filename) != filename_len) {
-+ return;
-+ }
-+
- key = php_openssl_evp_from_zval(zpkey, 0, passphrase, 0, &key_resource TSRMLS_CC);
-
- if (key == NULL) {
-@@ -3394,7 +3406,14 @@ PHP_FUNCTION(openssl_pkcs7_encrypt)
- &outfilename, &outfilename_len, &zrecipcerts, &zheaders, &flags, &cipherid) == FAILURE)
- return;
-
--
-+ if (strlen(infilename) != infilename_len) {
-+ return;
-+ }
-+
-+ if (strlen(outfilename) != outfilename_len) {
-+ return;
-+ }
-+
- if (php_openssl_safe_mode_chk(infilename TSRMLS_CC) || php_openssl_safe_mode_chk(outfilename TSRMLS_CC)) {
- return;
- }
-@@ -3526,14 +3545,22 @@ PHP_FUNCTION(openssl_pkcs7_sign)
- char * outfilename; int outfilename_len;
- char * extracertsfilename = NULL; int extracertsfilename_len;
-
-+ RETVAL_FALSE;
-+
- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ssZZa!|ls",
- &infilename, &infilename_len, &outfilename, &outfilename_len,
- &zcert, &zprivkey, &zheaders, &flags, &extracertsfilename,
- &extracertsfilename_len) == FAILURE) {
- return;
- }
--
-- RETVAL_FALSE;
-+
-+ if (strlen(infilename) != infilename_len) {
-+ return;
-+ }
-+
-+ if (strlen(outfilename) != outfilename_len) {
-+ return;
-+ }
-
- if (extracertsfilename) {
- others = load_all_certs_from_file(extracertsfilename);
-@@ -3630,12 +3657,20 @@ PHP_FUNCTION(openssl_pkcs7_decrypt)
- char * infilename; int infilename_len;
- char * outfilename; int outfilename_len;
-
-+ RETVAL_FALSE;
-+
- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ssZ|Z", &infilename, &infilename_len,
- &outfilename, &outfilename_len, &recipcert, &recipkey) == FAILURE) {
- return;
- }
-
-- RETVAL_FALSE;
-+ if (strlen(infilename) != infilename_len) {
-+ return;
-+ }
-+
-+ if (strlen(outfilename) != outfilename_len) {
-+ return;
-+ }
-
- cert = php_openssl_x509_from_zval(recipcert, 0, &certresval TSRMLS_CC);
- if (cert == NULL) {
---- a/ext/sqlite3/sqlite3.c
-+++ b/ext/sqlite3/sqlite3.c
-@@ -114,6 +114,9 @@ PHP_METHOD(sqlite3, open)
- zend_throw_exception(zend_exception_get_default(TSRMLS_C), "Already initialised DB Object", 0 TSRMLS_CC);
- }
-
-+ if (strlen(filename) != filename_len) {
-+ return;
-+ }
- if (strncmp(filename, ":memory:", 8) != 0) {
- if (!(fullpath = expand_filepath(filename, NULL TSRMLS_CC))) {
- zend_throw_exception(zend_exception_get_default(TSRMLS_C), "Unable to expand filepath", 0 TSRMLS_CC);
---- a/ext/pgsql/pgsql.c
-+++ b/ext/pgsql/pgsql.c
-@@ -3339,6 +3339,10 @@ PHP_FUNCTION(pg_lo_import)
- WRONG_PARAM_COUNT;
- }
-
-+ if (strlen(file_in) != name_len) {
-+ RETURN_FALSE;
-+ }
-+
- if (PG(safe_mode) &&(!php_checkuid(file_in, NULL, CHECKUID_CHECK_FILE_AND_DIR))) {
- RETURN_FALSE;
- }
-@@ -3476,6 +3480,10 @@ PHP_FUNCTION(pg_lo_export)
+ if (strlen(filename) != filename_length) {
RETURN_FALSE;
}
-
-+ if (strlen(file_out) != name_len) {
-+ RETURN_FALSE;
-+ }
-+
- if (PG(safe_mode) &&(!php_checkuid(file_out, NULL, CHECKUID_CHECK_FILE_AND_DIR))) {
- RETURN_FALSE;
- }
---- a/ext/gd/gd_ctx.c
-+++ b/ext/gd/gd_ctx.c
-@@ -91,6 +91,9 @@ static void _php_image_output_ctx(INTERN
- }
-
- if (argc > 1 && file_len) {
-+ if (strlen(file) != file_len) {
-+ RETURN_FALSE;
-+ }
- PHP_GD_CHECK_OPEN_BASEDIR(file, "Invalid filename");
-
- fp = VCWD_FOPEN(file, "wb");
---- a/ext/gd/gd.c
-+++ b/ext/gd/gd.c
-@@ -2642,6 +2642,9 @@ static void _php_image_output(INTERNAL_F
- }
-
- if (argc >= 2 && file_len) {
-+ if (strlen(file) != file_len) {
-+ RETURN_FALSE;
-+ }
- PHP_GD_CHECK_OPEN_BASEDIR(fn, "Invalid filename");
-
- fp = VCWD_FOPEN(fn, "wb");
-@@ -4552,6 +4555,14 @@ static void _php_image_convert(INTERNAL_
- dest_width = width;
- int_threshold = threshold;
-
-+ if (strlen(f_org) != f_org_len) {
-+ RETURN_FALSE;
-+ }
-+
-+ if (strlen(f_dest) != f_dest_len) {
-+ RETURN_FALSE;
-+ }
-+
- /* Check threshold value */
- if (int_threshold < 0 || int_threshold > 8) {
- php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid threshold value '%d'", int_threshold);
---- a/ext/sqlite/sqlite.c
-+++ b/ext/sqlite/sqlite.c
-@@ -1560,6 +1560,9 @@ PHP_FUNCTION(sqlite_popen)
- ZVAL_NULL(errmsg);
- }
-
-+ if (strlen(filename) != filename_len) {
-+ RETURN_FALSE;
-+ }
- if (strncmp(filename, ":memory:", sizeof(":memory:") - 1)) {
- /* resolve the fully-qualified path name to use as the hash key */
- if (!(fullpath = expand_filepath(filename, NULL TSRMLS_CC))) {
-@@ -1637,6 +1640,9 @@ PHP_FUNCTION(sqlite_open)
- ZVAL_NULL(errmsg);
- }
-
-+ if (strlen(filename) != filename_len) {
-+ RETURN_FALSE;
-+ }
- if (strncmp(filename, ":memory:", sizeof(":memory:") - 1)) {
- /* resolve the fully-qualified path name to use as the hash key */
- if (!(fullpath = expand_filepath(filename, NULL TSRMLS_CC))) {
-@@ -1690,6 +1696,10 @@ PHP_FUNCTION(sqlite_factory)
- ZVAL_NULL(errmsg);
- }
-
-+ if (strlen(filename) != filename_len) {
-+ RETURN_FALSE;
-+ }
-+
- if (strncmp(filename, ":memory:", sizeof(":memory:") - 1)) {
- /* resolve the fully-qualified path name to use as the hash key */
- if (!(fullpath = expand_filepath(filename, NULL TSRMLS_CC))) {
--- a/ext/posix/posix.c
+++ b/ext/posix/posix.c
-@@ -842,6 +842,10 @@ PHP_FUNCTION(posix_mkfifo)
+@@ -846,6 +846,10 @@ PHP_FUNCTION(posix_mkfifo)
RETURN_FALSE;
}
@@ -659,7 +114,7 @@
if (php_check_open_basedir_ex(path, 0 TSRMLS_CC) ||
(PG(safe_mode) && (!php_checkuid(path, NULL, CHECKUID_ALLOW_ONLY_DIR)))) {
RETURN_FALSE;
-@@ -877,6 +881,10 @@ PHP_FUNCTION(posix_mknod)
+@@ -885,6 +889,10 @@ PHP_FUNCTION(posix_mknod)
RETURN_FALSE;
}
@@ -670,7 +125,7 @@
if (php_check_open_basedir_ex(path, 0 TSRMLS_CC) ||
(PG(safe_mode) && (!php_checkuid(path, NULL, CHECKUID_ALLOW_ONLY_DIR)))) {
RETURN_FALSE;
-@@ -957,6 +965,10 @@ PHP_FUNCTION(posix_access)
+@@ -965,6 +973,10 @@ PHP_FUNCTION(posix_access)
RETURN_FALSE;
}
@@ -678,103 +133,12 @@
+ RETURN_FALSE;
+ }
+
- path = expand_filepath(filename, NULL TSRMLS_CC);
- if (!path) {
- POSIX_G(last_error) = EIO;
---- a/ext/xsl/xsltprocessor.c
-+++ b/ext/xsl/xsltprocessor.c
-@@ -642,6 +642,9 @@ PHP_FUNCTION(xsl_xsltprocessor_transform
-
- ret = -1;
- if (newdocp) {
-+ if (strlen(uri) != uri_len) {
-+ RETURN_FALSE;
-+ }
- ret = xsltSaveResultToFilename(uri, newdocp, sheetp, 0);
- xmlFreeDoc(newdocp);
- }
-@@ -845,7 +848,7 @@ PHP_FUNCTION(xsl_xsltprocessor_set_profi
- if (intern->profiling) {
- efree(intern->profiling);
- }
-- if (filename != NULL) {
-+ if (filename != NULL && strlen(filename) == filename_len) {
- intern->profiling = estrndup(filename,filename_len);
- } else {
- intern->profiling = NULL;
---- a/ext/com_dotnet/com_persist.c
-+++ b/ext/com_dotnet/com_persist.c
-@@ -389,6 +389,9 @@ CPH_METHOD(SaveToFile)
- }
-
- if (filename) {
-+ if (strlen(filename) != filename_len) {
-+ RETURN_FALSE;
-+ }
- fullpath = expand_filepath(filename, NULL TSRMLS_CC);
- if (!fullpath) {
- RETURN_FALSE;
-@@ -453,6 +456,10 @@ CPH_METHOD(LoadFromFile)
- return;
- }
-
-+ if (strlen(filename) != filename_len) {
-+ RETURN_FALSE;
-+ }
-+
- if (!(fullpath = expand_filepath(filename, NULL TSRMLS_CC))) {
- RETURN_FALSE;
- }
---- a/ext/bz2/bz2.c
-+++ b/ext/bz2/bz2.c
-@@ -387,6 +387,9 @@ static PHP_FUNCTION(bzopen)
- if (Z_TYPE_PP(file) == IS_STRING) {
- convert_to_string_ex(file);
-
-+ if (strlen(Z_STRVAL_PP(file)) != Z_STRLEN_PP(file)) {
-+ RETURN_FALSE;
-+ }
- if (Z_STRLEN_PP(file) == 0) {
- php_error_docref(NULL TSRMLS_CC, E_WARNING, "filename cannot be empty");
- RETURN_FALSE;
---- a/ext/pspell/pspell.c
-+++ b/ext/pspell/pspell.c
-@@ -402,6 +402,10 @@ static PHP_FUNCTION(pspell_new_personal)
- }
- #endif
-
-+ if (strlen(personal) != personal_len) {
-+ RETURN_FALSE;
-+ }
-+
- if (PG(safe_mode) && (!php_checkuid(personal, NULL, CHECKUID_CHECK_FILE_AND_DIR))) {
- delete_pspell_config(config);
- RETURN_FALSE;
-@@ -834,6 +838,10 @@ static void pspell_config_path(INTERNAL_
- return;
- }
-
-+ if (strlen(value) != value_len) {
-+ RETURN_FALSE;
-+ }
-+
- PSPELL_FETCH_CONFIG;
-
- if (PG(safe_mode) && (!php_checkuid(value, NULL, CHECKUID_CHECK_FILE_AND_DIR))) {
-@@ -891,6 +899,10 @@ static PHP_FUNCTION(pspell_config_repl)
-
- pspell_config_replace(config, "save-repl", "true");
-
-+ if (strlen(repl) != repl_len) {
-+ RETURN_FALSE;
-+ }
-+
- if (PG(safe_mode) && (!php_checkuid(repl, NULL, CHECKUID_CHECK_FILE_AND_DIR))) {
+ if (strlen(filename) != filename_len) {
RETURN_FALSE;
}
--- a/ext/enchant/enchant.c
+++ b/ext/enchant/enchant.c
-@@ -591,6 +591,10 @@ PHP_FUNCTION(enchant_broker_request_pwl_
+@@ -599,6 +599,10 @@ PHP_FUNCTION(enchant_broker_request_pwl_
RETURN_FALSE;
}
@@ -785,42 +149,9 @@
#if PHP_API_VERSION < 20100412
if ((PG(safe_mode) && (!php_checkuid(pwl, NULL, CHECKUID_CHECK_FILE_AND_DIR))) || php_check_open_basedir(pwl TSRMLS_CC)) {
#else
---- a/ext/imap/php_imap.c
-+++ b/ext/imap/php_imap.c
-@@ -1216,10 +1216,14 @@ static void php_imap_do_open(INTERNAL_FU
- }
-
- /* local filename, need to perform open_basedir and safe_mode checks */
-- if (mailbox[0] != '{' &&
-- (php_check_open_basedir(mailbox TSRMLS_CC) ||
-- (PG(safe_mode) && !php_checkuid(mailbox, NULL, CHECKUID_CHECK_FILE_AND_DIR)))) {
-- RETURN_FALSE;
-+ if (mailbox[0] != '{') {
-+ if (strlen(mailbox) != mailbox_len) {
-+ RETURN_FALSE;
-+ }
-+ if (php_check_open_basedir(mailbox TSRMLS_CC) ||
-+ (PG(safe_mode) && !php_checkuid(mailbox, NULL, CHECKUID_CHECK_FILE_AND_DIR))) {
-+ RETURN_FALSE;
-+ }
- }
-
- IMAPG(imap_user) = estrndup(user, user_len);
---- a/ext/fileinfo/fileinfo.c
-+++ b/ext/fileinfo/fileinfo.c
-@@ -294,6 +294,9 @@ PHP_FUNCTION(finfo_open)
- if (file_len == 0) {
- file = NULL;
- } else if (file && *file) { /* user specified file, perform open_basedir checks */
-+ if (strlen(file) != file_len) {
-+ RETURN_FALSE;
-+ }
- if (!VCWD_REALPATH(file, resolved_path)) {
- RETURN_FALSE;
- }
--- a/ext/oci8/oci8_interface.c
+++ b/ext/oci8/oci8_interface.c
-@@ -271,6 +271,10 @@ PHP_FUNCTION(oci_lob_load)
+@@ -276,6 +276,10 @@ PHP_FUNCTION(oci_lob_load)
return;
}
}
@@ -831,8 +162,8 @@
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");
-@@ -662,7 +666,7 @@ PHP_FUNCTION(oci_lob_erase)
- RETURN_FALSE;
+@@ -700,7 +704,7 @@ PHP_FUNCTION(oci_lob_flush)
+ return;
}
}
-
@@ -840,20 +171,20 @@
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;
-@@ -918,6 +922,10 @@ PHP_FUNCTION(oci_lob_export)
- /* nothing to write, fail silently */
- RETURN_FALSE;
+@@ -923,6 +927,10 @@ PHP_FUNCTION(oci_lob_export)
+ if (length == -1) {
+ length = lob_length - descriptor->lob_current_position;
}
+
+ if (strlen(filename) != filename_len) {
+ RETURN_FALSE;
+ }
- if (PG(safe_mode) && (!php_checkuid(filename, NULL, CHECKUID_CHECK_FILE_AND_DIR))) {
- RETURN_FALSE;
+ if (length == 0) {
+ /* nothing to write, fail silently */
--- a/ext/zip/php_zip.c
+++ b/ext/zip/php_zip.c
-@@ -1148,6 +1148,10 @@ static PHP_NAMED_FUNCTION(zif_zip_open)
+@@ -1155,6 +1155,10 @@ static PHP_NAMED_FUNCTION(zif_zip_open)
RETURN_FALSE;
}
@@ -864,7 +195,7 @@
if (ZIP_OPENBASEDIR_CHECKPATH(filename)) {
RETURN_FALSE;
}
-@@ -1437,6 +1441,10 @@ static ZIPARCHIVE_METHOD(open)
+@@ -1448,6 +1452,10 @@ static ZIPARCHIVE_METHOD(open)
RETURN_FALSE;
}
@@ -875,196 +206,19 @@
if (ZIP_OPENBASEDIR_CHECKPATH(filename)) {
RETURN_FALSE;
}
-@@ -2363,6 +2371,10 @@ static ZIPARCHIVE_METHOD(extractTo)
- RETURN_FALSE;
- }
-
-+ if (strlen(pathto) != pathto_len) {
-+ RETURN_FALSE;
-+ }
-+
- if (php_stream_stat_path(pathto, &ssb) < 0) {
- ret = php_stream_mkdir(pathto, 0777, PHP_STREAM_MKDIR_RECURSIVE, NULL);
- if (!ret) {
-@@ -2449,6 +2461,9 @@ static void php_zip_get_from(INTERNAL_FU
- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|ll", &filename, &filename_len, &len, &flags) == FAILURE) {
+@@ -2465,6 +2473,9 @@ static void php_zip_get_from(INTERNAL_FU
return;
}
-+ if (strlen(filename) != filename_len) {
+ if (strlen(filename) != filename_len) {
+ return;
+ }
- PHP_ZIP_STAT_PATH(intern, filename, filename_len, flags, sb);
- } else {
- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "l|ll", &index, &len, &flags) == FAILURE) {
---- a/ext/odbc/php_odbc.c
-+++ b/ext/odbc/php_odbc.c
-@@ -1293,8 +1293,11 @@ 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 (strlen(tmp) != Z_STRLEN_PP(tmp)) {
-+ RETURN_FALSE;
-+ }
-+
- filename = estrndup(&Z_STRVAL_PP(tmp)[1], Z_STRLEN_PP(tmp) - 2);
-- filename[strlen(filename)] = '\0';
-
- /* Check for safe mode. */
- if (PG(safe_mode) && (!php_checkuid(filename, NULL, CHECKUID_CHECK_FILE_AND_DIR))) {
---- a/ext/tidy/tidy.c
-+++ b/ext/tidy/tidy.c
-@@ -567,6 +567,9 @@ static void php_tidy_quick_repair(INTERN
- }
-
- if (is_file) {
-+ if (strlen(arg1) != arg1_len) {
-+ RETURN_FALSE;
-+ }
- if (!(data = php_tidy_file_to_mem(arg1, use_include_path, &data_len TSRMLS_CC))) {
- RETURN_FALSE;
- }
-@@ -1221,6 +1224,9 @@ static PHP_FUNCTION(tidy_parse_file)
- RETURN_FALSE;
- }
-
-+ if (strlen(inputfile) != input_len) {
-+ RETURN_FALSE;
-+ }
- tidy_instanciate(tidy_ce_doc, return_value TSRMLS_CC);
- obj = (PHPTidyObj *) zend_object_store_get_object(return_value TSRMLS_CC);
-
-@@ -1534,10 +1540,13 @@ static TIDY_DOC_METHOD(__construct)
- &options, &enc, &enc_len, &use_include_path) == FAILURE) {
- RETURN_FALSE;
- }
--
-+
- obj = (PHPTidyObj *)zend_object_store_get_object(object TSRMLS_CC);
-
- if (inputfile) {
-+ if (strlen(inputfile) != input_len) {
-+ RETURN_FALSE;
-+ }
- if (!(contents = php_tidy_file_to_mem(inputfile, use_include_path, &contents_len TSRMLS_CC))) {
- php_error_docref(NULL TSRMLS_CC, E_WARNING, "Cannot Load '%s' into memory %s", inputfile, (use_include_path) ? "(Using include path)" : "");
++ if (strlen(filename) != filename_len) {
return;
-@@ -1568,7 +1577,10 @@ static TIDY_DOC_METHOD(parseFile)
- &options, &enc, &enc_len, &use_include_path) == FAILURE) {
- RETURN_FALSE;
- }
--
-+
-+ if (strlen(inputfile) != input_len) {
-+ RETURN_FALSE;
-+ }
- if (!(contents = php_tidy_file_to_mem(inputfile, use_include_path, &contents_len TSRMLS_CC))) {
- php_error_docref(NULL TSRMLS_CC, E_WARNING, "Cannot Load '%s' into memory %s", inputfile, (use_include_path) ? "(Using include path)" : "");
- RETURN_FALSE;
---- a/Zend/zend_vm_execute.h
-+++ b/Zend/zend_vm_execute.h
-@@ -1880,6 +1880,16 @@ static int ZEND_FASTCALL ZEND_INCLUDE_O
-
- return_value_used = RETURN_VALUE_USED(opline);
-
-+ if (Z_LVAL(opline->op2.u.constant) != ZEND_EVAL && strlen(Z_STRVAL_P(inc_filename)) != Z_STRLEN_P(inc_filename)) {
-+ if (Z_LVAL(opline->op2.u.constant)==ZEND_INCLUDE_ONCE ||
-+ Z_LVAL(opline->op2.u.constant)==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);
-+ }
-+ goto done;
-+ }
-+
- switch (Z_LVAL(opline->op2.u.constant)) {
- case ZEND_INCLUDE_ONCE:
- case ZEND_REQUIRE_ONCE: {
-@@ -1933,6 +1943,7 @@ static int ZEND_FASTCALL ZEND_INCLUDE_O
- break;
- EMPTY_SWITCH_DEFAULT_CASE()
- }
-+done:
- if (inc_filename==&tmp_inc_filename) {
- zval_dtor(&tmp_inc_filename);
- }
-@@ -5154,6 +5165,16 @@ static int ZEND_FASTCALL ZEND_INCLUDE_O
-
- return_value_used = RETURN_VALUE_USED(opline);
-
-+ if (Z_LVAL(opline->op2.u.constant) != ZEND_EVAL && strlen(Z_STRVAL_P(inc_filename)) != Z_STRLEN_P(inc_filename)) {
-+ if (Z_LVAL(opline->op2.u.constant)==ZEND_INCLUDE_ONCE ||
-+ Z_LVAL(opline->op2.u.constant)==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);
-+ }
-+ goto done;
-+ }
-+
- switch (Z_LVAL(opline->op2.u.constant)) {
- case ZEND_INCLUDE_ONCE:
- case ZEND_REQUIRE_ONCE: {
-@@ -5207,6 +5228,7 @@ static int ZEND_FASTCALL ZEND_INCLUDE_O
- break;
- EMPTY_SWITCH_DEFAULT_CASE()
- }
-+done:
- if (inc_filename==&tmp_inc_filename) {
- zval_dtor(&tmp_inc_filename);
- }
-@@ -8524,6 +8546,16 @@ static int ZEND_FASTCALL ZEND_INCLUDE_O
-
- return_value_used = RETURN_VALUE_USED(opline);
-
-+ if (Z_LVAL(opline->op2.u.constant) != ZEND_EVAL && strlen(Z_STRVAL_P(inc_filename)) != Z_STRLEN_P(inc_filename)) {
-+ if (Z_LVAL(opline->op2.u.constant)==ZEND_INCLUDE_ONCE ||
-+ Z_LVAL(opline->op2.u.constant)==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);
-+ }
-+ goto done;
-+ }
-+
- switch (Z_LVAL(opline->op2.u.constant)) {
- case ZEND_INCLUDE_ONCE:
- case ZEND_REQUIRE_ONCE: {
-@@ -8577,6 +8609,7 @@ static int ZEND_FASTCALL ZEND_INCLUDE_O
- break;
- EMPTY_SWITCH_DEFAULT_CASE()
- }
-+done:
- if (inc_filename==&tmp_inc_filename) {
- zval_dtor(&tmp_inc_filename);
- }
-@@ -22387,6 +22420,16 @@ static int ZEND_FASTCALL ZEND_INCLUDE_O
-
- return_value_used = RETURN_VALUE_USED(opline);
-
-+ if (Z_LVAL(opline->op2.u.constant) != ZEND_EVAL && strlen(Z_STRVAL_P(inc_filename)) != Z_STRLEN_P(inc_filename)) {
-+ if (Z_LVAL(opline->op2.u.constant)==ZEND_INCLUDE_ONCE ||
-+ Z_LVAL(opline->op2.u.constant)==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);
-+ }
-+ goto done;
-+ }
-+
- switch (Z_LVAL(opline->op2.u.constant)) {
- case ZEND_INCLUDE_ONCE:
- case ZEND_REQUIRE_ONCE: {
-@@ -22440,6 +22483,7 @@ static int ZEND_FASTCALL ZEND_INCLUDE_O
- break;
- EMPTY_SWITCH_DEFAULT_CASE()
- }
-+done:
- if (inc_filename==&tmp_inc_filename) {
- zval_dtor(&tmp_inc_filename);
- }
+ }
+ PHP_ZIP_STAT_PATH(intern, filename, filename_len, flags, sb);
--- a/main/fopen_wrappers.c
+++ b/main/fopen_wrappers.c
-@@ -519,6 +519,10 @@ PHPAPI char *php_resolve_path(const char
+@@ -540,6 +540,10 @@ PHPAPI char *php_resolve_path(const char
return NULL;
}
diff --git a/debian/patches/series b/debian/patches/series
index 15567d6..09fe69b 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -35,7 +35,6 @@ mssql-null-exception.patch
sybase-alias.patch
strcmp_null-OnUpdateErrorLog.patch
#deprecate_short_open_tag
-unaligned_memory_access.patch
fix_broken_5.3_tests.patch
dont-gitclean-in-build.patch
#broken_5.3_test-posix_uname.patch
@@ -49,43 +48,14 @@ use_system_crypt_fixes.patch
session_save_path.patch
#install-programs_parallel_FTBFS.patch
#581911_pdo_mysql_segfaults.patch
-fpm_gcc_atomics.patch
php-fpm-man-section-and-cleanup.patch
fpm-config.patch
-CVE-2010-2950.patch
-php-5.3.4-ini.patch
-CVE-2010-3710.patch
-CVE-2010-3709.patch
-CVE-2010-3870.patch
-CVE-2010-4156.patch
-bug52573.patch
-bug52487.patch
-bug50481.patch
fix_crash_in__php_mssql_get_column_content_without_type.patch
-bug52827.patch
-bug52843.patch
-CVE-2010-3436.patch
-bug52947.patch
-fix_crash_in_GC.patch
bug53070.patch
-bug53323.patch
-reject-filenames-with-null-r305507.patch
-fix-open_basedir-with-separator-r305698.patch
-CVE-2010-4409.patch
-crash_in_zip_extract.patch
-unaligned_memory_access_in_hash_tiger.c.patch
-CVE-2010-4150.patch
-fix-infinite-loop-with-x87-cpu.patch
-do-not-overwrite-GLOBALS-and-this.patch
-fix-crash-if-aa-steps-are-invalid.patch
fix-crash-with-entity-declarations-in-simplexml.patch
-fix-for-NULL-deref-in-zend_language_scanner.patch
fix-integer-overflow-in-SdnToJulian.patch
fix-leak-and-possible-crash-introduced-by-the-null-poisoning-patch.patch
-fix-leaks-and-crash-bug-when-passing-the-callback-as-variable.patch
fix-memory-leak-inside-highlight_string.patch
fix-segfault-in-pgsql_stmt_execute-when-postgres-is-down.patch
-fix-segfault-when-extending-SplFixedArray.patch
fix-segfault-when-node-is-NULL-in-simplexml.patch
fix-segfault-when-using-several-cloned-intl-objects.patch
-fix-sqlite3-columnName-segfaults-on-bad-column_number.patch
diff --git a/debian/patches/session_save_path.patch b/debian/patches/session_save_path.patch
index 5e923c5..8c2ed6f 100644
--- a/debian/patches/session_save_path.patch
+++ b/debian/patches/session_save_path.patch
@@ -5,11 +5,9 @@ Origin: vendor
Forwarded: not-needed
Last-Update: 2010-05-01
-Index: php/ext/session/session.c
-===================================================================
---- php.orig/ext/session/session.c
-+++ php/ext/session/session.c
-@@ -765,7 +765,7 @@ static PHP_INI_MH(OnUpdateHashFunc) /* {
+--- a/ext/session/session.c
++++ b/ext/session/session.c
+@@ -788,7 +788,7 @@ static PHP_INI_MH(OnUpdateHashFunc) /* {
PHP_INI_BEGIN()
STD_PHP_INI_BOOLEAN("session.bug_compat_42", "1", PHP_INI_ALL, OnUpdateBool, bug_compat, php_ps_globals, ps_globals)
STD_PHP_INI_BOOLEAN("session.bug_compat_warn", "1", PHP_INI_ALL, OnUpdateBool, bug_compat_warn, php_ps_globals, ps_globals)
diff --git a/debian/patches/shtool_mkdir_-p_-race-condition.patch b/debian/patches/shtool_mkdir_-p_-race-condition.patch
index bf8765d..a74fa2b 100644
--- a/debian/patches/shtool_mkdir_-p_-race-condition.patch
+++ b/debian/patches/shtool_mkdir_-p_-race-condition.patch
@@ -8,11 +8,9 @@ Origin: vendor
Forwarded: yes
Last-Update: 2010-02-18
-Index: php/build/shtool
-===================================================================
---- php.orig/build/shtool
-+++ php/build/shtool
-@@ -991,7 +991,11 @@ mkdir )
+--- a/build/shtool
++++ b/build/shtool
+@@ -1003,7 +1003,11 @@ mkdir )
if [ ".$opt_t" = .yes ]; then
echo "mkdir $pathcomp" 1>&2
fi
diff --git a/debian/patches/unaligned_memory_access.patch b/debian/patches/unaligned_memory_access.patch
deleted file mode 100644
index ce51cee..0000000
--- a/debian/patches/unaligned_memory_access.patch
+++ /dev/null
@@ -1,27 +0,0 @@
-Description: Fix unaligned memory access.
-Origin: vendor
-Forwarded: http://bugs.php.net/50987
-Last-Update: 2010-02-09
-
-Index: php/ext/phar/phar.c
-===================================================================
---- php.orig/ext/phar/phar.c
-+++ php/ext/phar/phar.c
-@@ -512,7 +512,7 @@ void phar_entry_remove(phar_entry_data *
- (buffer) += 2
- #else
- # define PHAR_GET_32(buffer, var) \
-- var = *(php_uint32*)(buffer); \
-+ memcpy(&var, buffer, sizeof(var)); \
- buffer += 4
- # define PHAR_GET_16(buffer, var) \
- var = *(php_uint16*)(buffer); \
-@@ -2491,7 +2491,7 @@ static inline void phar_set_32(char *buf
- *((buffer) + 1) = (unsigned char) (((var) >> 8) & 0xFF);
- *((buffer) + 0) = (unsigned char) ((var) & 0xFF);
- #else
-- *(php_uint32 *)(buffer) = (php_uint32)(var);
-+ memcpy(buffer, &var, sizeof(var));
- #endif
- } /* }}} */
-
diff --git a/debian/patches/unaligned_memory_access_in_hash_tiger.c.patch b/debian/patches/unaligned_memory_access_in_hash_tiger.c.patch
deleted file mode 100644
index 4fcf9d2..0000000
--- a/debian/patches/unaligned_memory_access_in_hash_tiger.c.patch
+++ /dev/null
@@ -1,13 +0,0 @@
---- a/ext/hash/php_hash_tiger.h
-+++ b/ext/hash/php_hash_tiger.h
-@@ -25,9 +25,9 @@
- typedef struct {
- php_hash_uint64 state[3];
- php_hash_uint64 passed;
-+ unsigned char buffer[64];
- unsigned int passes:1;
- unsigned int length:7;
-- unsigned char buffer[64];
- } PHP_TIGER_CTX;
-
- PHP_HASH_API void PHP_3TIGERInit(PHP_TIGER_CTX *context);
diff --git a/debian/patches/use_embedded_timezonedb.patch b/debian/patches/use_embedded_timezonedb.patch
index 7f03a5d..e45d6a2 100644
--- a/debian/patches/use_embedded_timezonedb.patch
+++ b/debian/patches/use_embedded_timezonedb.patch
@@ -17,8 +17,8 @@ r3: fix a crash if /usr/share/zoneinfo doesn't exist (Raphael Geissert)
r2: add filesystem trawl to set up name alias index
r1: initial revision
---- pkg-php.orig/ext/date/lib/parse_tz.c
-+++ pkg-php/ext/date/lib/parse_tz.c
+--- a/ext/date/lib/parse_tz.c
++++ b/ext/date/lib/parse_tz.c
@@ -24,6 +24,16 @@
#include "timelib.h"
@@ -61,7 +61,7 @@ r1: initial revision
/* skip ID */
*tzf += 4;
-@@ -257,7 +277,435 @@ void timelib_dump_tzinfo(timelib_tzinfo
+@@ -257,7 +277,435 @@ void timelib_dump_tzinfo(timelib_tzinfo
}
}
@@ -633,8 +633,8 @@ r1: initial revision
} else {
tmp = NULL;
}
---- pkg-php.orig/ext/date/lib/timelib.m4
-+++ pkg-php/ext/date/lib/timelib.m4
+--- a/ext/date/lib/timelib.m4
++++ b/ext/date/lib/timelib.m4
@@ -78,3 +78,17 @@ stdlib.h
dnl Check for strtoll, atoll
diff --git a/debian/patches/use_embedded_timezonedb_fixes.patch b/debian/patches/use_embedded_timezonedb_fixes.patch
index 3693d8a..fa4c0d1 100644
--- a/debian/patches/use_embedded_timezonedb_fixes.patch
+++ b/debian/patches/use_embedded_timezonedb_fixes.patch
@@ -7,7 +7,7 @@ Description: Silence warnings about using the default system timezone info
Bug-Debian: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=571762
--- a/ext/date/php_date.c
+++ b/ext/date/php_date.c
-@@ -879,7 +879,7 @@ static char* guess_timezone(const timeli
+@@ -878,7 +878,7 @@ static char* guess_timezone(const timeli
tzid = "UTC";
}
diff --git a/debian/patches/use_system_crypt_fixes.patch b/debian/patches/use_system_crypt_fixes.patch
index 14b7dd0..bf7de65 100644
--- a/debian/patches/use_system_crypt_fixes.patch
+++ b/debian/patches/use_system_crypt_fixes.patch
@@ -1,6 +1,6 @@
--- a/ext/standard/tests/strings/bug51059.phpt
+++ b/ext/standard/tests/strings/bug51059.phpt
-@@ -3,7 +3,7 @@ Bug #51059 crypt() segfaults on certain
+@@ -3,7 +3,7 @@ Bug #51059 crypt() segfaults on certain
--FILE--
<?php
$res = crypt(b'a', b'_');
diff --git a/debian/patches/zend_int_overflow.patch b/debian/patches/zend_int_overflow.patch
index 591f224..ad7d655 100644
--- a/debian/patches/zend_int_overflow.patch
+++ b/debian/patches/zend_int_overflow.patch
@@ -4,8 +4,8 @@ Description: Another integer overflow/underflow logic fix.
the overflow/underflow conditions intelligently.
Bug: http://bugs.php.net/bug.php?id=51008
Bug-Debian: http://bugs.debian.org/570144
---- php.orig/Zend/zend_hash.h
-+++ php/Zend/zend_hash.h
+--- a/Zend/zend_hash.h
++++ b/Zend/zend_hash.h
@@ -306,9 +306,11 @@ END_EXTERN_C()
#define ZEND_HANDLE_NUMERIC(key, length, func) do { \
@@ -23,33 +23,33 @@ Bug-Debian: http://bugs.debian.org/570144
break; \
} \
- idx = (*tmp - '0'); \
-+ idx = ((negative)?-1:1) * (*tmp - '0'); \
++ idx = ((negative)?-1:1) * (*tmp - '0'); \
while (++tmp != end && *tmp >= '0' && *tmp <= '9') { \
- idx = (idx * 10) + (*tmp - '0'); \
-+ int digit = (*tmp - '0'); \
-+ if ( (!negative) && idx <= (LONG_MAX-digit)/10 ) { \
-+ idx = (idx * 10) + digit; \
-+ } else if ( (negative) && idx >= (LONG_MIN+digit)/10 ) { \
-+ idx = (idx * 10) - digit; \
-+ } else { \
-+ --tmp; /* overflow or underflow, make sure tmp != end */ \
-+ break; \
-+ } \
- } \
- if (tmp == end) { \
+- } \
+- if (tmp == end) { \
- if (*key == '-') { \
-- idx = -idx; \
-- if (idx > 0) { /* overflow */ \
+- if (idx-1 > LONG_MAX) { /* overflow */ \
- break; \
- } \
-- } else if (idx < 0) { /* overflow */ \
-- break; \
-- } \
+- idx = (ulong)(-(long)idx); \
+- } else if (idx > LONG_MAX) { /* overflow */ \
++ int digit = (*tmp - '0'); \
++ if ( (!negative) && idx <= (LONG_MAX-digit)/10 ) { \
++ idx = (idx * 10) + digit; \
++ } else if ( (negative) && idx >= (LONG_MIN+digit)/10 ) { \
++ idx = (idx * 10) - digit; \
++ } else { \
++ --tmp; /* overflow or underflow, make sure tmp != end */ \
+ break; \
+ } \
++ } \
++ if (tmp == end) { \
return func; \
} \
} \
---- php.orig/Zend/tests/bug45877.phpt
-+++ php/Zend/tests/bug45877.phpt
+--- a/Zend/tests/bug45877.phpt
++++ b/Zend/tests/bug45877.phpt
@@ -1,23 +1,40 @@
--TEST--
Bug #45877 (Array key '2147483647' left as string)
--
1.7.1
More information about the Pkg-php-commits
mailing list