mirror of
https://github.com/bdnugget/php-src.git
synced 2026-11-09 02:00:49 +00:00
Compare commits
3
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
6daaf1103b | ||
|
|
073d24bb50 | ||
|
|
bdb901b64a |
No files matched your search
@@ -22,10 +22,6 @@ sapi/nsapi/nsapi.c ident
|
||||
sapi/continuity/capi.c ident
|
||||
Zend/RFCs/002.txt ident
|
||||
Zend/RFCs/003.txt ident
|
||||
ext/exif/exif.c ident
|
||||
ext/ldap/ldap.c ident
|
||||
ext/pdo_pgsql/pdo_pgsql.c ident
|
||||
ext/tidy/tidy.c ident
|
||||
NEWS merge=NEWS
|
||||
UPGRADING merge=NEWS
|
||||
UPGRADING.INTERNALS merge=NEWS
|
||||
|
||||
@@ -19,7 +19,6 @@
|
||||
*.tgz
|
||||
*.tar.gz
|
||||
*.tar.bz2
|
||||
*.tar.xz
|
||||
.FBCIndex
|
||||
.FBCLockFolder
|
||||
.deps
|
||||
@@ -207,8 +206,6 @@ ext/pdo_sqlite/sqlite3.h
|
||||
ext/pdo_sqlite/tests/*.db
|
||||
ext/pdo_sqlite/tests/*.tmp
|
||||
ext/phar/phar.phar
|
||||
ext/phar/phar.1
|
||||
ext/phar/phar.phar.1
|
||||
ext/pspell/tests/*.tmp
|
||||
ext/reflection/xml
|
||||
ext/reflection/html
|
||||
@@ -240,14 +237,12 @@ sapi/apache/libphp5.module
|
||||
sapi/apache2handler/libphp5.module
|
||||
sapi/apache_hooks/libphp5.module
|
||||
sapi/cgi/php-cgi
|
||||
sapi/cgi/php-cgi.1
|
||||
sapi/cli/php.1
|
||||
sapi/fpm/php-fpm
|
||||
sapi/fpm/php-fpm.1
|
||||
sapi/fpm/init.d.php-fpm
|
||||
sapi/fpm/php-fpm.conf
|
||||
sapi/fpm/fpm/php-cgi
|
||||
sapi/phpdbg/phpdbg
|
||||
scripts/php-config
|
||||
scripts/phpize
|
||||
scripts/man1/*.1
|
||||
|
||||
+7
-14
@@ -1,11 +1,11 @@
|
||||
language: c
|
||||
language: php
|
||||
|
||||
php:
|
||||
# We only specify one version so we only get one worker
|
||||
- 5.4
|
||||
|
||||
notifications:
|
||||
email:
|
||||
on_failure: change
|
||||
|
||||
cache:
|
||||
- apt
|
||||
email: false
|
||||
|
||||
env:
|
||||
global:
|
||||
@@ -15,15 +15,8 @@ env:
|
||||
- PDO_MYSQL_TEST_USER=travis
|
||||
- PDO_MYSQL_TEST_PASS=
|
||||
- PDO_MYSQL_TEST_HOST=127.0.0.1
|
||||
- REPORT_EXIT_STATUS=1
|
||||
matrix:
|
||||
- ENABLE_MAINTAINER_ZTS=0 ENABLE_DEBUG=0
|
||||
- ENABLE_MAINTAINER_ZTS=1 ENABLE_DEBUG=1
|
||||
|
||||
before_install:
|
||||
- sudo cp ./travis/de /var/lib/locales/supported.d/de
|
||||
- sudo dpkg-reconfigure locales
|
||||
- ./travis/install.sh
|
||||
- REPORT_EXIT_STATUS=1
|
||||
|
||||
before_script:
|
||||
# Compile PHP
|
||||
|
||||
+5
-25
@@ -59,8 +59,8 @@ Exceptions:
|
||||
you're calling.
|
||||
|
||||
7. When commenting out code using a #if statement, do NOT use 0 only. Instead
|
||||
use "<git username here>_0". For example, #if FOO_0, where FOO is your
|
||||
git user foo. This allows easier tracking of why code was commented out,
|
||||
use "<svn username here>_0". For example, #if FOO_0, where FOO is your
|
||||
svn user foo. This allows easier tracking of why code was commented out,
|
||||
especially in bundled libraries.
|
||||
|
||||
8. Do not define functions that are not available. For instance, if a
|
||||
@@ -82,7 +82,7 @@ Exceptions:
|
||||
library may need to control or free the memory, or when the memory in
|
||||
question needs to survive between multiple requests.
|
||||
|
||||
User Functions/Methods Naming Conventions
|
||||
Naming Conventions
|
||||
------------------
|
||||
|
||||
1. Function names for user-level functions should be enclosed with in
|
||||
@@ -163,26 +163,6 @@ User Functions/Methods Naming Conventions
|
||||
'foobar'
|
||||
'foo_bar'
|
||||
|
||||
Internal Function Naming Convensions
|
||||
----------------------
|
||||
|
||||
1. Functions that are part of the external API should be named
|
||||
'php_modulename_function()' to avoid symbol collision. They should be in
|
||||
lowercase, with words underscore delimited. Exposed API must be defined
|
||||
in 'php_modulename.h'.
|
||||
|
||||
PHPAPI char *php_session_create_id(PS_CREATE_SID_ARGS);
|
||||
|
||||
Unexposed module function should be static and should not be defined in
|
||||
'php_modulename.h'.
|
||||
|
||||
static int php_session_destroy(TSRMLS_D)
|
||||
|
||||
2. Main module source file must be named 'modulename.c'.
|
||||
|
||||
3. Header file that is used by other sources must be named 'php_modulename.h'.
|
||||
|
||||
|
||||
Syntax and indentation
|
||||
----------------------
|
||||
|
||||
@@ -201,9 +181,9 @@ Syntax and indentation
|
||||
of PHP or one of its standard modules, please maintain the K&R
|
||||
style. This applies to just about everything, starting with
|
||||
indentation and comment styles and up to function declaration
|
||||
syntax. Also see Indentstyle.
|
||||
syntax. Also see Indentstyle_.
|
||||
|
||||
Indentstyle: http://www.catb.org/~esr/jargon/html/I/indent-style.html
|
||||
.. _Indentstyle: http://www.catb.org/~esr/jargon/html/I/indent-style.html
|
||||
|
||||
3. Be generous with whitespace and braces. Keep one empty line between the
|
||||
variable declaration section and the statements in a block, as well as
|
||||
|
||||
-12
@@ -385,12 +385,6 @@ MAINTENANCE: Maintained
|
||||
STATUS: Working
|
||||
SINCE: 4.0.4
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: hash
|
||||
PRIMARY MAINTAINER: Sara Golemon <pollita@php.net>, Mike Wallner <mike@php.net>, Anatol Belski <ab@php.net>
|
||||
MAINTENANCE: Maintained
|
||||
STATUS: Working
|
||||
SINCE: 5.1.2
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: iconv
|
||||
PRIMARY MAINTAINER: Moriyoshi Koizumi <moriyoshi@php.net>
|
||||
MAINTENANCE: Maintained
|
||||
@@ -444,12 +438,6 @@ PRIMARY MAINTAINER: Frank M. Kromann
|
||||
MAINTENANCE: Unknown
|
||||
STATUS: Experimental
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: opcache
|
||||
PRIMARY MAINTAINER: Dmitry Stogov <dmitry@zend.com>, Xinchen Hui <laruence@php.net>
|
||||
MAINTENANCE: Maintained
|
||||
STATUS: Working
|
||||
SINCE: 5.5.0
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: openssl
|
||||
PRIMARY MAINTAINER: Wez Furlong <wez@php.net>, Pierre-Alain Joye <pajoye@php.net>
|
||||
MAINTENANCE: Maintained
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
--------------------------------------------------------------------
|
||||
The PHP License, version 3.01
|
||||
Copyright (c) 1999 - 2015 The PHP Group. All rights reserved.
|
||||
Copyright (c) 1999 - 2012 The PHP Group. All rights reserved.
|
||||
--------------------------------------------------------------------
|
||||
|
||||
Redistribution and use in source and binary forms, with or without
|
||||
|
||||
+1
-1
@@ -14,7 +14,7 @@ php_lcov.info: lcov-test
|
||||
@rm -rf lcov_data/
|
||||
@$(mkinstalldirs) lcov_data/
|
||||
@echo
|
||||
-@files=`find . -name \*.gcda -o -name \*.gcno -o -name \*.da -o -name \*.c -o -name \*.h | sed -e 's/^\.\///' | sed -e 's/\.gcda//g' -e 's/\.gcno//g' -e 's/\.da//g' | $(EGREP) $(LCOV_INCLUDE) | sed -e 's/.libs/zzzz/g' | sort | sed -e 's/zzzz/.libs/g' | uniq` ;\
|
||||
-@files=`find . -name \*.gcda -o -name \*.gcno -o -name \*.da -o -name \*.c -o -name \*.h | sed -e 's/^\.\///' | sed -e 's/\.gcda//g' -e 's/\.gcno//g' -e 's/\.da//g' | $(EGREP) $(LCOV_INCLUDE) | uniq` ;\
|
||||
for x in $$files; do \
|
||||
echo -n . ;\
|
||||
y=`echo $$x | sed -e 's!\.libs/!!'`; \
|
||||
|
||||
@@ -1,803 +1,5 @@
|
||||
PHP NEWS
|
||||
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
||||
19 Feb 2015, PHP 5.5.22
|
||||
|
||||
- Core:
|
||||
. Fixed bug #67068 (getClosure returns somethings that's not a closure).
|
||||
(Danack at basereality dot com)
|
||||
. Fixed bug #68925 (Mitigation for CVE-2015-0235 – GHOST: glibc gethostbyname
|
||||
buffer overflow). (Stas)
|
||||
. Fixed bug #68942 (Use after free vulnerability in unserialize() with
|
||||
DateTimeZone). (CVE-2015-0273) (Stas)
|
||||
. Added NULL byte protection to exec, system and passthru. (Yasuo)
|
||||
. Removed support for multi-line headers, as the are deprecated by RFC 7230.
|
||||
(Stas)
|
||||
|
||||
- Date:
|
||||
. Fixed bug #45081 (strtotime incorrectly interprets SGT time zone). (Derick)
|
||||
|
||||
- Dba:
|
||||
. Fixed bug #68711 (useless comparisons). (bugreports at internot dot info)
|
||||
|
||||
- Enchant:
|
||||
. Fixed bug #6855 (heap buffer overflow in enchant_broker_request_dict()).
|
||||
(Antony)
|
||||
|
||||
- Fileinfo:
|
||||
. Fixed bug #68827 (Double free with disabled ZMM). (Joshua Rogers)
|
||||
|
||||
- FPM:
|
||||
. Fixed bug #66479 (Wrong response to FCGI_GET_VALUES). (Frank Stolle)
|
||||
. Fixed bug #68571 (core dump when webserver close the socket).
|
||||
(redfoxli069 at gmail dot com, Laruence)
|
||||
|
||||
- Libxml:
|
||||
. Fixed bug #64938 (libxml_disable_entity_loader setting is shared
|
||||
between threads). (Martin Jansen)
|
||||
|
||||
- OpenSSL:
|
||||
. Fixed bug #55618 (use case-insensitive cert name matching).
|
||||
(Daniel Lowrey)
|
||||
|
||||
- PDO_mysql:
|
||||
. Fixed bug #68750 (PDOMysql with mysqlnd does not allow the usage of
|
||||
named pipes). (steffenb198@aol.com)
|
||||
|
||||
- Phar:
|
||||
. Fixed bug #68901 (use after free). (bugreports at internot dot info)
|
||||
|
||||
- Pgsql:
|
||||
. Fixed Bug #65199 'pg_copy_from() modifies input array variable). (Yasuo)
|
||||
|
||||
- Sqlite3:
|
||||
. Fixed bug #68260 (SQLite3Result::fetchArray declares wrong
|
||||
required_num_args). (Julien)
|
||||
|
||||
- Mysqli:
|
||||
. Fixed bug #68114 (linker error on some OS X machines with fixed
|
||||
width decimal support) (Keyur Govande)
|
||||
. Fixed bug #68657 (Reading 4 byte floats with Mysqli and libmysqlclient
|
||||
has rounding errors) (Keyur Govande)
|
||||
|
||||
- Session:
|
||||
. Fixed bug #68941 (mod_files.sh is a bash-script) (bugzilla at ii.nl, Yasuo)
|
||||
. Fixed Bug #66623 (no EINTR check on flock) (Yasuo)
|
||||
. Fixed bug #68063 (Empty session IDs do still start sessions) (Yasuo)
|
||||
|
||||
- Standard:
|
||||
. Fixed bug #65272 (flock() out parameter not set correctly in windows).
|
||||
(Daniel Lowrey)
|
||||
. Fixed bug #69033 (Request may get env. variables from previous requests
|
||||
if PHP works as FastCGI)
|
||||
|
||||
- Streams:
|
||||
. Fixed bug which caused call after final close on streams filter. (Bob)
|
||||
|
||||
22 Jan 2015, PHP 5.5.21
|
||||
|
||||
- Core:
|
||||
. Upgraded crypt_blowfish to version 1.3. (Leigh)
|
||||
. Fixed bug #60704 (unlink() bug with some files path).
|
||||
. Fixed bug #65419 (Inside trait, self::class != __CLASS__). (Julien)
|
||||
. Fixed bug #65576 (Constructor from trait conflicts with inherited
|
||||
constructor). (dunglas at gmail dot com)
|
||||
. Fixed bug #55541 (errors spawn MessageBox, which blocks test automation).
|
||||
(Anatol)
|
||||
. Fixed bug #68297 (Application Popup provides too few information). (Anatol)
|
||||
. Fixed bug #65769 (localeconv() broken in TS builds). (Anatol)
|
||||
. Fixed bug #65230 (setting locale randomly broken). (Anatol)
|
||||
. Fixed bug #66764 (configure doesn't define EXPANDED_DATADIR / PHP_DATADIR
|
||||
correctly). (Ferenc)
|
||||
. Fixed bug #68583 (Crash in timeout thread). (Anatol)
|
||||
. Fixed bug #68676 (Explicit Double Free). (Kalle)
|
||||
. Fixed bug #68710 (Use After Free Vulnerability in PHP's unserialize()).
|
||||
(CVE-2015-0231) (Stefan Esser)
|
||||
|
||||
- CGI:
|
||||
. Fixed bug #68618 (out of bounds read crashes php-cgi). (CVE-2014-9427)
|
||||
(Stas)
|
||||
|
||||
- CLI server:
|
||||
. Fixed bug #68745 (Invalid HTTP requests make web server segfault). (Adam)
|
||||
|
||||
- cURL:
|
||||
. Fixed bug #67643 (curl_multi_getcontent returns '' when
|
||||
CURLOPT_RETURNTRANSFER isn't set). (Jille Timmermans)
|
||||
|
||||
- EXIF:
|
||||
. Fixed bug #68799: Free called on unitialized pointer. (CVE-2015-0232) (Stas)
|
||||
|
||||
- Fileinfo:
|
||||
. Fixed bug #68671 (incorrect expression in libmagic).
|
||||
(Joshua Rogers, Anatol Belski)
|
||||
. Removed readelf.c and related code from libmagic sources
|
||||
(Remi, Anatol)
|
||||
. Fixed bug #68735 (fileinfo out-of-bounds memory access).
|
||||
(Anatol)
|
||||
|
||||
- FPM:
|
||||
. Fixed bug #68751 (listen.allowed_clients is broken). (Remi)
|
||||
|
||||
- GD:
|
||||
. Fixed bug #68601 (buffer read overflow in gd_gif_in.c). (Jan Bee, Remi)
|
||||
|
||||
- Mbstring:
|
||||
. Fixed bug #68504 (--with-libmbfl configure option not present on Windows).
|
||||
(Ashesh Vashi)
|
||||
|
||||
- Mcrypt:
|
||||
. Fixed possible read after end of buffer and use after free. (Dmitry)
|
||||
|
||||
- Opcache:
|
||||
. Fixed bug #67111 (Memory leak when using "continue 2" inside two foreach
|
||||
loops). (Nikita)
|
||||
|
||||
- Pcntl:
|
||||
. Fixed bug #60509 (pcntl_signal doesn't decrease ref-count of old handler
|
||||
when setting SIG_DFL). (Julien)
|
||||
|
||||
- PCRE:
|
||||
. Fixed bug #66679 (Alignment Bug in PCRE 8.34 upstream).
|
||||
(Rainer Jung, Anatol Belski)
|
||||
|
||||
- pgsql:
|
||||
. Fixed bug #68697 (lo_export return -1 on failure). (Ondřej Surý)
|
||||
|
||||
- PDO:
|
||||
. Fixed bug #68371 (PDO#getAttribute() cannot be called with platform-specific
|
||||
attribute names). (Matteo)
|
||||
|
||||
- PDO_mysql:
|
||||
. Fixed bug #68424 (Add new PDO mysql connection attr to control multi
|
||||
statements option). (peter dot wolanin at acquia dot com)
|
||||
|
||||
- SPL:
|
||||
. Fixed bug #66405 (RecursiveDirectoryIterator::CURRENT_AS_PATHNAME
|
||||
breaks the RecursiveIterator). (Paul Garvin)
|
||||
. Fixed bug #65213 (cannot cast SplFileInfo to boolean) (Tjerk)
|
||||
. Fixed bug #68479 (Added escape parameter to SplFileObject::fputcsv). (Salathe)
|
||||
|
||||
- SQLite:
|
||||
. Fixed bug #68120 (Update bundled libsqlite to 3.8.7.2). (Anatol)
|
||||
|
||||
- Streams:
|
||||
. Fixed bug #68532 (convert.base64-encode omits padding bytes).
|
||||
(blaesius at krumedia dot de)
|
||||
|
||||
18 Dec 2014, PHP 5.5.20
|
||||
|
||||
- Core:
|
||||
. Fixed bug #68091 (Some Zend headers lack appropriate extern "C" blocks).
|
||||
(Adam)
|
||||
. Fixed bug #68185 ("Inconsistent insteadof definition."- incorrectly
|
||||
triggered). (Julien)
|
||||
. Fixed bug #68370 ("unset($this)" can make the program crash). (Laruence)
|
||||
. Fixed bug #68545 (NULL pointer dereference in unserialize.c). (Anatol)
|
||||
. Fixed bug #68594 (Use after free vulnerability in unserialize()).
|
||||
(CVE-2014-8142) (Stefan Esser)
|
||||
|
||||
- Date:
|
||||
. Fixed day_of_week function as it could sometimes return negative values
|
||||
internally. (Derick)
|
||||
|
||||
- FPM:
|
||||
. Fixed bug #68381 (fpm_unix_init_main ignores log_level).
|
||||
(David Zuelke, Remi)
|
||||
. Fixed bug #68420 (listen=9000 listens to ipv6 localhost instead of all
|
||||
addresses). (Remi)
|
||||
. Fixed bug #68421 (access.format='%R' doesn't log ipv6 address). (Remi)
|
||||
. Fixed bug #68423 (PHP-FPM will no longer load all pools). (Remi)
|
||||
. Fixed bug #68428 (listen.allowed_clients is IPv4 only). (Remi)
|
||||
. Fixed bug #68452 (php-fpm man page is oudated). (Remi)
|
||||
. Fixed request #68458 (Change pm.start_servers default warning to
|
||||
notice). (David Zuelke, Remi)
|
||||
. Fixed bug #68463 (listen.allowed_clients can silently result
|
||||
in no allowed access). (Remi)
|
||||
. Fixed request #68391 (php-fpm conf files loading order).
|
||||
(Florian Margaine, Remi)
|
||||
. Fixed bug #68478 (access.log don't use prefix). (Remi)
|
||||
|
||||
- Mcrypt:
|
||||
. Fixed possible read after end of buffer and use after free. (Dmitry)
|
||||
|
||||
- PDO_pgsql:
|
||||
. Fixed bug #66584 (Segmentation fault on statement deallocation) (Matteo)
|
||||
. Fixed bug #67462 (PDO_PGSQL::beginTransaction() wrongly throws exception
|
||||
when not in transaction) (Matteo)
|
||||
. Fixed bug #68351 (PDO::PARAM_BOOL and ATTR_EMULATE_PREPARES misbehaving)
|
||||
(Matteo)
|
||||
|
||||
- zlib:
|
||||
. Fixed bug #53829 (Compiling PHP with large file support will replace
|
||||
function gzopen by gzopen64) (Sascha Kettler, Matteo)
|
||||
|
||||
13 Nov 2014, PHP 5.5.19
|
||||
|
||||
- Core:
|
||||
. Fixed bug #68095 (AddressSanitizer reports a heap buffer overflow in
|
||||
php_getopt()). (Stas)
|
||||
. Fixed bug #68118 ($a->foo .= 'test'; can leave $a->foo undefined). (Nikita)
|
||||
. Fixed bug #68129 (parse_url() - incomplete support for empty usernames
|
||||
and passwords) (Tjerk)
|
||||
. Fixed bug #68365 (zend_mm_heap corrupted after memory overflow in
|
||||
zend_hash_copy). (Dmitry)
|
||||
|
||||
- CURL:
|
||||
. Add CURL_SSLVERSION_TLSv1_0, CURL_SSLVERSION_TLSv1_1, and
|
||||
CURL_SSLVERSION_TLSv1_2 constants if supported by libcurl (Rasmus)
|
||||
|
||||
- Fileinfo:
|
||||
. Fixed bug #66242 (libmagic: don't assume char is signed). (ArdB)
|
||||
. Fixed bug #68283 (fileinfo: out-of-bounds read in elf note headers).
|
||||
(CVE-2014-3710) (Remi)
|
||||
|
||||
- GD:
|
||||
. Fixed bug #65171 (imagescale() fails without height param). (Remi)
|
||||
|
||||
- GMP:
|
||||
. Fixed bug #63595 (GMP memory management conflicts with other libraries
|
||||
using GMP). (Remi)
|
||||
|
||||
- Mysqli:
|
||||
. Fixed bug #68114 (linker error on some OS X machines with fixed width
|
||||
decimal support) (Keyur Govande)
|
||||
|
||||
- ODBC:
|
||||
. Fixed bug #68087 (ODBC not correctly reading DATE column when preceded by
|
||||
a VARCHAR column) (Keyur Govande)
|
||||
|
||||
- SOAP:
|
||||
. Fixed bug #68361 (Segmentation fault on SoapClient::__getTypes).
|
||||
(Laruence)
|
||||
|
||||
- SPL:
|
||||
. Fixed bug #68128 (Regression in RecursiveRegexIterator) (Tjerk)
|
||||
|
||||
16 Oct 2014, PHP 5.5.18
|
||||
|
||||
- Core:
|
||||
. Fixed bug #67985 (Incorrect last used array index copied to new array after
|
||||
unset). (Tjerk)
|
||||
. Fixed bug #67739 (Windows 8.1/Server 2012 R2 OS build number reported
|
||||
as 6.2 (instead of 6.3)). (Christian Wenz)
|
||||
. Fixed bug #67633 (A foreach on an array returned from a function not doing
|
||||
copy-on-write). (Nikita)
|
||||
. Fixed bug #51800 (proc_open on Windows hangs forever). (Anatol)
|
||||
|
||||
- FPM:
|
||||
. Fixed bug #65641 (PHP-FPM incorrectly defines the SCRIPT_NAME variable
|
||||
when using Apache, mod_proxy-fcgi and ProxyPass). (Remi)
|
||||
. Implemented FR #55508 (listen and listen.allowed_clients should take IPv6
|
||||
addresses). (Robin Gloster)
|
||||
|
||||
- Reflection:
|
||||
. Fixed bug #68103 (Duplicate entry in Reflection for class alias). (Remi)
|
||||
|
||||
- Session:
|
||||
. Fixed bug #67972 (SessionHandler Invalid memory read create_sid()). (Adam)
|
||||
|
||||
18 Sep 2014, PHP 5.5.17
|
||||
|
||||
- Core:
|
||||
. Fixed bug #47358 (glob returns error, should be empty array()). (Pierre)
|
||||
. Fixed bug #65463 (SIGSEGV during zend_shutdown()). (Keyur Govande)
|
||||
. Fixed bug #66036 (Crash on SIGTERM in apache process). (Keyur Govande)
|
||||
. Fixed bug #67878 (program_prefix not honoured in man pages). (Remi)
|
||||
|
||||
- COM:
|
||||
. Fixed bug #41577 (DOTNET is successful once per server run)
|
||||
(Aidas Kasparas)
|
||||
|
||||
- FPM:
|
||||
. Fixed #67606 (FPM with mod_fastcgi/apache2.4 is broken). (David Zuelke)
|
||||
|
||||
- OpenSSL:
|
||||
. Fixed bug #41631 (socket timeouts not honored in blocking SSL reads).
|
||||
(Daniel Lowrey)
|
||||
. Fixed bug #67850 (extension won't build if openssl compiled without SSLv3)
|
||||
(Daniel Lowrey)
|
||||
|
||||
- SPL:
|
||||
. Fixed bug #67813 (CachingIterator::__construct InvalidArgumentException
|
||||
wrong message). (tim_siebels_aurich at yahoo dot de)
|
||||
|
||||
- Date:
|
||||
. Fixed bug #66091 (memory leaks in DateTime constructor). (Tjerk)
|
||||
. Fixed bug #66985 (Some timezones are no longer valid in PHP 5.5.10).
|
||||
(Derick)
|
||||
. Fixed bug #67109 (First uppercase letter breaks date string parsing).
|
||||
(Derick)
|
||||
|
||||
- GD
|
||||
. Made fontFetch's path parser thread-safe. (Sara).
|
||||
|
||||
- MySQLi:
|
||||
. Fixed bug #67839 (mysqli does not handle 4-byte floats correctly). (Keyur)
|
||||
|
||||
- Zlib:
|
||||
. Fixed bug #67724 (chained zlib filters silently fail with large amounts of
|
||||
data). (Mike)
|
||||
. Fixed bug #67865 (internal corruption phar error). Mike
|
||||
|
||||
21 Aug 2014, PHP 5.5.16
|
||||
|
||||
- COM:
|
||||
. Fixed missing type checks in com_event_sink (Yussuf Khalil, Stas).
|
||||
|
||||
- Fileinfo:
|
||||
. Fixed bug #67705 (extensive backtracking in rule regular expression).
|
||||
(CVE-2014-3538) (Remi)
|
||||
. Fixed bug #67716 (Segfault in cdf.c). (CVE-2014-3587) (Remi)
|
||||
|
||||
- FPM:
|
||||
. Fixed bug #67635 (php links to systemd libraries without using pkg-config).
|
||||
(pacho@gentoo.org, Remi)
|
||||
|
||||
- GD:
|
||||
. Fixed bug #66901 (php-gd 'c_color' NULL pointer dereference).
|
||||
(CVE-2014-2497) (Remi)
|
||||
. Fixed bug #67730 (Null byte injection possible with imagexxx functions).
|
||||
(CVE-2014-5120) (Ryan Mauger)
|
||||
|
||||
- Milter:
|
||||
. Fixed bug #67715 (php-milter does not build and crashes randomly). (Mike)
|
||||
|
||||
- Network:
|
||||
. Fixed bug #67717 (segfault in dns_get_record). (CVE-2014-3597) (Remi)
|
||||
|
||||
- OpenSSL:
|
||||
. Fixed missing type checks in OpenSSL options. (Yussuf Khalil, Stas)
|
||||
|
||||
- readline:
|
||||
. Fixed bug #55496 (Interactive mode doesn't force a newline before the
|
||||
prompt). (Bob, Johannes)
|
||||
. Fixed bug #67496 (Save command history when exiting interactive shell
|
||||
with control-c). (Dmitry Saprykin, Johannes)
|
||||
|
||||
- Sessions:
|
||||
. Fixed missing type checks in php_session_create_id (Yussuf Khalil, Stas).
|
||||
|
||||
- Core:
|
||||
. Fixed bug #67693 (incorrect push to the empty array) (Tjerk)
|
||||
|
||||
- ODBC:
|
||||
. Fixed bug #60616 (odbc_fetch_into returns junk data at end of multi-byte
|
||||
char fields). (Keyur)
|
||||
|
||||
24 Jul 2014, PHP 5.5.15
|
||||
|
||||
- Core:
|
||||
. Fixed bug #67428 (header('Location: foo') will override a 308-399 response
|
||||
code). (Adam)
|
||||
. Fixed bug #67436 (Autoloader isn't called if two method definitions don't
|
||||
match). (Bob)
|
||||
. Fixed bug #67091 (make install fails to install libphp5.so on FreeBSD 10.0).
|
||||
(Ferenc)
|
||||
. Fixed bug #67497 (eval with parse error causes segmentation fault in
|
||||
generator). (Nikita)
|
||||
. Fixed bug #67151 (strtr with empty array crashes). (Nikita)
|
||||
. Fixed bug #67407 (Windows 8.1/Server 2012 R2 reported as Windows 8/Server
|
||||
2012). (Christian Wenz)
|
||||
. Fixed bug #66608 (Incorrect behavior with nested "finally" blocks).
|
||||
(Laruence, Dmitry)
|
||||
. Implemented FR #34407 (ucwords and Title Case). (Tjerk)
|
||||
|
||||
- CLI server:
|
||||
. Implemented FR #67429 (CLI server is missing some new HTTP response codes).
|
||||
(Adam)
|
||||
. Fixed bug #66830 (Empty header causes PHP built-in web server to hang).
|
||||
(Adam)
|
||||
. Fixed bug #67594 (Unable to access to apache_request_headers() elements).
|
||||
(Tjerk)
|
||||
|
||||
- FPM:
|
||||
. Fixed bug #67530 (error_log=syslog ignored). (Remi)
|
||||
. Fixed bug #67531 (syslog cannot be set in pool configuration). (Remi)
|
||||
|
||||
- Intl:
|
||||
. Fixed bug #66921 (Wrong argument type hint for function
|
||||
intltz_from_date_time_zone). (Stas)
|
||||
. Fixed bug #67052 (NumberFormatter::parse() resets LC_NUMERIC setting).
|
||||
(Stas)
|
||||
|
||||
- OPCache:
|
||||
. Fixed bug #67215 (php-cgi work with opcache, may be segmentation fault
|
||||
happen) (Dmitry, Laruence)
|
||||
|
||||
- pgsql:
|
||||
. Fixed bug #67550 (Error in code "form" instead of "from", pgsql.c, line 756),
|
||||
which affected builds against libpq < 7.3. (Adam)
|
||||
|
||||
- Phar:
|
||||
. Fixed bug #67587 (Redirection loop on nginx with FPM). (Christian Weiske)
|
||||
|
||||
- SPL:
|
||||
. Fixed bug #67539 (ArrayIterator use-after-free due to object change during
|
||||
sorting). (CVE-2014-4698) (research at insighti dot org, Laruence)
|
||||
. Fixed bug #67538 (SPL Iterators use-after-free). (CVE-2014-4670) (Laruence)
|
||||
|
||||
- Streams:
|
||||
. Fixed bug #67430 (http:// wrapper doesn't follow 308 redirects). (Adam)
|
||||
|
||||
- Session:
|
||||
. Fixed bug #66827 (Session raises E_NOTICE when session name variable is array).
|
||||
(Yasuo)
|
||||
|
||||
27 Jun 2014, PHP 5.5.14
|
||||
|
||||
- Core:
|
||||
. Fixed BC break introduced by patch for bug #67072. (Anatol, Stas)
|
||||
. Fixed bug #66622 (Closures do not correctly capture the late bound class
|
||||
(static::) in some cases). (Levi Morrison)
|
||||
. Fixed bug #67390 (insecure temporary file use in the configure script).
|
||||
(Remi) (CVE-2014-3981)
|
||||
. Fixed bug #67399 (putenv with empty variable may lead to crash). (Stas)
|
||||
|
||||
- CLI server:
|
||||
. Fixed Bug #67406 (built-in web-server segfaults on startup). (Remi)
|
||||
|
||||
- Date:
|
||||
. Fixed bug #67308 (Serialize of DateTime truncates fractions of second).
|
||||
(Adam)
|
||||
. Fixed regression in fix for bug #67118 (constructor can't be called twice).
|
||||
(Remi)
|
||||
|
||||
- Fileinfo:
|
||||
. Fixed bug #67326 (fileinfo: cdf_read_short_sector insufficient boundary check).
|
||||
. Fixed bug #67410 (fileinfo: mconvert incorrect handling of truncated pascal
|
||||
string size). (Francisco Alonso, Jan Kaluza, Remi)
|
||||
. Fixed bug #67411 (fileinfo: cdf_check_stream_offset insufficient boundary
|
||||
check). (Francisco Alonso, Jan Kaluza, Remi)
|
||||
. Fixed bug #67412 (fileinfo: cdf_count_chain insufficient boundary check).
|
||||
(Francisco Alonso, Jan Kaluza, Remi)
|
||||
. Fixed bug #67413 (fileinfo: cdf_read_property_info insufficient boundary
|
||||
check). (Francisco Alonso, Jan Kaluza, Remi)
|
||||
|
||||
- LiteSpeed:
|
||||
. Updated LiteSpeed SAPI code from V5.5 to V6.6 (George Wang)
|
||||
|
||||
- Network:
|
||||
. Fixed bug #67432 (Fix potential segfault in dns_get_record()).
|
||||
(CVE-2014-4049). (Sara)
|
||||
|
||||
- OPCache:
|
||||
. Fixed issue #183 (TMP_VAR is not only used once). (Dmitry, Laruence)
|
||||
|
||||
- OpenSSL:
|
||||
. Fixed bug #65698 (certificates validity parsing does not work past 2050).
|
||||
(Paul Oehler)
|
||||
. Fixed bug #66636 (openssl_x509_parse warning with V_ASN1_GENERALIZEDTIME).
|
||||
(Paul Oehler)
|
||||
|
||||
- PDO-ODBC:
|
||||
. Fixed bug #50444 (PDO-ODBC changes for 64-bit).
|
||||
|
||||
- SOAP:
|
||||
. Implemented FR #49898 (Add SoapClient::__getCookies()). (Boro Sitnikovski)
|
||||
|
||||
- SPL:
|
||||
. Fixed bug #66127 (Segmentation fault with ArrayObject unset). (Stas)
|
||||
. Fixed bug #67359 (Segfault in recursiveDirectoryIterator). (Laruence)
|
||||
. Fixed bug #67360 (Missing element after ArrayObject::getIterator). (Adam)
|
||||
. Fixed bug #67492 (unserialize() SPL ArrayObject / SPLObjectStorage Type
|
||||
Confusion). (CVE-2014-3515) (Stefan Esser)
|
||||
|
||||
29 May 2014, PHP 5.5.13
|
||||
|
||||
- CLI server:
|
||||
. Fixed bug #67079 (Missing MIME types for XML/XSL files). (Anatol)
|
||||
|
||||
- COM:
|
||||
. Fixed bug #66431 (Special Character via COM Interface (CP_UTF8)). (Anatol)
|
||||
|
||||
- Core:
|
||||
. Fixed bug #65701 (copy() doesn't work when destination filename is created
|
||||
by tempnam()). (Boro Sitnikovski)
|
||||
. Fixed bug #67072 (Echoing unserialized "SplFileObject" crash). (Anatol)
|
||||
. Fixed bug #67245 (usage of memcpy() with overlapping src and dst in
|
||||
zend_exceptions.c). (Bob)
|
||||
. Fixed bug #67247 (spl_fixedarray_resize integer overflow). (Stas)
|
||||
. Fixed bug #67249 (printf out-of-bounds read). (Stas)
|
||||
. Fixed bug #67250 (iptcparse out-of-bounds read). (Stas)
|
||||
. Fixed bug #67252 (convert_uudecode out-of-bounds read). (Stas)
|
||||
|
||||
- Curl:
|
||||
. Fixed bug #64247 (CURLOPT_INFILE doesn't allow reset). (Mike)
|
||||
|
||||
- Date:
|
||||
. Fixed bug #67118 (DateTime constructor crash with invalid data). (Anatol)
|
||||
. Fixed bug #67251 (date_parse_from_format out-of-bounds read). (Stas)
|
||||
. Fixed bug #67253 (timelib_meridian_with_check out-of-bounds read). (Stas)
|
||||
|
||||
- DOM:
|
||||
. Fixed bug #67081 (DOMDocumentType->internalSubset returns entire DOCTYPE tag,
|
||||
not only the subset). (Anatol)
|
||||
|
||||
- Fileinfo:
|
||||
. Fixed bug #66307 (Fileinfo crashes with powerpoint files). (Anatol)
|
||||
. Fixed bug #67327 (fileinfo: CDF infinite loop in nelements DoS) (CVE-2014-0238).
|
||||
. Fixed bug #67328 (fileinfo: fileinfo: numerous file_printf calls resulting in
|
||||
performance degradation) (CVE-2014-0237).
|
||||
|
||||
- FPM:
|
||||
. Fixed bug #66908 (php-fpm reload leaks epoll_create() file descriptor).
|
||||
(Julio Pintos)
|
||||
|
||||
- GD:
|
||||
. Fixed bug #67248 (imageaffinematrixget missing check of parameters). (Stas)
|
||||
|
||||
- PCRE:
|
||||
. Fixed bug #67238 (Ungreedy and min/max quantifier bug, applied patch
|
||||
from the upstream). (Anatol)
|
||||
|
||||
- Phar:
|
||||
. Fix bug #64498 ($phar->buildFromDirectory can't compress file with an accent
|
||||
in its name). (PR #588)
|
||||
|
||||
30 Apr 2014, PHP 5.5.12
|
||||
- Core:
|
||||
. Fixed bug #61019 (Out of memory on command stream_get_contents). (Mike)
|
||||
. Fixed bug #64330 (stream_socket_server() creates wrong Abstract Namespace
|
||||
UNIX sockets). (Mike)
|
||||
. Fixed bug #66182 (exit in stream filter produces segfault). (Mike)
|
||||
. Fixed bug #66736 (fpassthru broken). (Mike)
|
||||
. Fixed bug #67024 (getimagesize should recognize BMP files with negative
|
||||
height). (Gabor Buella)
|
||||
. Fixed bug #67043 (substr_compare broke by previous change) (Tjerk)
|
||||
. Fixed bug #67033 (Remove reference to Windows 95). (Anatol)
|
||||
|
||||
- cURL:
|
||||
. Fixed bug #66562 (curl_exec returns differently than curl_multi_getcontent).
|
||||
(Freek Lijten)
|
||||
|
||||
- Date:
|
||||
. Fixed bug #66721 (__wakeup of DateTime segfaults when invalid object data is
|
||||
supplied). (Boro Sitnikovski)
|
||||
|
||||
- Embed:
|
||||
. Fixed bug #65715 (php5embed.lib isn't provided anymore). (Anatol).
|
||||
|
||||
- Fileinfo:
|
||||
. Fixed bug #66987 (Memory corruption in fileinfo ext / bigendian).
|
||||
(Remi)
|
||||
|
||||
- FPM:
|
||||
. Fixed bug #66482 (unknown entry 'priority' in php-fpm.conf).
|
||||
. Fixed bug #67060 (sapi/fpm: possible privilege escalation due to insecure
|
||||
default configuration) (CVE-2014-0185). (Stas)
|
||||
|
||||
- JSON:
|
||||
. Fixed bug #66021 (Blank line inside empty array/object when
|
||||
JSON_PRETTY_PRINT is set). (Kevin Israel)
|
||||
|
||||
- LDAP:
|
||||
. Fixed issue with null bytes in LDAP bindings. (Matthew Daley)
|
||||
|
||||
- mysqli:
|
||||
. Fixed problem in mysqli_commit()/mysqli_rollback() with second parameter
|
||||
(extra comma) and third parameters (lack of escaping). (Andrey)
|
||||
|
||||
- OpenSSL:
|
||||
. Fix bug #66942 (memory leak in openssl_seal()). (Chuan Ma)
|
||||
. Fix bug #66952 (memory leak in openssl_open()). (Chuan Ma)
|
||||
|
||||
- SimpleXML:
|
||||
. Fixed bug #66084 (simplexml_load_string() mangles empty node name)
|
||||
(Anatol)
|
||||
|
||||
- SQLite:
|
||||
. Fixed bug #66967 (Updated bundled libsqlite to 3.8.4.3). (Anatol)
|
||||
|
||||
- XSL:
|
||||
. Fixed bug #53965 (<xsl:include> cannot find files with relative paths
|
||||
when loaded with "file://"). (Anatol)
|
||||
|
||||
- Apache2 Handler SAPI:
|
||||
. Fixed Apache log issue caused by APR's lack of support for %zu
|
||||
(APR issue https://issues.apache.org/bugzilla/show_bug.cgi?id=56120).
|
||||
(Jeff Trawick)
|
||||
|
||||
03 Apr 2014, PHP 5.5.11
|
||||
|
||||
- Core:
|
||||
. Allow zero length comparison in substr_compare() (Tjerk)
|
||||
. Fixed bug #60602 (proc_open() changes environment array) (Tjerk)
|
||||
|
||||
- SPL:
|
||||
. Added feature #65545 (SplFileObject::fread()) (Tjerk)
|
||||
. Fixed bug #66702 (RegexIterator::INVERT_MATCH does not invert). (Joshua
|
||||
Thijssen)
|
||||
|
||||
- cURL:
|
||||
. Fixed bug #66109 (Can't reset CURLOPT_CUSTOMREQUEST to default behaviour) (Tjerk)
|
||||
. Fix compilation on libcurl versions between 7.10.5 and 7.12.2, inclusive.
|
||||
(Adam)
|
||||
|
||||
- Fileinfo:
|
||||
. Fixed bug #66946i (fileinfo: extensive backtracking in awk rule regular
|
||||
expression). (CVE-2013-7345) (Remi)
|
||||
|
||||
- FPM:
|
||||
. Added clear_env configuration directive to disable clearenv() call.
|
||||
(Github PR# 598, Paul Annesley)
|
||||
|
||||
- GD:
|
||||
. Fixed bug #66714 (imageconvolution breakage). (Brad Daily)
|
||||
. Fixed bug #66869 (Invalid 2nd argument crashes imageaffinematrixget) (Pierre)
|
||||
. Fixed bug #66887 (imagescale - poor quality of scaled image). (Remi)
|
||||
. Fixed bug #66890 (imagescale segfault). (Remi)
|
||||
. Fixed bug #66893 (imagescale ignore method argument). (Remi)
|
||||
|
||||
- Hash:
|
||||
. hash_pbkdf2() now works correctly if the $length argument is not specified.
|
||||
(Nikita)
|
||||
|
||||
- Intl:
|
||||
. Fixed bug #66873 (A reproductible crash in UConverter when given invalid
|
||||
encoding) (Stas)
|
||||
|
||||
- Mail:
|
||||
. Fixed bug #66535 (Don't add newline after X-PHP-Originating-Script) (Tjerk)
|
||||
|
||||
- MySQLi:
|
||||
. Fixed bug #66762 (Segfault in mysqli_stmt::bind_result() when link closed)
|
||||
(Remi)
|
||||
|
||||
- OPCache
|
||||
. Added function opcache_is_script_cached(). (Danack)
|
||||
. Added information about interned strings usage. (Terry, Julien, Dmitry)
|
||||
|
||||
- Openssl:
|
||||
. Fixed bug #66833 (Default disgest algo is still MD5, switch to SHA1). (Remi)
|
||||
|
||||
- GMP
|
||||
. Fixed bug #66872 (invalid argument crashes gmp_testbit) (Pierre)
|
||||
|
||||
- SQLite:
|
||||
. Updated bundled libsqlite to 3.8.3.1 (Anatol)
|
||||
|
||||
06 Mar 2014, PHP 5.5.10
|
||||
|
||||
- Core:
|
||||
. Fixed Request #66574i (Allow multiple paths in php_ini_scanned_path). (Remi)
|
||||
|
||||
- Date:
|
||||
. Fixed bug #45528 (Allow the DateTimeZone constructor to accept timezones
|
||||
per offset too). (Derick)
|
||||
|
||||
- Fileinfo:
|
||||
. Bug #66731 (file: infinite recursion) (CVE-2014-1943). (Remi)
|
||||
. Fixed bug #66820 (out-of-bounds memory access in fileinfo)
|
||||
(CVE-2014-2270). (Remi)
|
||||
|
||||
- GD
|
||||
. Fixed Bug #66815 (imagecrop(): insufficient fix for NULL defer
|
||||
CVE-2013-7327). (Tomas Hoger, Remi)
|
||||
|
||||
- JSON:
|
||||
. Fixed bug #65753 (JsonSerializeable couldn't implement on module extension)
|
||||
(chobieeee@php.net)
|
||||
|
||||
- LDAP:
|
||||
. Implemented ldap_modify_batch (https://wiki.php.net/rfc/ldap_modify_batch).
|
||||
(Ondřej Hošek)
|
||||
|
||||
- Openssl:
|
||||
. Fixed bug #66501 (Add EC key support to php_openssl_is_private_key).
|
||||
(Mark Zedwood)
|
||||
|
||||
- PCRE:
|
||||
. Upgraded to PCRE 8.34. (Anatol)
|
||||
|
||||
- Pgsql:
|
||||
. Added warning for dangerous client encoding and remove possible injections
|
||||
for pg_insert()/pg_update()/pg_delete()/pg_select(). (Yasuo)
|
||||
|
||||
|
||||
06 Feb 2014, PHP 5.5.9
|
||||
|
||||
- Core:
|
||||
. Fixed bug #66509 (copy() arginfo has changed starting from 5.4). (willfitch)
|
||||
|
||||
- GD:
|
||||
. Fixed bug #66356 (Heap Overflow Vulnerability in imagecrop()).
|
||||
(Laruence, Remi)
|
||||
|
||||
- OPCache:
|
||||
. Fixed bug #66474 (Optimizer bug in constant string to boolean conversion).
|
||||
(Dmitry)
|
||||
. Fixed bug #66461 (PHP crashes if opcache.interned_strings_buffer=0).
|
||||
(Dmitry)
|
||||
. Fixed bug #66298 (ext/opcache/Optimizer/zend_optimizer.c has dos-style
|
||||
^M as lineend). (Laruence)
|
||||
|
||||
- PDO_pgsql:
|
||||
. Fixed bug #62479 (PDO-psql cannot connect if password contains
|
||||
spaces) (willfitch, iliaa)
|
||||
|
||||
- Readline
|
||||
. Fixed Bug #66412 (readline_clear_history() with libedit causes segfault after
|
||||
#65714). (Remi)
|
||||
|
||||
- Session
|
||||
. Fixed bug #66469 (Session module is sending multiple set-cookie headers when
|
||||
session.use_strict_mode=1) (Yasuo)
|
||||
. Fixed bug #66481 (Segfaults on session_name()).
|
||||
(cmcdermottroe at engineyard dot com, Yasuo)
|
||||
|
||||
- Standard
|
||||
. Fixed bug #66395 (basename function doesn't remove drive letter). (Anatol)
|
||||
|
||||
- Sockets:
|
||||
. Fixed bug #66381 (__ss_family was changed on AIX 5.3). (Felipe)
|
||||
|
||||
- Zend Engine
|
||||
. Fixed bug #66009 (Failed compilation of PHP extension with C++ std
|
||||
library using VS 2012). (Anatol)
|
||||
|
||||
09 Jan 2014, PHP 5.5.8
|
||||
|
||||
- Core:
|
||||
. Disallowed JMP into a finally block. (Laruence)
|
||||
. Added validation of class names in the autoload process. (Dmitry)
|
||||
. Fixed invalid C code in zend_strtod.c. (Lior Kaplan)
|
||||
. Fixed ZEND_MM_MEM_TYPE=mmap_zero. (Dmitry, Tony)
|
||||
. Fixed bug #66041 (list() fails to unpack yielded ArrayAccess object).
|
||||
(Nikita)
|
||||
. Fixed bug #65764 (generators/throw_rethrow FAIL with
|
||||
ZEND_COMPILE_EXTENDED_INFO). (Nikita)
|
||||
. Fixed bug #61645 (fopen and O_NONBLOCK). (Mike)
|
||||
. Fixed bug #66218 (zend_register_functions breaks reflection). (Remi)
|
||||
|
||||
- Date:
|
||||
. Fixed bug #66060 (Heap buffer over-read in DateInterval) (CVE-2013-6712).
|
||||
(Remi)
|
||||
. Fixed bug #65768 (DateTimeImmutable::diff does not work). (Nikita Nefedov)
|
||||
|
||||
- DOM:
|
||||
. Fixed bug #65196 (Passing DOMDocumentFragment to DOMDocument::saveHTML()
|
||||
Produces invalid Markup). (Mike)
|
||||
|
||||
- Exif:
|
||||
. Fixed bug #65873 (Integer overflow in exif_read_data()). (Stas)
|
||||
|
||||
- Filter:
|
||||
. Fixed bug #66229 (128.0.0.0/16 isn't reserved any longer). (Adam)
|
||||
|
||||
- GD:
|
||||
. Fixed bug #64405 (Use freetype-config for determining freetype2 dir(s)).
|
||||
(Adam)
|
||||
|
||||
- PDO_odbc:
|
||||
. Fixed bug #66311 (Stack smashing protection kills PDO/ODBC queries).
|
||||
(michael at orlitzky dot com)
|
||||
|
||||
- MySQLi:
|
||||
. Fixed bug #65486 (mysqli_poll() is broken on win x64). (Anatol)
|
||||
|
||||
- OPCache:
|
||||
. Fixed revalidate_path=1 behavior to avoid caching of symlinks values.
|
||||
(Dmitry)
|
||||
. Fixed Issue #140: "opcache.enable_file_override" doesn't respect
|
||||
"opcache.revalidate_freq". (Dmitry).
|
||||
|
||||
- SNMP:
|
||||
. Fixed SNMP_ERR_TOOBIG handling for bulk walk operations. (Boris Lytochkin)
|
||||
|
||||
- SOAP
|
||||
. Fixed bug #66112 (Use after free condition in SOAP extension).
|
||||
(martin dot koegler at brz dot gv dot at)
|
||||
|
||||
- Sockets:
|
||||
. Fixed bug #65923 (ext/socket assumes AI_V4MAPPED is defined). (Felipe)
|
||||
|
||||
- XSL
|
||||
. Fixed bug #49634 (Segfault throwing an exception in a XSL registered
|
||||
function). (Mike)
|
||||
|
||||
- ZIP:
|
||||
. Fixed Bug #66321 (ZipArchive::open() ze_obj->filename_len not real). (Remi)
|
||||
|
||||
12 Dec 2013, PHP 5.5.7
|
||||
|
||||
- CLI server:
|
||||
@@ -808,7 +10,6 @@ spaces) (willfitch, iliaa)
|
||||
- Core:
|
||||
. Fixed bug #66094 (unregister_tick_function tries to cast a Closure to a
|
||||
string). (Laruence)
|
||||
. Fixed bug #65969 (Chain assignment with T_LIST failure). (Dmitry)
|
||||
|
||||
- OPCache
|
||||
. Fixed bug #66176 (Invalid constant substitution). (Dmitry)
|
||||
@@ -816,13 +17,13 @@ spaces) (willfitch, iliaa)
|
||||
. Fixed bug #65559 (Opcache: cache not cleared if changes occur while
|
||||
running). (Dmitry)
|
||||
|
||||
- readline
|
||||
. Fixed Bug #65714 (PHP cli forces the tty to cooked mode). (Remi)
|
||||
|
||||
- Openssl:
|
||||
- OpenSSL:
|
||||
. Fixed memory corruption in openssl_x509_parse() (CVE-2013-6420).
|
||||
(Stefan Esser).
|
||||
|
||||
- readline
|
||||
. Fixed Bug #65714 (PHP cli forces the tty to cooked mode). (Remi)
|
||||
|
||||
14 Nov 2013, PHP 5.5.6
|
||||
|
||||
- Core:
|
||||
@@ -1304,12 +505,6 @@ spaces) (willfitch, iliaa)
|
||||
CURLOPT_RTSP_REQUEST, CURLOPT_RESOLVE, CURLOPT_ACCEPT_ENCODING,
|
||||
CURLOPT_TRANSFER_ENCODING, CURLOPT_DNS_SERVERS and CURLOPT_USE_SSL.
|
||||
(Pierrick)
|
||||
. Added new functions curl_escape, curl_multi_setopt, curl_multi_strerror
|
||||
curl_pause, curl_reset, curl_share_close, curl_share_init,
|
||||
curl_share_setopt curl_strerror and curl_unescape. (Pierrick)
|
||||
. Addes new curl options CURLOPT_TELNETOPTIONS, CURLOPT_GSSAPI_DELEGATION,
|
||||
CURLOPT_ACCEPTTIMEOUT_MS, CURLOPT_SSL_OPTIONS, CURLOPT_TCP_KEEPALIVE,
|
||||
CURLOPT_TCP_KEEPIDLE and CURLOPT_TCP_KEEPINTVL. (Pierrick)
|
||||
. Fixed bug #55635 (CURLOPT_BINARYTRANSFER no longer used. The constant
|
||||
still exists for backward compatibility but is doing nothing). (Pierrick)
|
||||
. Fixed bug #54995 (Missing CURLINFO_RESPONSE_CODE support). (Pierrick)
|
||||
@@ -1317,6 +512,12 @@ spaces) (willfitch, iliaa)
|
||||
- DateTime
|
||||
. Added DateTimeImmutable - a variant of DateTime that only returns the
|
||||
modified state instead of changing itself. (Derick)
|
||||
. Added new functions curl_escape, curl_multi_setopt, curl_multi_strerror
|
||||
curl_pause, curl_reset, curl_share_close, curl_share_init,
|
||||
curl_share_setopt curl_strerror and curl_unescape. (Pierrick)
|
||||
. Addes new curl options CURLOPT_TELNETOPTIONS, CURLOPT_GSSAPI_DELEGATION,
|
||||
CURLOPT_ACCEPTTIMEOUT_MS, CURLOPT_SSL_OPTIONS, CURLOPT_TCP_KEEPALIVE,
|
||||
CURLOPT_TCP_KEEPIDLE and CURLOPT_TCP_KEEPINTVL. (Pierrick)
|
||||
. Fixed bug #64825 (Invalid free when unserializing DateTimeZone).
|
||||
(Anatol)
|
||||
. Fixed bug #64359 (strftime crash with VS2012). (Anatol)
|
||||
@@ -1772,8 +973,7 @@ spaces) (willfitch, iliaa)
|
||||
. Fixed bug #63999 (php with fpm fails to build on Solaris 10 or 11). (Adam)
|
||||
|
||||
- Litespeed:
|
||||
. Fixed bug #63228 (-Werror=format-security error in lsapi code).
|
||||
(Elan Ruusamäe, George)
|
||||
. Fixed bug #63228 (-Werror=format-security error in lsapi code). (George)
|
||||
|
||||
- ext/sqlite3:
|
||||
. Fixed bug #63921 (sqlite3::bindvalue and relative PHP functions aren't
|
||||
|
||||
@@ -1,11 +1,3 @@
|
||||
This file describes extension module API details. Refer to
|
||||
README.EXT_SKEL to create extension skeleton files. Refer to
|
||||
Hacker's Guide for PHP internals.
|
||||
|
||||
http://www.php.net/manual/en/internals2.php
|
||||
|
||||
|
||||
|
||||
Between PHP 4.0.6 and 4.1.0, the Zend module struct changed in a way
|
||||
that broke both source and binary compatibility. If you are
|
||||
maintaining a third party extension, here's how to update it:
|
||||
|
||||
+6
-24
@@ -45,29 +45,12 @@ HOW TO USE IT
|
||||
|
||||
--proto=filename.
|
||||
|
||||
SOURCE AND HEADER FILE NAME
|
||||
|
||||
./ext_skel generates 'module_name.c' and 'php_module_name.h' as main source
|
||||
and header files. Keep these names.
|
||||
|
||||
Module functions (User functions) must be named
|
||||
|
||||
module_name_function()
|
||||
|
||||
When you need to expose module functions to other modules, expose functions
|
||||
strictly needed by others. Exposed internal function must be named
|
||||
|
||||
php_module_name_function()
|
||||
|
||||
See also CODING_STANDARDS.
|
||||
|
||||
|
||||
FORMAT OF FUNCTION DEFINITIONS FILE
|
||||
|
||||
All the definitions must be on one line. In it's simplest form, it's just
|
||||
the function name, e.g.
|
||||
|
||||
module_name_function
|
||||
my_function
|
||||
|
||||
but then you'll be left with an almost empty function body without any
|
||||
argument handling.
|
||||
@@ -89,9 +72,8 @@ FORMAT OF FUNCTION DEFINITIONS FILE
|
||||
|
||||
An example:
|
||||
|
||||
module_name_function(int arg1, int arg2 [, int arg3 [, int arg4]])
|
||||
my_function(int arg1, int arg2 [, int arg3 [, int arg4]]) this is my 1st
|
||||
|
||||
Arguments arg1 and arg2 are required.
|
||||
Arguments arg3 and arg4 are optional.
|
||||
|
||||
If possible, the function definition should also contain it's return type
|
||||
@@ -151,15 +133,15 @@ EXAMPLE
|
||||
|
||||
The following _one_ line
|
||||
|
||||
bool module_name_drawtext(resource image, string text, resource font, int x, int y [, int color])
|
||||
bool my_drawtext(resource image, string text, resource font, int x, int y [, int color])
|
||||
|
||||
will create this function definition for you (note that there are a few
|
||||
question marks to be replaced by you, and you must of course add your own
|
||||
value definitions too):
|
||||
|
||||
/* {{{ proto bool module_name_drawtext(resource image, string text, resource font, int x, int y [, int color])
|
||||
/* {{{ proto bool my_drawtext(resource image, string text, resource font, int x, int y [, int color])
|
||||
*/
|
||||
PHP_FUNCTION(module_name_drawtext)
|
||||
PHP_FUNCTION(my_drawtext)
|
||||
{
|
||||
char *text = NULL;
|
||||
int argc = ZEND_NUM_ARGS();
|
||||
@@ -182,7 +164,7 @@ PHP_FUNCTION(module_name_drawtext)
|
||||
ZEND_FETCH_RESOURCE(???, ???, font, font_id, "???", ???_rsrc_id);
|
||||
}
|
||||
|
||||
php_error(E_WARNING, "module_name_drawtext: not yet implemented");
|
||||
php_error(E_WARNING, "my_drawtext: not yet implemented");
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
+7
-13
@@ -45,16 +45,15 @@ Currently we have the following branches in use::
|
||||
|
||||
master The active development branch.
|
||||
|
||||
PHP-5.6 Is used to release the PHP 5.6.x series. This is a current
|
||||
stable version and is open for bugfixes only.
|
||||
|
||||
PHP-5.5 Is used to release the PHP 5.5.x series. This is a current
|
||||
stable version and is open for bugfixes only.
|
||||
|
||||
PHP-5.4 Is used to release the PHP 5.4.x series. This is a current
|
||||
stable version and is open for bugfixes only.
|
||||
|
||||
PHP-5.3 This branch is closed.
|
||||
PHP-5.3 Is used to release the PHP 5.3.x series. This is currently
|
||||
in extended support and open forsecurity fixes only. Triaged
|
||||
via security@php.net
|
||||
|
||||
PHP-5.2 This branch is closed.
|
||||
|
||||
@@ -62,22 +61,17 @@ Currently we have the following branches in use::
|
||||
|
||||
PHP-4.4 This branch is closed.
|
||||
|
||||
PHP-X.Y.Z These branches are used for the release managers for tagging
|
||||
the releases, hence they are closed to the general public.
|
||||
|
||||
The next few rules are more of a technical nature::
|
||||
|
||||
1. All changes should first go to the lowest branch (i.e. 5.4) and then
|
||||
1. All changes should first go to the lowest branch (i.e. 5.3) and then
|
||||
get merged up to all other branches. If a change is not needed for
|
||||
later branches (i.e. fixes for features which where dropped from later
|
||||
branches) an empty merge should be done.
|
||||
|
||||
2. All news updates intended for public viewing, such as new features,
|
||||
bug fixes, improvements, etc., should go into the NEWS file of *any
|
||||
stable release* version with the given change. In other words,
|
||||
news about a bug fix which went into PHP-5.4, PHP-5.5 and master
|
||||
should be noted in both PHP-5.4/NEWS and PHP-5.5/NEWS but
|
||||
not master, which is not a public released version yet.
|
||||
bug fixes, improvements, etc., should go into the NEWS file of the
|
||||
*first* to be released version with the given change. In other words
|
||||
any NEWS file change only needs to done in one branch.
|
||||
|
||||
3. Do not commit multiple file and dump all messages in one commit. If you
|
||||
modified several unrelated files, commit each group separately and
|
||||
|
||||
+83
-100
@@ -8,30 +8,19 @@ General notes and tips
|
||||
1. Do not release on Fridays, Saturdays or Sundays
|
||||
because the sysadmins can not upgrade stuff then.
|
||||
|
||||
2. Package two days before a release. So if the release is to be on Thursday,
|
||||
package on Tuesday. Think about timezones as well.
|
||||
2. Package the day before a release. So if the release is to be on Thursday,
|
||||
package on Wednesday.
|
||||
|
||||
3. Ensure that the tests on Travis CI are green.
|
||||
See: https://travis-ci.org/php/php-src/builds
|
||||
It is recommended to do so a couple of days before the packaging day, to
|
||||
have enough time to investigate failures, communicate with the authors and
|
||||
commit the fixes.
|
||||
The RM for the branch is also responsible for keeping the CI green on
|
||||
ongoing bases between the releases. Check the CI status for your branch
|
||||
periodically and resolve the failures ASAP. See more in:
|
||||
https://wiki.php.net/rfc/travis_ci
|
||||
3. Ensure that Windows builds will work before packaging
|
||||
|
||||
4. Ensure that Windows builds will work before packaging
|
||||
4. Follow all steps to the letter. When unclear ask previous RM's (Derick/Ilia)
|
||||
before proceeding. Ideally make sure that for the first releases one of the
|
||||
previous RM's is around to answer questions. For the steps related to the
|
||||
php/QA/bug websites try to have someone from the webmaster team (Bjori) on hand.
|
||||
|
||||
5. Follow all steps to the letter. When unclear ask previous RM's (David/Julien/
|
||||
Johannes/Stas/Derick/Ilia) before proceeding. Ideally make sure that for the
|
||||
first releases one of the previous RM's is around to answer questions. For the
|
||||
steps related to the php/QA/bug websites try to have someone from the webmaster
|
||||
team (Bjori) on hand.
|
||||
5. Verify the tags to be extra sure everything was tagged properly.
|
||||
|
||||
6. Verify the tags to be extra sure everything was tagged properly.
|
||||
|
||||
7. Moving extensions from/to PECL requires write acces to the destination.
|
||||
6. Moving extensions from/to PECL requires write acces to the destination.
|
||||
Most developers should have this.
|
||||
|
||||
Moving extensions from php-src to PECL
|
||||
@@ -58,52 +47,40 @@ Rolling a non stable release (alpha/beta/RC)
|
||||
|
||||
1. Check windows snapshot builder logs (http://windows.php.net/downloads/snaps/ the last revision)
|
||||
|
||||
2. Check the tests at https://travis-ci.org/php/php-src/builds
|
||||
|
||||
3. run the "scripts/dev/credits" script in php-src and commit the changes in the
|
||||
2. run the "scripts/dev/credits" script in php-src and commit the changes in the
|
||||
credits files in ext/standard.
|
||||
|
||||
4. Checkout the release branch for this release (e.g., PHP-5.4.2) from the main branch.
|
||||
3. Checkout the release branch for this release (e.g., PHP-5.4.2).
|
||||
|
||||
5. Bump the version numbers in ``main/php_version.h``, ``configure.in`` and possibly ``NEWS``.
|
||||
Do not use abbreviations for alpha and beta. Do not use dashes, you should
|
||||
``#define PHP_VERSION "5.4.22RC1"`` and not ``#define PHP_VERSION "5.4.22-RC1"``
|
||||
4. Bump the version numbers in ``main/php_version.h``, ``configure.in`` and possibly ``NEWS``.
|
||||
Do not use abbreviations for alpha and beta.
|
||||
|
||||
6. Compile and make test, with and without ZTS, using the right Bison version
|
||||
(for example, for 5.5, Bison 2.4.1 is used)
|
||||
5. Commit these changes to the branch with ``git commit -a``.
|
||||
|
||||
7. Check ./sapi/cli/php -v output for version matching.
|
||||
|
||||
8. If all is right, commit the changes to the release branch with ``git commit -a``.
|
||||
|
||||
9. Tag the repository release branch with the version, e.g.:
|
||||
6. Tag the repository with the version, e.g.:
|
||||
``git tag -u YOURKEYID php-5.4.2RC2``
|
||||
|
||||
10. Bump the version numbers in ``main/php_version.h``, ``configure.in`` and ``NEWS``
|
||||
in the *main* branch (PHP-5.4 for example) to prepare for the **next** version.
|
||||
F.e. if the RC is "5.4.1RC1" then the new one should be "5.4.2-dev" - regardless if we get
|
||||
a new RC or not. This is to make sure ``version_compare()`` can correctly work.
|
||||
Commit the changes to the main branch.
|
||||
|
||||
11. Push the changes to the main repo, the tag, the main branch and the release branch :
|
||||
7. Push the changes to the main repo:
|
||||
``git push --tags origin HEAD``
|
||||
``git push origin {main branch}``
|
||||
``git push origin {release branch}``
|
||||
|
||||
12. run: ``PHPROOT=. ./makedist 5.4.2RC2``, this will export the tree, create configure
|
||||
and build three tarballs (gz, bz2 and xz).
|
||||
8. run: ``./makedist 5.4.2RC2``, this will export the tree, create configure
|
||||
and build three tarballs (gz,bz2 and xz). Make sure you use the same GNU Bison
|
||||
version as snaps. Recent bison version are known to break ZTS.
|
||||
|
||||
13. Copy those tarballs (scp, rsync) to downloads.php.net, in your homedir there should be a
|
||||
9. Copy those three tarballs to www.php.net, in your homedir there should be a
|
||||
directory "downloads/". Copy them into there, so that the system can generate
|
||||
MD5 sums. If you do not have this directory, talk to Derick or Dan.
|
||||
MD5 sums. If you do not have this directory, talk to Derick.
|
||||
|
||||
14. Now the RC can be found on http://downloads.php.net/yourname,
|
||||
10. Now the RC can be found on http://downloads.php.net/yourname,
|
||||
f.e. http://downloads.php.net/derick/
|
||||
|
||||
15. Once the release has been tagged, contact the PHP Windows development team
|
||||
11. Once the release has been tagged, contact the PHP Windows development team
|
||||
(internals-win@lists.php.net) so that Windows binaries can be created. Once
|
||||
those are made, they should be placed into the same directory as the source snapshots.
|
||||
|
||||
12. Notify the documentation team if documentations for new features are
|
||||
not yet available but a stable release is imminent.
|
||||
|
||||
Getting the non stable release (alpha/beta/RC) announced
|
||||
--------------------------------------------------------
|
||||
|
||||
@@ -113,10 +90,10 @@ pointing out "the location of the release" and "the possible release date of
|
||||
either the next RC, or the final release".
|
||||
|
||||
2. Send an email (see example here http://news.php.net/php.pear.qa/5201) **To**
|
||||
``php-qa@lists.php.net`` and ``primary-qa-tester@lists.php.net``.
|
||||
``php-qa@lists.php.net`` and ``primary-qa-tests@lists.php.net``.
|
||||
This email is to notify the selected projects about a new release so that they
|
||||
can make sure their projects keep working. Make sure that you have been setup
|
||||
as a moderator for ``primary-qa-tester@lists.php.net`` by having someone (Hannes, Dan,
|
||||
as a moderator for ``primary-qa-tests@lists.php.net`` by having someone (Wez,
|
||||
Derick) run the following commands for you:
|
||||
|
||||
``ssh lists.php.net``
|
||||
@@ -132,9 +109,9 @@ Derick) run the following commands for you:
|
||||
|
||||
Note: Remember to update the MD5 checksum information.
|
||||
|
||||
4. Update ``web/php.git/include/version.inc`` (x=major version number)
|
||||
4. Update ``php.git/include/version.inc`` (x=major version number)
|
||||
|
||||
a. ``$PHP_x_RC`` = "5.4.0RC1" (should be set to "false" before)
|
||||
a. ``$PHP_x_RC`` = "5.4.0RC1"
|
||||
|
||||
b. ``$PHP_x_RC_DATE`` = "06 September 2007"
|
||||
|
||||
@@ -145,62 +122,70 @@ Derick) run the following commands for you:
|
||||
6. For the first RC, write the doc team (phpdoc@lists.php.net) about updating the
|
||||
INSTALL and win32/install.txt files which are generated from the PHP manual sources.
|
||||
|
||||
7. Publish the announce on www.php.net as well (for all releases, alpha, RCs or other)
|
||||
|
||||
Rolling a stable release
|
||||
------------------------
|
||||
|
||||
1. Checkout your release branch, you should have created when releasing previous RC
|
||||
and bump the version numbers in ``main/php_version.h``, ``configure.in`` and possibly ``NEWS``.
|
||||
1. Check windows snapshot builder logs (http://snaps.php.net/win32/snapshot-STABLE.log f.e.)
|
||||
|
||||
2. If a CVE commit needs to be merged to the release, then have it committed to
|
||||
the base branches and merged upwards as usual (f.e commit the CVE fix to 5.3,
|
||||
merge to 5.4, 5.5 etc...). Then you can cherry-pick it in your release branch.
|
||||
Don't forget to update NEWS manually in an extra commit then.
|
||||
2. Bump the version numbers in ``main/php_version.h``, ``configure.in`` and possibly ``NEWS``.
|
||||
|
||||
3. Commit those changes. Ensure the tests at https://travis-ci.org/php/php-src/builds are
|
||||
still passing.
|
||||
3. **Merge** all related sections in NEWS (f.e. merge the 5.4.1RC1 and 5.4.0 sections)
|
||||
|
||||
4. run the "scripts/dev/credits" script in php-src and commit the changes in the
|
||||
4. Commit those changes
|
||||
|
||||
5. run the "scripts/dev/credits" script in php-src and commit the changes in the
|
||||
credits files in ext/standard.
|
||||
|
||||
5. Compile and make test, with and without ZTS, using the right Bison version
|
||||
(for example, for 5.5, Bison 2.4.1 is used)
|
||||
6. tag the repository with the version f.e. "``git tag -s php-5.4.1``"
|
||||
(of course, you need to change that to the version you're rolling an RC for).
|
||||
When making 5.X release, you need to tag the Zend directory separately!!
|
||||
|
||||
6. Check ./sapi/cli/php -v output for version matching.
|
||||
7. Bump up the version numbers in ``main/php_version.h``, ``configure.in`` and
|
||||
possibly ``NEWS`` again, to the **next** version. F.e. if the release candidate
|
||||
was "5.4.1RC1" then the new one should be "5.4.1RC2-dev" - regardless if we get
|
||||
a new RC or not. This is to make sure ``version_compare()`` can correctly work.
|
||||
|
||||
7. tag the repository with the version f.e. "``git tag -u YOURKEYID -s php-5.4.1``"
|
||||
8. Commit those changes
|
||||
|
||||
8. Push the tag f.e. "``git push origin php-5.4.1``"
|
||||
9. Log in onto the snaps box and go into the correct tree (f.e. the PHP-5.4
|
||||
branch if you're rolling 5.5.x releases).
|
||||
|
||||
9. run: ``PHPROOT=. ./makedist php 5.4.1``, this will export the tag, create configure
|
||||
and build three tarballs (gz, bz2 and xz).
|
||||
Check if the pear files are updated (phar).
|
||||
10. You do not have to update the tree, but of course you can with "``git pull
|
||||
origin <branch>``".
|
||||
|
||||
10. Generate the GPG signature files for the archives.
|
||||
``gpg -u YOUREMAIL --armor --detach-sign php-X.Y.Z.tar.xxx``
|
||||
11. run: ``./makedist php 5.4.1``, this will export the tree, create configure
|
||||
and build two tarballs (one gz and one bz2).
|
||||
|
||||
11. Commit and push all the tarballs and signature files to web/php-distributions.git,
|
||||
then update the git submodule reference in web/php.git:
|
||||
``git submodule init;
|
||||
12. Commit those two tarballs to web/php-distributions.git, then update the git
|
||||
submodule reference in web/php.git:
|
||||
git submodule init;
|
||||
git submodule update;
|
||||
cd distributions;
|
||||
git pull origin master;
|
||||
cd ..;
|
||||
git commit distributions;
|
||||
git push;``
|
||||
This is to fetch the last commit id from php-distributions.git and commit this
|
||||
last commit id to web/php.git, then, mirrors will now sync
|
||||
git push;
|
||||
|
||||
12. Once the release has been tagged, contact the PHP Windows development team
|
||||
(internals-win@lists.php.net) so that Windows binaries can be created.
|
||||
13. Once the release has been tagged, contact the PHP Windows development team
|
||||
(internals-win@lists.php.net) so that Windows binaries can be created. Once
|
||||
those are made, they should be committed to SVN too.
|
||||
|
||||
14. Check if the pear files are updated (phar for 5.1+ or run pear/make-pear-bundle.php with 4.4)
|
||||
|
||||
15. When making a final release, also remind the PHP Windows development team
|
||||
(internals-win@lists.php.net) to prepare the installer packages for Win32.
|
||||
|
||||
16. Make sure proper documentation exists for all new features/changes.
|
||||
Coordinate the release with the PHP Documentation team.
|
||||
|
||||
Getting the stable release announced
|
||||
------------------------------------
|
||||
|
||||
1. Update phpweb/include/releases.inc with the old release info
|
||||
(updates the download archives)
|
||||
1. Run the bumpRelease script for phpweb on your local checkout
|
||||
|
||||
a. You can run ``php bin/bumpRelease 5`` if you are making a release for the
|
||||
highest branch, otherwise you have to do this manually, see point 1.b
|
||||
a. ``php bin/bumpRelease 5`` (or ``php bin/bumpRelease 4`` for PHP4)
|
||||
|
||||
b. In case multiple PHP minor versions are in active development you have
|
||||
to manually copy the old information to include/releases.inc
|
||||
@@ -220,14 +205,7 @@ Getting the stable release announced
|
||||
|
||||
f. if the windows builds aren't ready yet prefix the "windows" key with a dot (".windows")
|
||||
|
||||
3. Create the release file (releases/x_y_z.php)
|
||||
Usually we use the same content as for point 6, but included in php template
|
||||
instead of the release xml.
|
||||
|
||||
4. Update php-qa/include/release-qa.php and add the next version as an QARELEASE
|
||||
(prepare for next RC)
|
||||
|
||||
5. Update the ChangeLog file for the given major version
|
||||
3. Update the ChangeLog file for the given major version
|
||||
f.e. ``ChangeLog-5.php`` from the NEWS file
|
||||
|
||||
a. go over the list and put every element on one line
|
||||
@@ -247,10 +225,19 @@ f.e. ``ChangeLog-5.php`` from the NEWS file
|
||||
IV. ``s/Fixed PECL bug #\([0-9]\+\)/<?php peclbugfix(\1); ?>/``
|
||||
|
||||
V. ``s/FR #\([0-9]\+\)/FR <?php bugl(\1); ?>/``
|
||||
|
||||
e. You may want to try php-web/bin/news2html to automate this task
|
||||
|
||||
6. Add a short notice to phpweb stating that there is a new release, and
|
||||
4. ``cp releases/5_4_0.php releases/5_4_1.php``
|
||||
|
||||
5. ``git add releases/5_4_1.php``
|
||||
|
||||
6. Update the ``releases/*.php`` file with relevant data. The release
|
||||
announcement file should list in detail:
|
||||
|
||||
a. security fixes,
|
||||
|
||||
b. changes in behavior (whether due to a bug fix or not)
|
||||
|
||||
7. Add a short notice to phpweb stating that there is a new release, and
|
||||
highlight the major important things (security fixes) and when it is important
|
||||
to upgrade.
|
||||
|
||||
@@ -258,11 +245,7 @@ to upgrade.
|
||||
|
||||
b. Add the content for the news entry
|
||||
|
||||
7. **Check mirrors have been synced before announcing or pushing news**
|
||||
Try, f.e. http://www.php.net/get/php-5.5.1.tar.bz2/from/a/mirror
|
||||
Try several mirrors, mirrors may update slowly (may take an hour)
|
||||
|
||||
8. Commit all the changes to their respective git repos
|
||||
8. Commit all the changes.
|
||||
|
||||
9. Wait an hour or two, then send a mail to php-announce@lists.php.net,
|
||||
php-general@lists.php.net and internals@lists.php.net with a text similar to
|
||||
|
||||
@@ -50,17 +50,6 @@ Please make the mail subject prefix "[PATCH]". If attaching a patch,
|
||||
ensure it has a file extension of ".txt". This is because only MIME
|
||||
attachments of type 'text/*' are accepted.
|
||||
|
||||
The preferred way to propose PHP patch is sending pull request from
|
||||
github.
|
||||
|
||||
https://github.com/php/php-src
|
||||
|
||||
Fork the official PHP repository and send a pull request. A
|
||||
notification will be sent to the pull request mailing list. Sending a
|
||||
note to PHP Internals list (internals@lists.php.net) may help getting
|
||||
more feedback and quicker turnaround. You can also add pull requests
|
||||
to bug reports at http://bugs.php.net/.
|
||||
|
||||
|
||||
PHP Documentation Patches
|
||||
-------------------------
|
||||
|
||||
+1
-1
@@ -2,7 +2,7 @@
|
||||
------------------
|
||||
Failed tests usually indicate a problem with your local system setup
|
||||
and not within PHP itself (at least for official PHP release versions).
|
||||
You may decide to automatically submit a test summary to our QA workflow
|
||||
You may decide to automaticaly submit a test summary to our QA workflow
|
||||
at the end of a test run.
|
||||
Please do *not* submit a failed test as a bug or ask for help on why
|
||||
it failed on your system without providing substantial backup information
|
||||
|
||||
Regular → Executable
File mode changed.
@@ -2,7 +2,6 @@
|
||||
#define TSRM_CONFIG_W32_H
|
||||
|
||||
#include <../main/config.w32.h>
|
||||
#include "Zend/zend_config.w32.h"
|
||||
|
||||
#define HAVE_UTIME 1
|
||||
#define HAVE_ALLOCA 1
|
||||
@@ -12,4 +11,12 @@
|
||||
#include <stdlib.h>
|
||||
#include <crtdbg.h>
|
||||
|
||||
#undef inline
|
||||
#ifdef ZEND_WIN32_FORCE_INLINE
|
||||
# define inline __forceinline
|
||||
#else
|
||||
# define inline
|
||||
#endif
|
||||
|
||||
|
||||
#endif
|
||||
@@ -2,7 +2,7 @@
|
||||
#define TSRM_CONFIG_COMMON_H
|
||||
|
||||
#ifndef __CYGWIN__
|
||||
# ifdef _WIN32
|
||||
# if WINNT|WIN32
|
||||
# define TSRM_WIN32
|
||||
# endif
|
||||
#endif
|
||||
|
||||
+1
-1
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| PHP Version 5 |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1997-2015 The PHP Group |
|
||||
| Copyright (c) 1997-2013 The PHP Group |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 3.01 of the PHP license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
+1
-1
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| PHP Version 5 |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1997-2015 The PHP Group |
|
||||
| Copyright (c) 1997-2013 The PHP Group |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 3.01 of the PHP license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| PHP Version 5 |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1997-2015 The PHP Group |
|
||||
| Copyright (c) 1997-2013 The PHP Group |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 3.01 of the PHP license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| PHP Version 5 |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1997-2015 The PHP Group |
|
||||
| Copyright (c) 1997-2013 The PHP Group |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 3.01 of the PHP license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
+1
-1
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| PHP Version 5 |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1997-2015 The PHP Group |
|
||||
| Copyright (c) 1997-2013 The PHP Group |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 3.01 of the PHP license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
+1
-1
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| PHP Version 5 |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1997-2015 The PHP Group |
|
||||
| Copyright (c) 1997-2013 The PHP Group |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 3.01 of the PHP license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
@@ -7,7 +7,6 @@ PHP 5.5 UPGRADE NOTES
|
||||
2. Changes in SAPI modules
|
||||
3. Deprecated Functionality
|
||||
4. Changed Functions
|
||||
a. unserialize() change
|
||||
5. New Functions
|
||||
6. New Classes and Interfaces
|
||||
7. Removed Extensions
|
||||
@@ -86,10 +85,6 @@ PHP 5.5 UPGRADE NOTES
|
||||
configure this. The service can now use Type=notify in the systemd
|
||||
unit file. (Remi)
|
||||
|
||||
- Support for several XML MIME types in the built-in CLI server. For static
|
||||
files with extensions .xml, .xsl, .xsd the Content-Type header
|
||||
application/xml is now sent automatically.
|
||||
|
||||
========================================
|
||||
3. Deprecated Functionality
|
||||
========================================
|
||||
@@ -194,47 +189,6 @@ PHP 5.5 UPGRADE NOTES
|
||||
- Since 5.5.4, fputcsv() has fifth parameter escape_char, allowing to
|
||||
specify escape char.
|
||||
|
||||
4a. unserialize() change
|
||||
------------------------
|
||||
|
||||
- Starting PHP 5.5.13, the bug fix for bug #67072 introduces a change to
|
||||
unserialize() function, detailed below:
|
||||
|
||||
If the string looking like 'O:..:"ClassName":...' is unserialized, and
|
||||
the class named is an internal class that declares custom unserializer
|
||||
function, or extends such class, unserialize would fail.
|
||||
|
||||
Using O: for user classes not extending internal classes (including
|
||||
those implementing Serializable) is still supported in 5.4, though
|
||||
it is deprecated and may not be supported in 5.6 for classes that do not
|
||||
originally serialize to O:. Same for using O: for internal classes
|
||||
implementing Serializable (like ArrayObject) and classes that extend
|
||||
them.
|
||||
|
||||
The reason for that is that O: format is meant to be used with classes
|
||||
that do not define custom handlers, and was never intended for the use
|
||||
with classes that do. When used with the class that relies on custom
|
||||
unserializer, it can leave the object of such internal class in an
|
||||
inconsistent state which has been observed to result in crashes and may
|
||||
also lead to memory corruption and ultimately even arbitrary code
|
||||
execution. This was never the intended use of unserializer, and mere
|
||||
possibility of doing this constitutes a bug, since the data passed to
|
||||
unserialize() is not a valid serialization of any object. Since there
|
||||
are many applications applying unserialize() to untrusted data, this
|
||||
presents a potential security vulnerability. Thus, keeping such bug in
|
||||
the code base was considered too dangerous.
|
||||
|
||||
We are aware that some applications use O: format as a way to
|
||||
instantiate classes. This was never the intended usage of serializer,
|
||||
and ReflectionClass methods such as newInstance or
|
||||
newInstanceWithoutConstructor can be used for that. We're working on
|
||||
providing more comprehensive solution for such use cases in PHP 5.6 and
|
||||
welcome the ideas in this area.
|
||||
|
||||
We note also that using unserialize() on any data that is not the result
|
||||
of serialize() call continues to be an unsupported scenario and should
|
||||
not be relied on to produce any specific result.
|
||||
|
||||
========================================
|
||||
5. New Functions
|
||||
========================================
|
||||
@@ -345,12 +299,6 @@ PHP 5.5 UPGRADE NOTES
|
||||
- IntlDateFormatter::getTimeZone()
|
||||
- IntlDateFormatter::setTimeZone()
|
||||
|
||||
- LDAP:
|
||||
- ldap_modify_batch() (5.5.10)
|
||||
|
||||
- SOAP:
|
||||
- SoapClient::__getCookies() (5.5.14)
|
||||
|
||||
- Sockets:
|
||||
- socket_sendmsg()
|
||||
- socket_recvmsg()
|
||||
|
||||
@@ -8,7 +8,6 @@ UPGRADE NOTES - PHP X.Y
|
||||
c. Lowercasing and locales
|
||||
d. zend_qsort_r
|
||||
e. get_current_key
|
||||
f. unserialization of manipulated object strings
|
||||
|
||||
2. Build system changes
|
||||
a. Unix build system changes
|
||||
@@ -109,21 +108,6 @@ void (*get_current_key)(zend_object_iterator *iter, zval *key TSRMLS_DC);
|
||||
|
||||
The key should be written into the zval* using the ZVAL_* macros.
|
||||
|
||||
f. unserialization of manipulated object strings
|
||||
|
||||
Strings requiring unserialization of objects are now explicitly checked
|
||||
whether the object they contain implements the Serializable interface.
|
||||
This solves the situation where manipulated strings could be passed for
|
||||
objects using Serializable to disallow serialization. An object
|
||||
implementing Serializable will always start with "C:" in the serialized
|
||||
string, all other objects are represented with starting "O:". Objects
|
||||
implementing Serializable to disable serialization using
|
||||
zend_class_unserialize_deny and zend_class_serialize_deny, when
|
||||
instantiated from the serializer with a manipulated "O:" string at the
|
||||
start, will most likely be defectively initialized. This is now
|
||||
fixed at the appropriate place by checking for the presence of the
|
||||
serialize callback in the class entry.
|
||||
|
||||
========================
|
||||
2. Build system changes
|
||||
========================
|
||||
|
||||
+1
-1
@@ -10,7 +10,7 @@ libZend_la_SOURCES=\
|
||||
zend_ini_parser.y zend_ini_scanner.l \
|
||||
zend_alloc.c zend_compile.c zend_constants.c zend_dynamic_array.c \
|
||||
zend_execute.c zend_execute_API.c zend_highlight.c zend_llist.c \
|
||||
zend_vm_opcodes.c zend_opcode.c zend_operators.c zend_ptr_stack.c zend_stack.c \
|
||||
zend_opcode.c zend_operators.c zend_ptr_stack.c zend_stack.c \
|
||||
zend_variables.c zend.c zend_API.c zend_extensions.c zend_hash.c \
|
||||
zend_list.c zend_indent.c zend_builtin_functions.c zend_sprintf.c \
|
||||
zend_ini.c zend_qsort.c zend_objects.c zend_object_handlers.c \
|
||||
|
||||
@@ -261,10 +261,6 @@ SOURCE=.\zend_ts_hash.c
|
||||
|
||||
SOURCE=.\zend_variables.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_vm_opcodes.c
|
||||
# End Source File
|
||||
# End Group
|
||||
# Begin Group "Header Files"
|
||||
|
||||
|
||||
@@ -291,10 +291,6 @@ SOURCE=.\zend_ts_hash.c
|
||||
|
||||
SOURCE=.\zend_variables.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_vm_opcodes.c
|
||||
# End Source File
|
||||
# End Group
|
||||
# Begin Group "Header Files"
|
||||
|
||||
|
||||
@@ -24,6 +24,6 @@ Warning: feof(): wrapper::stream_eof is not implemented! Assuming EOF in %s on l
|
||||
Fatal error: Uncaught exception 'Exception' in %s:%d
|
||||
Stack trace:
|
||||
#0 [internal function]: wrapper->stream_eof()
|
||||
#1 %s(%d): feof(Resource id #%d)
|
||||
#1 %s(%d): feof(Resource id #6)
|
||||
#2 {main}
|
||||
thrown in %s on line %d
|
||||
@@ -1,23 +0,0 @@
|
||||
--TEST--
|
||||
Bug #65419 (Inside trait, self::class != __CLASS__)
|
||||
--FILE--
|
||||
<?php
|
||||
trait abc
|
||||
{
|
||||
static function def()
|
||||
{
|
||||
echo self::class, "\n";
|
||||
echo __CLASS__, "\n";
|
||||
}
|
||||
}
|
||||
|
||||
class ghi
|
||||
{
|
||||
use abc;
|
||||
}
|
||||
|
||||
ghi::def();
|
||||
?>
|
||||
--EXPECTF--
|
||||
ghi
|
||||
ghi
|
||||
@@ -1,62 +0,0 @@
|
||||
--TEST--
|
||||
Fixed Bug #65784 (Segfault with finally)
|
||||
--XFAIL--
|
||||
This bug is not fixed in 5.5 due to ABI BC
|
||||
--FILE--
|
||||
<?php
|
||||
function foo1() {
|
||||
try {
|
||||
throw new Exception("not catch");
|
||||
return true;
|
||||
} finally {
|
||||
try {
|
||||
throw new Exception("catched");
|
||||
} catch (Exception $e) {
|
||||
}
|
||||
}
|
||||
}
|
||||
try {
|
||||
$foo = foo1();
|
||||
var_dump($foo);
|
||||
} catch (Exception $e) {
|
||||
do {
|
||||
var_dump($e->getMessage());
|
||||
} while ($e = $e->getPrevious());
|
||||
}
|
||||
|
||||
function foo2() {
|
||||
try {
|
||||
try {
|
||||
throw new Exception("catched");
|
||||
return true;
|
||||
} finally {
|
||||
try {
|
||||
throw new Exception("catched");
|
||||
} catch (Exception $e) {
|
||||
}
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
}
|
||||
}
|
||||
|
||||
$foo = foo2();
|
||||
var_dump($foo);
|
||||
|
||||
function foo3() {
|
||||
try {
|
||||
throw new Exception("not catched");
|
||||
return true;
|
||||
} finally {
|
||||
try {
|
||||
throw new NotExists();
|
||||
} catch (Exception $e) {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
$bar = foo3();
|
||||
--EXPECTF--
|
||||
string(9) "not catch"
|
||||
NULL
|
||||
|
||||
Fatal error: Class 'NotExists' not found in %sbug65784.php on line %d
|
||||
@@ -1,10 +0,0 @@
|
||||
--TEST--
|
||||
Bug #65969 (Chain assignment with T_LIST failure)
|
||||
--FILE--
|
||||
<?php
|
||||
$obj = new stdClass;
|
||||
list($a,$b) = $obj->prop = [1,2];
|
||||
var_dump($a,$b);
|
||||
--EXPECT--
|
||||
int(1)
|
||||
int(2)
|
||||
@@ -1,21 +0,0 @@
|
||||
--TEST--
|
||||
Bug #66218 zend_register_functions breaks reflection
|
||||
--SKIPIF--
|
||||
<?php
|
||||
if (PHP_SAPI != "cli") die("skip CLI only test");
|
||||
if (!function_exists("dl")) die("skip need dl");
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
$tab = get_extension_funcs("standard");
|
||||
$fcts = array("dl");
|
||||
foreach ($fcts as $fct) {
|
||||
if (in_array($fct, $tab)) {
|
||||
echo "$fct Ok\n";
|
||||
}
|
||||
}
|
||||
?>
|
||||
Done
|
||||
--EXPECTF--
|
||||
dl Ok
|
||||
Done
|
||||
@@ -1,26 +0,0 @@
|
||||
--TEST--
|
||||
Bug #66286: Incorrect object comparison with inheritance
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
abstract class first {
|
||||
protected $someArray = array();
|
||||
}
|
||||
|
||||
class second extends first {
|
||||
protected $someArray = array();
|
||||
protected $someValue = null;
|
||||
|
||||
public function __construct($someValue) {
|
||||
$this->someValue = $someValue;
|
||||
}
|
||||
}
|
||||
|
||||
$objFirst = new second('123');
|
||||
$objSecond = new second('321');
|
||||
|
||||
var_dump ($objFirst == $objSecond);
|
||||
|
||||
?>
|
||||
--EXPECT--
|
||||
bool(false)
|
||||
@@ -1,73 +0,0 @@
|
||||
--TEST--
|
||||
Bug #66608 (Incorrect behavior with nested "finally" blocks)
|
||||
--FILE--
|
||||
<?php
|
||||
function bar() {
|
||||
try {
|
||||
echo "1\n";
|
||||
try {
|
||||
} finally {
|
||||
try {
|
||||
} finally {
|
||||
}
|
||||
echo "2\n";
|
||||
}
|
||||
} finally {
|
||||
try {
|
||||
throw new Exception ("");
|
||||
} catch (Exception $ab) {
|
||||
echo "3\n";
|
||||
} finally {
|
||||
try {
|
||||
} finally {
|
||||
echo "4\n";
|
||||
try {
|
||||
} finally {
|
||||
}
|
||||
echo "5\n";
|
||||
}
|
||||
}
|
||||
echo "6\n";
|
||||
try {
|
||||
} finally {
|
||||
while (1) {
|
||||
try {
|
||||
echo "7\n";
|
||||
break;
|
||||
} finally {
|
||||
echo "8\n";
|
||||
}
|
||||
echo "bad";
|
||||
}
|
||||
echo "9\n";
|
||||
while (1) {
|
||||
try {
|
||||
throw new Exception("");
|
||||
} catch(Exception $e) {
|
||||
echo "10\n";
|
||||
break;
|
||||
} finally {
|
||||
echo "11\n";
|
||||
}
|
||||
echo "bak\n";
|
||||
}
|
||||
}
|
||||
echo "12\n";
|
||||
}
|
||||
echo "13\n";
|
||||
}
|
||||
bar();
|
||||
--EXPECT--
|
||||
1
|
||||
2
|
||||
3
|
||||
4
|
||||
5
|
||||
6
|
||||
7
|
||||
8
|
||||
9
|
||||
10
|
||||
11
|
||||
12
|
||||
13
|
||||
@@ -1,20 +0,0 @@
|
||||
--TEST--
|
||||
Bug #67111: Memory leak when using "continue 2" inside two foreach loops
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
$array1 = [1, 2, 3];
|
||||
$array2 = [1, 2, 3];
|
||||
|
||||
foreach ($array1 as $x) {
|
||||
foreach ($array2 as $y) {
|
||||
echo "$x.$y\n";
|
||||
continue 2;
|
||||
}
|
||||
}
|
||||
|
||||
?>
|
||||
--EXPECT--
|
||||
1.1
|
||||
2.1
|
||||
3.1
|
||||
@@ -1,10 +0,0 @@
|
||||
<?php
|
||||
|
||||
class a {
|
||||
public function test($arg = c::TESTCONSTANT) {
|
||||
echo __METHOD__ . "($arg)\n";
|
||||
}
|
||||
|
||||
static public function staticTest() {
|
||||
}
|
||||
}
|
||||
@@ -1,8 +0,0 @@
|
||||
<?php
|
||||
|
||||
class b extends a {
|
||||
public function test() {
|
||||
echo __METHOD__ . "()\n";
|
||||
parent::test();
|
||||
}
|
||||
}
|
||||
@@ -1,26 +0,0 @@
|
||||
--TEST--
|
||||
bug67436: Autoloader isn't called if user defined error handler is present
|
||||
|
||||
--INI--
|
||||
error_reporting=
|
||||
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
spl_autoload_register(function($classname) {
|
||||
if (in_array($classname, array('a','b','c'))) {
|
||||
require_once ($classname . '.php');
|
||||
}
|
||||
});
|
||||
|
||||
set_error_handler(function ($errno, $errstr, $errfile, $errline) {
|
||||
}, error_reporting());
|
||||
|
||||
a::staticTest();
|
||||
|
||||
$b = new b();
|
||||
$b->test();
|
||||
|
||||
--EXPECT--
|
||||
b::test()
|
||||
a::test(c::TESTCONSTANT)
|
||||
@@ -1,24 +0,0 @@
|
||||
--TEST--
|
||||
bug67436: E_STRICT instead of custom error handler
|
||||
|
||||
--INI--
|
||||
error_reporting=-1
|
||||
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
spl_autoload_register(function($classname) {
|
||||
if (in_array($classname, array('a','b','c'))) {
|
||||
require_once ($classname . '.php');
|
||||
}
|
||||
});
|
||||
|
||||
a::staticTest();
|
||||
|
||||
$b = new b();
|
||||
$b->test();
|
||||
|
||||
--EXPECTF--
|
||||
Strict Standards: Declaration of b::test() should be compatible with a::test($arg = c::TESTCONSTANT) in %s/bug67436/b.php on line %d
|
||||
b::test()
|
||||
a::test(c::TESTCONSTANT)
|
||||
@@ -1,5 +0,0 @@
|
||||
<?php
|
||||
|
||||
class c {
|
||||
const TESTCONSTANT = "c::TESTCONSTANT";
|
||||
}
|
||||
@@ -1,44 +0,0 @@
|
||||
--TEST--
|
||||
Bug #67633: A foreach on an array returned from a function not doing copy-on-write
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
function id($x) {
|
||||
return $x;
|
||||
}
|
||||
|
||||
function &ref_id(&$x) {
|
||||
return $x;
|
||||
}
|
||||
|
||||
$c = 'c';
|
||||
$array = ['a', 'b', $c];
|
||||
|
||||
foreach(id($array) as &$v) {
|
||||
$v .= 'q';
|
||||
}
|
||||
var_dump($array);
|
||||
|
||||
foreach(ref_id($array) as &$v) {
|
||||
$v .= 'q';
|
||||
}
|
||||
var_dump($array);
|
||||
|
||||
?>
|
||||
--EXPECT--
|
||||
array(3) {
|
||||
[0]=>
|
||||
string(1) "a"
|
||||
[1]=>
|
||||
string(1) "b"
|
||||
[2]=>
|
||||
string(1) "c"
|
||||
}
|
||||
array(3) {
|
||||
[0]=>
|
||||
string(2) "aq"
|
||||
[1]=>
|
||||
string(2) "bq"
|
||||
[2]=>
|
||||
&string(2) "cq"
|
||||
}
|
||||
@@ -1,16 +0,0 @@
|
||||
--TEST--
|
||||
Bug #67985 - Last used array index not copied to new array at assignment
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
$a = ['zero', 'one', 'two'];
|
||||
unset($a[2]);
|
||||
$b = $a;
|
||||
$a[] = 'three';
|
||||
$b[] = 'three';
|
||||
|
||||
var_dump($a === $b);
|
||||
|
||||
?>
|
||||
--EXPECT--
|
||||
bool(true)
|
||||
@@ -1,21 +0,0 @@
|
||||
--TEST--
|
||||
Bug #68118: $a->foo .= 'test'; can leave $a->foo undefined
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
set_error_handler(function() {
|
||||
$obj = new stdClass;
|
||||
$obj->test = 'meow';
|
||||
return true;
|
||||
});
|
||||
|
||||
$a = new stdClass;
|
||||
$a->undefined .= 'test';
|
||||
var_dump($a);
|
||||
|
||||
?>
|
||||
--EXPECT--
|
||||
object(stdClass)#2 (1) {
|
||||
["undefined"]=>
|
||||
string(4) "test"
|
||||
}
|
||||
@@ -1,18 +0,0 @@
|
||||
--TEST--
|
||||
Bug #68370 "unset($this)" can make the program crash
|
||||
--FILE--
|
||||
<?php
|
||||
class C {
|
||||
public function test() {
|
||||
unset($this);
|
||||
return get_defined_vars();
|
||||
}
|
||||
}
|
||||
$c = new C();
|
||||
$x = $c->test();
|
||||
print_r($x);
|
||||
unset($c, $x);
|
||||
--EXPECTF--
|
||||
Array
|
||||
(
|
||||
)
|
||||
@@ -1,22 +0,0 @@
|
||||
--TEST--
|
||||
Closure 049: static::class in static closure in non-static method.
|
||||
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
class A {
|
||||
function foo() {
|
||||
$f = static function() {
|
||||
return static::class;
|
||||
};
|
||||
return $f();
|
||||
}
|
||||
}
|
||||
|
||||
class B extends A {}
|
||||
|
||||
$b = new B;
|
||||
|
||||
var_dump($b->foo());
|
||||
--EXPECT--
|
||||
string(1) "B"
|
||||
@@ -1,22 +0,0 @@
|
||||
--TEST--
|
||||
Closure 050: static::class in non-static closure in non-static method.
|
||||
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
class A {
|
||||
function foo() {
|
||||
$f = function() {
|
||||
return static::class;
|
||||
};
|
||||
return $f();
|
||||
}
|
||||
}
|
||||
|
||||
class B extends A {}
|
||||
|
||||
$b = new B;
|
||||
var_dump($b->foo());
|
||||
|
||||
--EXPECT--
|
||||
string(1) "B"
|
||||
@@ -1,21 +0,0 @@
|
||||
--TEST--
|
||||
Closure 051: static::class in static closure in static method.
|
||||
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
class A {
|
||||
static function foo() {
|
||||
$f = static function() {
|
||||
return static::class;
|
||||
};
|
||||
return $f();
|
||||
}
|
||||
}
|
||||
|
||||
class B extends A {}
|
||||
|
||||
var_dump(B::foo());
|
||||
|
||||
--EXPECT--
|
||||
string(1) "B"
|
||||
@@ -1,21 +0,0 @@
|
||||
--TEST--
|
||||
Closure 052: static::class in non-static closure in static method.
|
||||
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
class A {
|
||||
static function foo() {
|
||||
$f = function() {
|
||||
return static::class;
|
||||
};
|
||||
return $f();
|
||||
}
|
||||
}
|
||||
|
||||
class B extends A {}
|
||||
|
||||
var_dump(B::foo());
|
||||
|
||||
--EXPECT--
|
||||
string(1) "B"
|
||||
@@ -1,22 +0,0 @@
|
||||
--TEST--
|
||||
Closure 053: self::class in static closure in non-static method.
|
||||
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
class A {
|
||||
function foo() {
|
||||
$f = static function() {
|
||||
return self::class;
|
||||
};
|
||||
return $f();
|
||||
}
|
||||
}
|
||||
|
||||
class B extends A {}
|
||||
|
||||
$b = new B;
|
||||
var_dump($b->foo());
|
||||
|
||||
--EXPECT--
|
||||
string(1) "A"
|
||||
@@ -1,22 +0,0 @@
|
||||
--TEST--
|
||||
Closure 054: self::class in non-static closure in non-static method.
|
||||
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
class A {
|
||||
function foo() {
|
||||
$f = function() {
|
||||
return self::class;
|
||||
};
|
||||
return $f();
|
||||
}
|
||||
}
|
||||
|
||||
class B extends A {}
|
||||
|
||||
$b = new B;
|
||||
var_dump($b->foo());
|
||||
|
||||
--EXPECT--
|
||||
string(1) "A"
|
||||
@@ -1,21 +0,0 @@
|
||||
--TEST--
|
||||
Closure 055: self::class in static closure in static method.
|
||||
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
class A {
|
||||
static function foo() {
|
||||
$f = static function() {
|
||||
return self::class;
|
||||
};
|
||||
return $f();
|
||||
}
|
||||
}
|
||||
|
||||
class B extends A {}
|
||||
|
||||
var_dump(B::foo());
|
||||
|
||||
--EXPECT--
|
||||
string(1) "A"
|
||||
@@ -1,21 +0,0 @@
|
||||
--TEST--
|
||||
Closure 056: self::class in non-static closure in static method.
|
||||
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
class A {
|
||||
static function foo() {
|
||||
$f = function() {
|
||||
return self::class;
|
||||
};
|
||||
return $f();
|
||||
}
|
||||
}
|
||||
|
||||
class B extends A {}
|
||||
|
||||
var_dump(B::foo());
|
||||
|
||||
--EXPECT--
|
||||
string(1) "A"
|
||||
@@ -1,37 +0,0 @@
|
||||
--TEST--
|
||||
Bug 66622: Closures do not correctly capture the late bound class (static::) in some cases
|
||||
|
||||
--FILE--
|
||||
<?php
|
||||
class A {
|
||||
static function name() { return 'A'; }
|
||||
function foo() {
|
||||
$fn = function() { return static::name(); };
|
||||
echo static::name() . ' vs ' . $fn() . "\n";
|
||||
}
|
||||
function bar() {
|
||||
$fn = static function() { return static::name(); };
|
||||
echo static::name() . ' vs ' . $fn() . "\n";
|
||||
}
|
||||
static function baz() {
|
||||
$fn = function() { return static::name(); };
|
||||
echo static::name() . ' vs ' . $fn() . "\n";
|
||||
}
|
||||
}
|
||||
class B extends A {
|
||||
static function name() { return 'B'; }
|
||||
}
|
||||
|
||||
function test() {
|
||||
(new B)->foo();
|
||||
(new B)->bar();
|
||||
(new B)->baz();
|
||||
B::baz();
|
||||
}
|
||||
test();
|
||||
|
||||
--EXPECT--
|
||||
B vs B
|
||||
B vs B
|
||||
B vs B
|
||||
B vs B
|
||||
@@ -1,17 +0,0 @@
|
||||
--TEST--
|
||||
Bug #66041: list() fails to unpack yielded ArrayAccess object
|
||||
--FILE--
|
||||
<?php
|
||||
function dumpElement() {
|
||||
list($value) = yield;
|
||||
var_dump($value);
|
||||
};
|
||||
|
||||
$fixedArray = new SplFixedArray(1);
|
||||
$fixedArray[0] = 'the element';
|
||||
|
||||
$generator = dumpElement();
|
||||
$generator->send($fixedArray);
|
||||
?>
|
||||
--EXPECT--
|
||||
string(11) "the element"
|
||||
@@ -1,19 +0,0 @@
|
||||
--TEST--
|
||||
Bug #67467: eval with parse error causes segmentation fault in generator
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
function gen() {
|
||||
$a = 1;
|
||||
yield $a;
|
||||
}
|
||||
|
||||
@eval('abc');
|
||||
|
||||
$values = gen();
|
||||
$values->next();
|
||||
|
||||
?>
|
||||
===DONE===
|
||||
--EXPECT--
|
||||
===DONE===
|
||||
@@ -32,11 +32,12 @@ Stack trace:
|
||||
#0 %s(%d): serialize(Object(Generator))
|
||||
#1 {main}
|
||||
|
||||
exception 'Exception' with message 'Unserialization of 'Generator' is not allowed' in %s:%d
|
||||
Stack trace:
|
||||
#0 [internal function]: Generator->__wakeup()
|
||||
#1 %s(%d): unserialize('O:9:"Generator"...')
|
||||
#2 {main}
|
||||
|
||||
Warning: Erroneous data format for unserializing 'Generator' in %sserialize_unserialize_error.php on line %d
|
||||
|
||||
Notice: unserialize(): Error at offset 19 of 20 bytes in %sserialize_unserialize_error.php on line %s
|
||||
bool(false)
|
||||
exception 'Exception' with message 'Unserialization of 'Generator' is not allowed' in %s:%d
|
||||
Stack trace:
|
||||
#0 %s(%d): unserialize('C:9:"Generator"...')
|
||||
|
||||
@@ -4,7 +4,6 @@ Generator::throw() where the exception is caught in the generator
|
||||
<?php
|
||||
|
||||
function gen() {
|
||||
echo "before yield\n";
|
||||
try {
|
||||
yield;
|
||||
} catch (RuntimeException $e) {
|
||||
@@ -19,7 +18,6 @@ var_dump($gen->throw(new RuntimeException('Test')));
|
||||
|
||||
?>
|
||||
--EXPECTF--
|
||||
before yield
|
||||
exception 'RuntimeException' with message 'Test' in %s:%d
|
||||
Stack trace:
|
||||
#0 {main}
|
||||
|
||||
@@ -4,7 +4,6 @@ Generator::throw() where the generator throws a different exception
|
||||
<?php
|
||||
|
||||
function gen() {
|
||||
echo "before yield\n";
|
||||
try {
|
||||
yield;
|
||||
} catch (RuntimeException $e) {
|
||||
@@ -19,7 +18,6 @@ var_dump($gen->throw(new RuntimeException('throw')));
|
||||
|
||||
?>
|
||||
--EXPECTF--
|
||||
before yield
|
||||
Caught: exception 'RuntimeException' with message 'throw' in %s:%d
|
||||
Stack trace:
|
||||
#0 {main}
|
||||
|
||||
@@ -1,31 +0,0 @@
|
||||
--TEST--
|
||||
Bug #65576 (Constructor from trait conflicts with inherited constructor)
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
trait T
|
||||
{
|
||||
public function __construct()
|
||||
{
|
||||
echo "Trait contructor\n";
|
||||
}
|
||||
}
|
||||
|
||||
class A
|
||||
{
|
||||
public function __construct()
|
||||
{
|
||||
echo "Parent constructor\n";
|
||||
}
|
||||
}
|
||||
|
||||
class B extends A
|
||||
{
|
||||
use T;
|
||||
}
|
||||
|
||||
new B();
|
||||
|
||||
--EXPECT--
|
||||
Trait contructor
|
||||
|
||||
@@ -1,33 +0,0 @@
|
||||
--TEST--
|
||||
Bug #65576 (Constructor from trait conflicts with inherited constructor)
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
trait T
|
||||
{
|
||||
public function __construct()
|
||||
{
|
||||
parent::__construct();
|
||||
echo "Trait contructor\n";
|
||||
}
|
||||
}
|
||||
|
||||
class A
|
||||
{
|
||||
public function __construct()
|
||||
{
|
||||
echo "Parent constructor\n";
|
||||
}
|
||||
}
|
||||
|
||||
class B extends A
|
||||
{
|
||||
use T;
|
||||
}
|
||||
|
||||
new B();
|
||||
|
||||
--EXPECT--
|
||||
Parent constructor
|
||||
Trait contructor
|
||||
|
||||
@@ -1,15 +0,0 @@
|
||||
--TEST--
|
||||
Try finally (segfault with empty break)
|
||||
--FILE--
|
||||
<?php
|
||||
function foo () {
|
||||
try {
|
||||
break;
|
||||
} finally {
|
||||
}
|
||||
}
|
||||
|
||||
foo();
|
||||
?>
|
||||
--EXPECTF--
|
||||
Fatal error: Cannot break/continue 1 level in %stry_finally_011.php on line %d
|
||||
+9
-16
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2015 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
@@ -43,6 +43,10 @@
|
||||
# define GLOBAL_CONSTANTS_TABLE EG(zend_constants)
|
||||
#endif
|
||||
|
||||
#if defined(ZEND_WIN32) && ZEND_DEBUG
|
||||
BOOL WINAPI IsDebuggerPresent(VOID);
|
||||
#endif
|
||||
|
||||
/* true multithread-shared globals */
|
||||
ZEND_API zend_class_entry *zend_standard_class_def = NULL;
|
||||
ZEND_API int (*zend_printf)(const char *format, ...);
|
||||
@@ -127,7 +131,7 @@ ZEND_API zval zval_used_for_init; /* True global variable */
|
||||
/* version information */
|
||||
static char *zend_version_info;
|
||||
static uint zend_version_info_length;
|
||||
#define ZEND_CORE_VERSION_INFO "Zend Engine v" ZEND_VERSION ", Copyright (c) 1998-2015 Zend Technologies\n"
|
||||
#define ZEND_CORE_VERSION_INFO "Zend Engine v" ZEND_VERSION ", Copyright (c) 1998-2013 Zend Technologies\n"
|
||||
#define PRINT_ZVAL_INDENT 4
|
||||
|
||||
static void print_hash(zend_write_func_t write_func, HashTable *ht, int indent, zend_bool is_object TSRMLS_DC) /* {{{ */
|
||||
@@ -809,22 +813,11 @@ void zend_shutdown(TSRMLS_D) /* {{{ */
|
||||
{
|
||||
#ifdef ZEND_SIGNALS
|
||||
zend_signal_shutdown(TSRMLS_C);
|
||||
#endif
|
||||
#ifdef ZEND_WIN32
|
||||
zend_shutdown_timeout_thread();
|
||||
#endif
|
||||
zend_destroy_rsrc_list(&EG(persistent_list) TSRMLS_CC);
|
||||
|
||||
if (EG(active))
|
||||
{
|
||||
/*
|
||||
* The order of destruction is important here.
|
||||
* See bugs #65463 and 66036.
|
||||
*/
|
||||
zend_hash_reverse_apply(GLOBAL_FUNCTION_TABLE, (apply_func_t) zend_cleanup_function_data_full TSRMLS_CC);
|
||||
zend_hash_reverse_apply(GLOBAL_CLASS_TABLE, (apply_func_t) zend_cleanup_user_class_data TSRMLS_CC);
|
||||
zend_cleanup_internal_classes(TSRMLS_C);
|
||||
zend_hash_reverse_apply(GLOBAL_FUNCTION_TABLE, (apply_func_t) clean_non_persistent_function_full TSRMLS_CC);
|
||||
zend_hash_reverse_apply(GLOBAL_CLASS_TABLE, (apply_func_t) clean_non_persistent_class_full TSRMLS_CC);
|
||||
}
|
||||
|
||||
zend_destroy_modules();
|
||||
|
||||
zend_hash_destroy(GLOBAL_FUNCTION_TABLE);
|
||||
|
||||
+1
-1
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2015 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
+1
-1
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2015 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
+1
-1
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2015 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
+2
-2
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2015 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
@@ -201,7 +201,7 @@ static int zend_mm_dev_zero_fd = -1;
|
||||
|
||||
static zend_mm_storage* zend_mm_mem_mmap_zero_init(void *params)
|
||||
{
|
||||
if (zend_mm_dev_zero_fd == -1) {
|
||||
if (zend_mm_dev_zero_fd != -1) {
|
||||
zend_mm_dev_zero_fd = open("/dev/zero", O_RDWR, S_IRUSR | S_IWUSR);
|
||||
}
|
||||
if (zend_mm_dev_zero_fd >= 0) {
|
||||
|
||||
+1
-1
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2015 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
+1
-1
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2015 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2015 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
@@ -245,16 +245,16 @@ static const zend_function_entry builtin_functions[] = { /* {{{ */
|
||||
ZEND_FE(func_num_args, arginfo_zend__void)
|
||||
ZEND_FE(func_get_arg, arginfo_func_get_arg)
|
||||
ZEND_FE(func_get_args, arginfo_zend__void)
|
||||
ZEND_FE(strlen, arginfo_strlen)
|
||||
ZEND_FE(strcmp, arginfo_strcmp)
|
||||
ZEND_FE(strncmp, arginfo_strncmp)
|
||||
ZEND_FE(strcasecmp, arginfo_strcmp)
|
||||
ZEND_FE(strlen, arginfo_strlen)
|
||||
ZEND_FE(strcmp, arginfo_strcmp)
|
||||
ZEND_FE(strncmp, arginfo_strncmp)
|
||||
ZEND_FE(strcasecmp, arginfo_strcmp)
|
||||
ZEND_FE(strncasecmp, arginfo_strncmp)
|
||||
ZEND_FE(each, arginfo_each)
|
||||
ZEND_FE(each, arginfo_each)
|
||||
ZEND_FE(error_reporting, arginfo_error_reporting)
|
||||
ZEND_FE(define, arginfo_define)
|
||||
ZEND_FE(defined, arginfo_defined)
|
||||
ZEND_FE(get_class, arginfo_get_class)
|
||||
ZEND_FE(define, arginfo_define)
|
||||
ZEND_FE(defined, arginfo_defined)
|
||||
ZEND_FE(get_class, arginfo_get_class)
|
||||
ZEND_FE(get_called_class, arginfo_zend__void)
|
||||
ZEND_FE(get_parent_class, arginfo_get_class)
|
||||
ZEND_FE(method_exists, arginfo_method_exists)
|
||||
@@ -274,13 +274,13 @@ static const zend_function_entry builtin_functions[] = { /* {{{ */
|
||||
ZEND_FE(get_included_files, arginfo_zend__void)
|
||||
ZEND_FALIAS(get_required_files, get_included_files, arginfo_zend__void)
|
||||
ZEND_FE(is_subclass_of, arginfo_is_subclass_of)
|
||||
ZEND_FE(is_a, arginfo_is_subclass_of)
|
||||
ZEND_FE(is_a, arginfo_is_subclass_of)
|
||||
ZEND_FE(get_class_vars, arginfo_get_class_vars)
|
||||
ZEND_FE(get_object_vars, arginfo_get_object_vars)
|
||||
ZEND_FE(get_class_methods, arginfo_get_class_methods)
|
||||
ZEND_FE(trigger_error, arginfo_trigger_error)
|
||||
ZEND_FALIAS(user_error, trigger_error, arginfo_trigger_error)
|
||||
ZEND_FE(set_error_handler, arginfo_set_error_handler)
|
||||
ZEND_FE(set_error_handler, arginfo_set_error_handler)
|
||||
ZEND_FE(restore_error_handler, arginfo_zend__void)
|
||||
ZEND_FE(set_exception_handler, arginfo_set_exception_handler)
|
||||
ZEND_FE(restore_exception_handler, arginfo_zend__void)
|
||||
@@ -288,14 +288,14 @@ static const zend_function_entry builtin_functions[] = { /* {{{ */
|
||||
ZEND_FE(get_declared_traits, arginfo_zend__void)
|
||||
ZEND_FE(get_declared_interfaces, arginfo_zend__void)
|
||||
ZEND_FE(get_defined_functions, arginfo_zend__void)
|
||||
ZEND_FE(get_defined_vars, arginfo_zend__void)
|
||||
ZEND_FE(create_function, arginfo_create_function)
|
||||
ZEND_FE(get_resource_type, arginfo_get_resource_type)
|
||||
ZEND_FE(get_defined_vars, arginfo_zend__void)
|
||||
ZEND_FE(create_function, arginfo_create_function)
|
||||
ZEND_FE(get_resource_type, arginfo_get_resource_type)
|
||||
ZEND_FE(get_loaded_extensions, arginfo_get_loaded_extensions)
|
||||
ZEND_FE(extension_loaded, arginfo_extension_loaded)
|
||||
ZEND_FE(extension_loaded, arginfo_extension_loaded)
|
||||
ZEND_FE(get_extension_funcs, arginfo_extension_loaded)
|
||||
ZEND_FE(get_defined_constants, arginfo_get_defined_constants)
|
||||
ZEND_FE(debug_backtrace, arginfo_debug_backtrace)
|
||||
ZEND_FE(debug_backtrace, arginfo_debug_backtrace)
|
||||
ZEND_FE(debug_print_backtrace, arginfo_debug_print_backtrace)
|
||||
#if ZEND_DEBUG
|
||||
ZEND_FE(zend_test_func, NULL)
|
||||
@@ -305,7 +305,7 @@ static const zend_function_entry builtin_functions[] = { /* {{{ */
|
||||
#endif
|
||||
ZEND_FE(gc_collect_cycles, arginfo_zend__void)
|
||||
ZEND_FE(gc_enabled, arginfo_zend__void)
|
||||
ZEND_FE(gc_enable, arginfo_zend__void)
|
||||
ZEND_FE(gc_enable, arginfo_zend__void)
|
||||
ZEND_FE(gc_disable, arginfo_zend__void)
|
||||
ZEND_FE_END
|
||||
};
|
||||
@@ -461,12 +461,17 @@ ZEND_FUNCTION(func_get_args)
|
||||
|
||||
array_init_size(return_value, arg_count);
|
||||
for (i=0; i<arg_count; i++) {
|
||||
zval *element;
|
||||
zval *element, *arg;
|
||||
|
||||
ALLOC_ZVAL(element);
|
||||
*element = **((zval **) (p-(arg_count-i)));
|
||||
zval_copy_ctor(element);
|
||||
INIT_PZVAL(element);
|
||||
arg = *((zval **) (p-(arg_count-i)));
|
||||
if (!Z_ISREF_P(arg)) {
|
||||
element = arg;
|
||||
Z_ADDREF_P(element);
|
||||
} else {
|
||||
ALLOC_ZVAL(element);
|
||||
INIT_PZVAL_COPY(element, arg);
|
||||
zval_copy_ctor(element);
|
||||
}
|
||||
zend_hash_next_index_insert(return_value->value.ht, &element, sizeof(zval *), NULL);
|
||||
}
|
||||
}
|
||||
@@ -2437,49 +2442,36 @@ ZEND_FUNCTION(extension_loaded)
|
||||
Returns an array with the names of functions belonging to the named extension */
|
||||
ZEND_FUNCTION(get_extension_funcs)
|
||||
{
|
||||
char *extension_name, *lcname;
|
||||
int extension_name_len, array;
|
||||
char *extension_name;
|
||||
int extension_name_len;
|
||||
zend_module_entry *module;
|
||||
HashPosition iterator;
|
||||
zend_function *zif;
|
||||
const zend_function_entry *func;
|
||||
|
||||
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &extension_name, &extension_name_len) == FAILURE) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (strncasecmp(extension_name, "zend", sizeof("zend"))) {
|
||||
lcname = zend_str_tolower_dup(extension_name, extension_name_len);
|
||||
} else {
|
||||
lcname = estrdup("core");
|
||||
}
|
||||
if (zend_hash_find(&module_registry, lcname,
|
||||
extension_name_len+1, (void**)&module) == FAILURE) {
|
||||
efree(lcname);
|
||||
RETURN_FALSE;
|
||||
}
|
||||
|
||||
zend_hash_internal_pointer_reset_ex(CG(function_table), &iterator);
|
||||
if (module->functions) {
|
||||
/* avoid BC break, if functions list is empty, will return an empty array */
|
||||
array_init(return_value);
|
||||
array = 1;
|
||||
} else {
|
||||
array = 0;
|
||||
}
|
||||
while (zend_hash_get_current_data_ex(CG(function_table), (void **) &zif, &iterator) == SUCCESS) {
|
||||
if (zif->common.type==ZEND_INTERNAL_FUNCTION
|
||||
&& zif->internal_function.module == module) {
|
||||
if (!array) {
|
||||
array_init(return_value);
|
||||
array = 1;
|
||||
}
|
||||
add_next_index_string(return_value, zif->common.function_name, 1);
|
||||
char *lcname = zend_str_tolower_dup(extension_name, extension_name_len);
|
||||
if (zend_hash_find(&module_registry, lcname,
|
||||
extension_name_len+1, (void**)&module) == FAILURE) {
|
||||
efree(lcname);
|
||||
RETURN_FALSE;
|
||||
}
|
||||
zend_hash_move_forward_ex(CG(function_table), &iterator);
|
||||
efree(lcname);
|
||||
|
||||
if (!(func = module->functions)) {
|
||||
RETURN_FALSE;
|
||||
}
|
||||
} else {
|
||||
func = builtin_functions;
|
||||
}
|
||||
|
||||
efree(lcname);
|
||||
array_init(return_value);
|
||||
|
||||
if (!array) {
|
||||
RETURN_FALSE;
|
||||
while (func->fname) {
|
||||
add_next_index_string(return_value, func->fname, 1);
|
||||
func++;
|
||||
}
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2015 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2015 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
@@ -449,7 +449,6 @@ ZEND_API void zend_create_closure(zval *res, zend_function *func, zend_class_ent
|
||||
|
||||
closure->func = *func;
|
||||
closure->func.common.prototype = NULL;
|
||||
closure->func.common.fn_flags |= ZEND_ACC_CLOSURE;
|
||||
|
||||
if ((scope == NULL) && (this_ptr != NULL)) {
|
||||
/* use dummy scope if we're binding an object without specifying a scope */
|
||||
@@ -487,7 +486,6 @@ ZEND_API void zend_create_closure(zval *res, zend_function *func, zend_class_ent
|
||||
}
|
||||
}
|
||||
|
||||
closure->this_ptr = NULL;
|
||||
/* Invariants:
|
||||
* If the closure is unscoped, it has no bound object.
|
||||
* The the closure is scoped, it's either static or it's bound */
|
||||
@@ -499,7 +497,10 @@ ZEND_API void zend_create_closure(zval *res, zend_function *func, zend_class_ent
|
||||
Z_ADDREF_P(this_ptr);
|
||||
} else {
|
||||
closure->func.common.fn_flags |= ZEND_ACC_STATIC;
|
||||
closure->this_ptr = NULL;
|
||||
}
|
||||
} else {
|
||||
closure->this_ptr = NULL;
|
||||
}
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2015 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
+8
-26
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2015 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
@@ -2140,12 +2140,6 @@ void zend_do_resolve_class_name(znode *result, znode *class_name, int is_static
|
||||
if (!CG(active_class_entry)) {
|
||||
zend_error(E_COMPILE_ERROR, "Cannot access self::class when no class scope is active");
|
||||
}
|
||||
if (CG(active_class_entry)->ce_flags & ZEND_ACC_TRAIT) {
|
||||
constant_name.op_type = IS_CONST;
|
||||
ZVAL_STRINGL(&constant_name.u.constant, "class", sizeof("class")-1, 1);
|
||||
zend_do_fetch_constant(result, class_name, &constant_name, ZEND_RT, 1 TSRMLS_CC);
|
||||
break;
|
||||
}
|
||||
zval_dtor(&class_name->u.constant);
|
||||
class_name->op_type = IS_CONST;
|
||||
ZVAL_STRINGL(&class_name->u.constant, CG(active_class_entry)->name, CG(active_class_entry)->name_length, 1);
|
||||
@@ -2788,7 +2782,7 @@ void zend_do_yield(znode *result, znode *value, const znode *key, zend_bool is_v
|
||||
SET_UNUSED(opline->op2);
|
||||
}
|
||||
|
||||
opline->result_type = IS_VAR;
|
||||
opline->result_type = IS_TMP_VAR;
|
||||
opline->result.var = get_temporary_variable(CG(active_op_array));
|
||||
GET_NODE(result, opline->result);
|
||||
}
|
||||
@@ -3342,11 +3336,8 @@ static char * zend_get_function_declaration(zend_function *fptr TSRMLS_DC) /* {{
|
||||
*zv = *precv->op2.zv;
|
||||
zval_copy_ctor(zv);
|
||||
INIT_PZVAL(zv);
|
||||
if ((Z_TYPE_P(zv) & IS_CONSTANT_TYPE_MASK) == IS_CONSTANT) {
|
||||
REALLOC_BUF_IF_EXCEED(buf, offset, length, Z_STRLEN_P(zv));
|
||||
memcpy(offset, Z_STRVAL_P(zv), Z_STRLEN_P(zv));
|
||||
offset += Z_STRLEN_P(zv);
|
||||
} else if (Z_TYPE_P(zv) == IS_BOOL) {
|
||||
zval_update_constant_ex(&zv, (void*)1, fptr->common.scope TSRMLS_CC);
|
||||
if (Z_TYPE_P(zv) == IS_BOOL) {
|
||||
if (Z_LVAL_P(zv)) {
|
||||
memcpy(offset, "true", 4);
|
||||
offset += 4;
|
||||
@@ -3368,7 +3359,7 @@ static char * zend_get_function_declaration(zend_function *fptr TSRMLS_DC) /* {{
|
||||
*(offset++) = '.';
|
||||
}
|
||||
*(offset++) = '\'';
|
||||
} else if (Z_TYPE_P(zv) == IS_ARRAY || (Z_TYPE_P(zv) & IS_CONSTANT_TYPE_MASK) == IS_CONSTANT_ARRAY) {
|
||||
} else if (Z_TYPE_P(zv) == IS_ARRAY) {
|
||||
memcpy(offset, "Array", 5);
|
||||
offset += 5;
|
||||
} else {
|
||||
@@ -3842,7 +3833,7 @@ static void zend_add_magic_methods(zend_class_entry* ce, const char* mname, uint
|
||||
if (!strncmp(mname, ZEND_CLONE_FUNC_NAME, mname_len)) {
|
||||
ce->clone = fe; fe->common.fn_flags |= ZEND_ACC_CLONE;
|
||||
} else if (!strncmp(mname, ZEND_CONSTRUCTOR_FUNC_NAME, mname_len)) {
|
||||
if (ce->constructor && (!ce->parent || ce->constructor != ce->parent->constructor)) {
|
||||
if (ce->constructor) {
|
||||
zend_error(E_COMPILE_ERROR, "%s has colliding constructor definitions coming from traits", ce->name);
|
||||
}
|
||||
ce->constructor = fe; fe->common.fn_flags |= ZEND_ACC_CTOR;
|
||||
@@ -3867,7 +3858,7 @@ static void zend_add_magic_methods(zend_class_entry* ce, const char* mname, uint
|
||||
zend_str_tolower_copy(lowercase_name, ce->name, ce->name_length);
|
||||
lowercase_name = (char*)zend_new_interned_string(lowercase_name, ce->name_length + 1, 1 TSRMLS_CC);
|
||||
if (!memcmp(mname, lowercase_name, mname_len)) {
|
||||
if (ce->constructor && (!ce->parent || ce->constructor != ce->parent->constructor)) {
|
||||
if (ce->constructor) {
|
||||
zend_error(E_COMPILE_ERROR, "%s has colliding constructor definitions coming from traits", ce->name);
|
||||
}
|
||||
ce->constructor = fe;
|
||||
@@ -4122,7 +4113,7 @@ static void zend_traits_init_trait_structures(zend_class_entry *ce TSRMLS_DC) /*
|
||||
|
||||
/* make sure that the trait method is not from a class mentioned in
|
||||
exclude_from_classes, for consistency */
|
||||
if (cur_precedence->trait_method->ce == cur_precedence->exclude_from_classes[j]) {
|
||||
if (cur_precedence->trait_method->ce == cur_precedence->exclude_from_classes[i]) {
|
||||
zend_error(E_COMPILE_ERROR,
|
||||
"Inconsistent insteadof definition. "
|
||||
"The method %s is to be used from %s, but %s is also on the exclude list",
|
||||
@@ -6237,15 +6228,6 @@ void zend_do_foreach_begin(znode *foreach_token, znode *open_brackets_token, zno
|
||||
/* save the location of FETCH_W instruction(s) */
|
||||
open_brackets_token->u.op.opline_num = get_next_op_number(CG(active_op_array));
|
||||
zend_do_end_variable_parse(array, BP_VAR_W, 0 TSRMLS_CC);
|
||||
|
||||
if (zend_is_function_or_method_call(array)) {
|
||||
opline = get_next_op(CG(active_op_array) TSRMLS_CC);
|
||||
opline->opcode = ZEND_SEPARATE;
|
||||
SET_NODE(opline->op1, array);
|
||||
SET_UNUSED(opline->op2);
|
||||
opline->result_type = IS_VAR;
|
||||
opline->result.var = opline->op1.var;
|
||||
}
|
||||
} else {
|
||||
is_variable = 0;
|
||||
open_brackets_token->u.op.opline_num = get_next_op_number(CG(active_op_array));
|
||||
|
||||
+1
-6
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2015 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
@@ -666,8 +666,6 @@ ZEND_API void zend_cleanup_internal_class_data(zend_class_entry *ce TSRMLS_DC);
|
||||
ZEND_API void zend_cleanup_internal_classes(TSRMLS_D);
|
||||
ZEND_API int zend_cleanup_function_data(zend_function *function TSRMLS_DC);
|
||||
ZEND_API int zend_cleanup_function_data_full(zend_function *function TSRMLS_DC);
|
||||
ZEND_API int clean_non_persistent_function_full(zend_function *function TSRMLS_DC);
|
||||
ZEND_API int clean_non_persistent_class_full(zend_class_entry **ce TSRMLS_DC);
|
||||
|
||||
ZEND_API void destroy_zend_function(zend_function *function TSRMLS_DC);
|
||||
ZEND_API void zend_function_dtor(zend_function *function);
|
||||
@@ -845,9 +843,6 @@ int zend_add_literal(zend_op_array *op_array, const zval *zv TSRMLS_DC);
|
||||
#define ZEND_FAST_RET_TO_CATCH 1
|
||||
#define ZEND_FAST_RET_TO_FINALLY 2
|
||||
|
||||
#define ZEND_FAST_CALL_FROM_CATCH 1
|
||||
#define ZEND_FAST_CALL_FROM_FINALLY 2
|
||||
|
||||
END_EXTERN_C()
|
||||
|
||||
#define ZEND_CLONE_FUNC_NAME "__clone"
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2015 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2015 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
@@ -62,15 +62,10 @@ typedef unsigned int uint;
|
||||
/* This will cause the compilation process to be MUCH longer, but will generate
|
||||
* a much quicker PHP binary
|
||||
*/
|
||||
#undef inline
|
||||
#ifdef ZEND_WIN32_FORCE_INLINE
|
||||
/* _ALLOW_KEYWORD_MACROS is only relevant for C++ */
|
||||
# if (_MSC_VER >= 1700) && !defined(_ALLOW_KEYWORD_MACROS)
|
||||
# define _ALLOW_KEYWORD_MACROS
|
||||
# endif
|
||||
# undef inline
|
||||
# define inline __forceinline
|
||||
#elif !defined(ZEND_WIN32_KEEP_INLINE)
|
||||
# undef inline
|
||||
#else
|
||||
# define inline
|
||||
#endif
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2015 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2015 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2015 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2015 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2015 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
+1
-1
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2015 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
+4
-59
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2015 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
@@ -360,11 +360,6 @@ ZEND_METHOD(error_exception, getSeverity)
|
||||
} \
|
||||
}
|
||||
|
||||
|
||||
#define TRACE_ARG_APPEND(vallen) \
|
||||
*str = (char*)erealloc(*str, *len + 1 + vallen); \
|
||||
memmove((*str) + *len - l_added + 1 + vallen, (*str) + *len - l_added + 1, l_added);
|
||||
|
||||
/* }}} */
|
||||
|
||||
static int _build_trace_args(zval **arg TSRMLS_DC, int num_args, va_list args, zend_hash_key *hash_key) /* {{{ */
|
||||
@@ -376,7 +371,7 @@ static int _build_trace_args(zval **arg TSRMLS_DC, int num_args, va_list args, z
|
||||
len = va_arg(args, int*);
|
||||
|
||||
/* the trivial way would be to do:
|
||||
* convert_to_string_ex(arg);
|
||||
* conver_to_string_ex(arg);
|
||||
* append it and kill the now tmp arg.
|
||||
* but that could cause some E_NOTICE and also damn long lines.
|
||||
*/
|
||||
@@ -399,58 +394,8 @@ static int _build_trace_args(zval **arg TSRMLS_DC, int num_args, va_list args, z
|
||||
l_added += 3 + 1;
|
||||
}
|
||||
while (--l_added) {
|
||||
unsigned char chr = (*str)[*len - l_added];
|
||||
if (chr < 32 || chr == '\\' || chr > 126) {
|
||||
(*str)[*len - l_added] = '\\';
|
||||
|
||||
switch (chr) {
|
||||
case '\n':
|
||||
TRACE_ARG_APPEND(1);
|
||||
(*str)[++(*len) - l_added] = 'n';
|
||||
break;
|
||||
case '\r':
|
||||
TRACE_ARG_APPEND(1);
|
||||
(*str)[++(*len) - l_added] = 'r';
|
||||
break;
|
||||
case '\t':
|
||||
TRACE_ARG_APPEND(1);
|
||||
(*str)[++(*len) - l_added] = 't';
|
||||
break;
|
||||
case '\f':
|
||||
TRACE_ARG_APPEND(1);
|
||||
(*str)[++(*len) - l_added] = 'f';
|
||||
break;
|
||||
case '\v':
|
||||
TRACE_ARG_APPEND(1);
|
||||
(*str)[++(*len) - l_added] = 'v';
|
||||
break;
|
||||
#ifndef PHP_WIN32
|
||||
case '\e':
|
||||
#else
|
||||
case VK_ESCAPE:
|
||||
#endif
|
||||
TRACE_ARG_APPEND(1);
|
||||
(*str)[++(*len) - l_added] = 'e';
|
||||
break;
|
||||
case '\\':
|
||||
TRACE_ARG_APPEND(1);
|
||||
(*str)[++(*len) - l_added] = '\\';
|
||||
break;
|
||||
default:
|
||||
TRACE_ARG_APPEND(3);
|
||||
(*str)[*len - l_added + 1] = 'x';
|
||||
if ((chr >> 4) < 10) {
|
||||
(*str)[*len - l_added + 2] = (chr >> 4) + '0';
|
||||
} else {
|
||||
(*str)[*len - l_added + 2] = (chr >> 4) + 'A' - 10;
|
||||
}
|
||||
if (chr % 16 < 10) {
|
||||
(*str)[*len - l_added + 3] = chr % 16 + '0';
|
||||
} else {
|
||||
(*str)[*len - l_added + 3] = chr % 16 + 'A' - 10;
|
||||
}
|
||||
*len += 3;
|
||||
}
|
||||
if ((*str)[*len - l_added] < 32) {
|
||||
(*str)[*len - l_added] = '?';
|
||||
}
|
||||
}
|
||||
break;
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2015 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
+3
-2
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2015 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
@@ -1247,8 +1247,9 @@ convert_to_array:
|
||||
}
|
||||
}
|
||||
|
||||
static void zend_fetch_dimension_address_read(temp_variable *result, zval *container, zval *dim, int dim_type, int type TSRMLS_DC)
|
||||
static void zend_fetch_dimension_address_read(temp_variable *result, zval **container_ptr, zval *dim, int dim_type, int type TSRMLS_DC)
|
||||
{
|
||||
zval *container = *container_ptr;
|
||||
zval **retval;
|
||||
|
||||
switch (Z_TYPE_P(container)) {
|
||||
|
||||
+8
-1
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2015 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
@@ -352,6 +352,13 @@ ZEND_API zend_class_entry *zend_fetch_class(const char *class_name, uint class_n
|
||||
ZEND_API zend_class_entry *zend_fetch_class_by_name(const char *class_name, uint class_name_len, const zend_literal *key, int fetch_type TSRMLS_DC);
|
||||
void zend_verify_abstract_class(zend_class_entry *ce TSRMLS_DC);
|
||||
|
||||
#ifdef ZEND_WIN32
|
||||
void zend_init_timeout_thread(void);
|
||||
void zend_shutdown_timeout_thread(void);
|
||||
#define WM_REGISTER_ZEND_TIMEOUT (WM_USER+1)
|
||||
#define WM_UNREGISTER_ZEND_TIMEOUT (WM_USER+2)
|
||||
#endif
|
||||
|
||||
#define zendi_zval_copy_ctor(p) zval_copy_ctor(&(p))
|
||||
#define zendi_zval_dtor(p) zval_dtor(&(p))
|
||||
|
||||
|
||||
+126
-52
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2015 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
@@ -46,10 +46,13 @@ ZEND_API const zend_fcall_info empty_fcall_info = { 0, NULL, NULL, NULL, NULL, 0
|
||||
ZEND_API const zend_fcall_info_cache empty_fcall_info_cache = { 0, NULL, NULL, NULL, NULL };
|
||||
|
||||
#ifdef ZEND_WIN32
|
||||
#ifdef ZTS
|
||||
__declspec(thread)
|
||||
#endif
|
||||
HANDLE tq_timer = NULL;
|
||||
#include <process.h>
|
||||
static WNDCLASS wc;
|
||||
static HWND timeout_window;
|
||||
static HANDLE timeout_thread_event;
|
||||
static HANDLE timeout_thread_handle;
|
||||
static DWORD timeout_thread_id;
|
||||
static int timeout_thread_initialized=0;
|
||||
#endif
|
||||
|
||||
#if 0&&ZEND_DEBUG
|
||||
@@ -106,7 +109,7 @@ static int clean_non_persistent_function(zend_function *function TSRMLS_DC) /* {
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
ZEND_API int clean_non_persistent_function_full(zend_function *function TSRMLS_DC) /* {{{ */
|
||||
static int clean_non_persistent_function_full(zend_function *function TSRMLS_DC) /* {{{ */
|
||||
{
|
||||
return (function->type == ZEND_INTERNAL_FUNCTION) ? ZEND_HASH_APPLY_KEEP : ZEND_HASH_APPLY_REMOVE;
|
||||
}
|
||||
@@ -118,7 +121,7 @@ static int clean_non_persistent_class(zend_class_entry **ce TSRMLS_DC) /* {{{ */
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
ZEND_API int clean_non_persistent_class_full(zend_class_entry **ce TSRMLS_DC) /* {{{ */
|
||||
static int clean_non_persistent_class_full(zend_class_entry **ce TSRMLS_DC) /* {{{ */
|
||||
{
|
||||
return ((*ce)->type == ZEND_INTERNAL_CLASS) ? ZEND_HASH_APPLY_KEEP : ZEND_HASH_APPLY_REMOVE;
|
||||
}
|
||||
@@ -445,6 +448,8 @@ ZEND_API int zend_is_true(zval *op) /* {{{ */
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
#include "../TSRM/tsrm_strtok_r.h"
|
||||
|
||||
#define IS_VISITED_CONSTANT IS_CONSTANT_INDEX
|
||||
#define IS_CONSTANT_VISITED(p) (Z_TYPE_P(p) & IS_VISITED_CONSTANT)
|
||||
#define Z_REAL_TYPE_P(p) (Z_TYPE_P(p) & ~IS_VISITED_CONSTANT)
|
||||
@@ -1058,14 +1063,6 @@ ZEND_API int zend_lookup_class_ex(const char *name, int name_length, const zend_
|
||||
return FAILURE;
|
||||
}
|
||||
|
||||
/* Verify class name before passing it to __autoload() */
|
||||
if (strspn(name, "0123456789_abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ\177\200\201\202\203\204\205\206\207\210\211\212\213\214\215\216\217\220\221\222\223\224\225\226\227\230\231\232\233\234\235\236\237\240\241\242\243\244\245\246\247\250\251\252\253\254\255\256\257\260\261\262\263\264\265\266\267\270\271\272\273\274\275\276\277\300\301\302\303\304\305\306\307\310\311\312\313\314\315\316\317\320\321\322\323\324\325\326\327\330\331\332\333\334\335\336\337\340\341\342\343\344\345\346\347\350\351\352\353\354\355\356\357\360\361\362\363\364\365\366\367\370\371\372\373\374\375\376\377\\") != name_length) {
|
||||
if (!key) {
|
||||
free_alloca(lc_free, use_heap);
|
||||
}
|
||||
return FAILURE;
|
||||
}
|
||||
|
||||
if (EG(in_autoload) == NULL) {
|
||||
ALLOC_HASHTABLE(EG(in_autoload));
|
||||
zend_hash_init(EG(in_autoload), 0, NULL, NULL, 0);
|
||||
@@ -1336,19 +1333,111 @@ ZEND_API void zend_timeout(int dummy) /* {{{ */
|
||||
/* }}} */
|
||||
|
||||
#ifdef ZEND_WIN32
|
||||
VOID CALLBACK tq_timer_cb(PVOID arg, BOOLEAN timed_out)
|
||||
static LRESULT CALLBACK zend_timeout_WndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lParam) /* {{{ */
|
||||
{
|
||||
zend_bool *php_timed_out;
|
||||
switch (message) {
|
||||
case WM_DESTROY:
|
||||
PostQuitMessage(0);
|
||||
break;
|
||||
case WM_REGISTER_ZEND_TIMEOUT:
|
||||
/* wParam is the thread id pointer, lParam is the timeout amount in seconds */
|
||||
if (lParam == 0) {
|
||||
KillTimer(timeout_window, wParam);
|
||||
} else {
|
||||
#ifdef ZTS
|
||||
void ***tsrm_ls;
|
||||
#endif
|
||||
SetTimer(timeout_window, wParam, lParam*1000, NULL);
|
||||
#ifdef ZTS
|
||||
tsrm_ls = ts_resource_ex(0, &wParam);
|
||||
if (!tsrm_ls) {
|
||||
/* shouldn't normally happen */
|
||||
break;
|
||||
}
|
||||
#endif
|
||||
EG(timed_out) = 0;
|
||||
}
|
||||
break;
|
||||
case WM_UNREGISTER_ZEND_TIMEOUT:
|
||||
/* wParam is the thread id pointer */
|
||||
KillTimer(timeout_window, wParam);
|
||||
break;
|
||||
case WM_TIMER: {
|
||||
#ifdef ZTS
|
||||
void ***tsrm_ls;
|
||||
|
||||
/* The doc states it'll be always true, however it theoretically
|
||||
could be FALSE when the thread was signaled. */
|
||||
if (!timed_out) {
|
||||
tsrm_ls = ts_resource_ex(0, &wParam);
|
||||
if (!tsrm_ls) {
|
||||
/* Thread died before receiving its timeout? */
|
||||
break;
|
||||
}
|
||||
#endif
|
||||
KillTimer(timeout_window, wParam);
|
||||
EG(timed_out) = 1;
|
||||
}
|
||||
break;
|
||||
default:
|
||||
return DefWindowProc(hWnd, message, wParam, lParam);
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
static unsigned __stdcall timeout_thread_proc(void *pArgs) /* {{{ */
|
||||
{
|
||||
MSG message;
|
||||
|
||||
wc.style=0;
|
||||
wc.lpfnWndProc = zend_timeout_WndProc;
|
||||
wc.cbClsExtra=0;
|
||||
wc.cbWndExtra=0;
|
||||
wc.hInstance=NULL;
|
||||
wc.hIcon=NULL;
|
||||
wc.hCursor=NULL;
|
||||
wc.hbrBackground=(HBRUSH)(COLOR_BACKGROUND + 5);
|
||||
wc.lpszMenuName=NULL;
|
||||
wc.lpszClassName = "Zend Timeout Window";
|
||||
if (!RegisterClass(&wc)) {
|
||||
return -1;
|
||||
}
|
||||
timeout_window = CreateWindow(wc.lpszClassName, wc.lpszClassName, 0, CW_USEDEFAULT, CW_USEDEFAULT, CW_USEDEFAULT, CW_USEDEFAULT, NULL, NULL, NULL, NULL);
|
||||
SetEvent(timeout_thread_event);
|
||||
while (GetMessage(&message, NULL, 0, 0)) {
|
||||
SendMessage(timeout_window, message.message, message.wParam, message.lParam);
|
||||
if (message.message == WM_QUIT) {
|
||||
break;
|
||||
}
|
||||
}
|
||||
DestroyWindow(timeout_window);
|
||||
UnregisterClass(wc.lpszClassName, NULL);
|
||||
SetEvent(timeout_thread_handle);
|
||||
return 0;
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
void zend_init_timeout_thread(void) /* {{{ */
|
||||
{
|
||||
timeout_thread_event = CreateEvent(NULL, FALSE, FALSE, NULL);
|
||||
timeout_thread_handle = CreateEvent(NULL, FALSE, FALSE, NULL);
|
||||
_beginthreadex(NULL, 0, timeout_thread_proc, NULL, 0, &timeout_thread_id);
|
||||
WaitForSingleObject(timeout_thread_event, INFINITE);
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
void zend_shutdown_timeout_thread(void) /* {{{ */
|
||||
{
|
||||
if (!timeout_thread_initialized) {
|
||||
return;
|
||||
}
|
||||
PostThreadMessage(timeout_thread_id, WM_QUIT, 0, 0);
|
||||
|
||||
php_timed_out = (zend_bool *)arg;
|
||||
*php_timed_out = 1;
|
||||
/* Wait for thread termination */
|
||||
WaitForSingleObject(timeout_thread_handle, 5000);
|
||||
CloseHandle(timeout_thread_handle);
|
||||
timeout_thread_initialized = 0;
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
#endif
|
||||
|
||||
/* This one doesn't exists on QNX */
|
||||
@@ -1366,28 +1455,13 @@ void zend_set_timeout(long seconds, int reset_signals) /* {{{ */
|
||||
if(!seconds) {
|
||||
return;
|
||||
}
|
||||
|
||||
/* Don't use ChangeTimerQueueTimer() as it will not restart an expired
|
||||
timer, so we could end up with just an ignored timeout. Instead
|
||||
delete and recreate. */
|
||||
if (NULL != tq_timer) {
|
||||
if (!DeleteTimerQueueTimer(NULL, tq_timer, NULL)) {
|
||||
EG(timed_out) = 0;
|
||||
tq_timer = NULL;
|
||||
zend_error(E_ERROR, "Could not delete queued timer");
|
||||
return;
|
||||
}
|
||||
tq_timer = NULL;
|
||||
if (timeout_thread_initialized == 0 && InterlockedIncrement(&timeout_thread_initialized) == 1) {
|
||||
/* We start up this process-wide thread here and not in zend_startup(), because if Zend
|
||||
* is initialized inside a DllMain(), you're not supposed to start threads from it.
|
||||
*/
|
||||
zend_init_timeout_thread();
|
||||
}
|
||||
|
||||
/* XXX passing NULL means the default timer queue provided by the system is used */
|
||||
if (!CreateTimerQueueTimer(&tq_timer, NULL, (WAITORTIMERCALLBACK)tq_timer_cb, (VOID*)&EG(timed_out), seconds*1000, 0, WT_EXECUTEONLYONCE)) {
|
||||
EG(timed_out) = 0;
|
||||
tq_timer = NULL;
|
||||
zend_error(E_ERROR, "Could not queue new timer");
|
||||
return;
|
||||
}
|
||||
EG(timed_out) = 0;
|
||||
PostThreadMessage(timeout_thread_id, WM_REGISTER_ZEND_TIMEOUT, (WPARAM) GetCurrentThreadId(), (LPARAM) seconds);
|
||||
#else
|
||||
# ifdef HAVE_SETITIMER
|
||||
{
|
||||
@@ -1429,16 +1503,9 @@ void zend_set_timeout(long seconds, int reset_signals) /* {{{ */
|
||||
void zend_unset_timeout(TSRMLS_D) /* {{{ */
|
||||
{
|
||||
#ifdef ZEND_WIN32
|
||||
if (NULL != tq_timer) {
|
||||
if (!DeleteTimerQueueTimer(NULL, tq_timer, NULL)) {
|
||||
EG(timed_out) = 0;
|
||||
tq_timer = NULL;
|
||||
zend_error(E_ERROR, "Could not delete queued timer");
|
||||
return;
|
||||
}
|
||||
tq_timer = NULL;
|
||||
if(timeout_thread_initialized) {
|
||||
PostThreadMessage(timeout_thread_id, WM_UNREGISTER_ZEND_TIMEOUT, (WPARAM) GetCurrentThreadId(), (LPARAM) 0);
|
||||
}
|
||||
EG(timed_out) = 0;
|
||||
#else
|
||||
# ifdef HAVE_SETITIMER
|
||||
if (EG(timeout_seconds)) {
|
||||
@@ -1688,6 +1755,13 @@ ZEND_API void zend_rebuild_symbol_table(TSRMLS_D) /* {{{ */
|
||||
/*printf("Cache miss! Initialized %x\n", EG(active_symbol_table));*/
|
||||
}
|
||||
ex->symbol_table = EG(active_symbol_table);
|
||||
|
||||
if (ex->op_array->this_var != -1 &&
|
||||
!*EX_CV_NUM(ex, ex->op_array->this_var) &&
|
||||
EG(This)) {
|
||||
*EX_CV_NUM(ex, ex->op_array->this_var) = (zval**)EX_CV_NUM(ex, ex->op_array->last_var + ex->op_array->this_var);
|
||||
**EX_CV_NUM(ex, ex->op_array->this_var) = EG(This);
|
||||
}
|
||||
for (i = 0; i < ex->op_array->last_var; i++) {
|
||||
if (*EX_CV_NUM(ex, i)) {
|
||||
zend_hash_quick_update(EG(active_symbol_table),
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2015 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2015 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
+1
-1
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2015 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
+1
-5
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2015 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
@@ -21,8 +21,6 @@
|
||||
#ifndef ZEND_FLOAT_H
|
||||
#define ZEND_FLOAT_H
|
||||
|
||||
BEGIN_EXTERN_C()
|
||||
|
||||
/*
|
||||
Define functions for FP initialization and de-initialization.
|
||||
*/
|
||||
@@ -30,8 +28,6 @@ extern ZEND_API void zend_init_fpu(TSRMLS_D);
|
||||
extern ZEND_API void zend_shutdown_fpu(TSRMLS_D);
|
||||
extern ZEND_API void zend_ensure_fpu_mode(TSRMLS_D);
|
||||
|
||||
END_EXTERN_C()
|
||||
|
||||
/* Copy of the contents of xpfpa.h (which is under public domain)
|
||||
See http://wiki.php.net/rfc/rounding for details.
|
||||
|
||||
|
||||
+1
-1
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2015 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
+1
-1
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2015 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
+66
-83
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2015 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
@@ -29,73 +29,6 @@ static zend_object_handlers zend_generator_handlers;
|
||||
|
||||
static zend_object_value zend_generator_create(zend_class_entry *class_type TSRMLS_DC);
|
||||
|
||||
static void zend_generator_cleanup_unfinished_execution(zend_generator *generator TSRMLS_DC) /* {{{ */
|
||||
{
|
||||
zend_execute_data *execute_data = generator->execute_data;
|
||||
zend_op_array *op_array = execute_data->op_array;
|
||||
|
||||
if (generator->send_target) {
|
||||
Z_DELREF_PP(generator->send_target);
|
||||
generator->send_target = NULL;
|
||||
}
|
||||
|
||||
/* Manually free loop variables, as execution couldn't reach their
|
||||
* SWITCH_FREE / FREE opcodes. */
|
||||
{
|
||||
/* -1 required because we want the last run opcode, not the
|
||||
* next to-be-run one. */
|
||||
zend_uint op_num = execute_data->opline - op_array->opcodes - 1;
|
||||
|
||||
int i;
|
||||
for (i = 0; i < op_array->last_brk_cont; ++i) {
|
||||
zend_brk_cont_element *brk_cont = op_array->brk_cont_array + i;
|
||||
|
||||
if (brk_cont->start < 0) {
|
||||
continue;
|
||||
} else if (brk_cont->start > op_num) {
|
||||
break;
|
||||
} else if (brk_cont->brk > op_num) {
|
||||
zend_op *brk_opline = op_array->opcodes + brk_cont->brk;
|
||||
|
||||
switch (brk_opline->opcode) {
|
||||
case ZEND_SWITCH_FREE:
|
||||
{
|
||||
temp_variable *var = EX_TMP_VAR(execute_data, brk_opline->op1.var);
|
||||
zval_ptr_dtor(&var->var.ptr);
|
||||
}
|
||||
break;
|
||||
case ZEND_FREE:
|
||||
{
|
||||
temp_variable *var = EX_TMP_VAR(execute_data, brk_opline->op1.var);
|
||||
zval_dtor(&var->tmp_var);
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* Clear any backed up stack arguments */
|
||||
{
|
||||
void **ptr = generator->stack->top - 1;
|
||||
void **end = zend_vm_stack_frame_base(execute_data);
|
||||
|
||||
for (; ptr >= end; --ptr) {
|
||||
zval_ptr_dtor((zval **) ptr);
|
||||
}
|
||||
}
|
||||
|
||||
/* If yield was used as a function argument there may be active
|
||||
* method calls those objects need to be freed */
|
||||
while (execute_data->call >= execute_data->call_slots) {
|
||||
if (execute_data->call->object) {
|
||||
zval_ptr_dtor(&execute_data->call->object);
|
||||
}
|
||||
execute_data->call--;
|
||||
}
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
ZEND_API void zend_generator_close(zend_generator *generator, zend_bool finished_execution TSRMLS_DC) /* {{{ */
|
||||
{
|
||||
if (generator->value) {
|
||||
@@ -125,10 +58,68 @@ ZEND_API void zend_generator_close(zend_generator *generator, zend_bool finished
|
||||
/* A fatal error / die occurred during the generator execution. Trying to clean
|
||||
* up the stack may not be safe in this case. */
|
||||
if (CG(unclean_shutdown)) {
|
||||
generator->execute_data = NULL;
|
||||
return;
|
||||
}
|
||||
|
||||
/* If the generator is closed before it can finish execution (reach
|
||||
* a return statement) we have to free loop variables manually, as
|
||||
* we don't know whether the SWITCH_FREE / FREE opcodes have run */
|
||||
if (!finished_execution) {
|
||||
/* -1 required because we want the last run opcode, not the
|
||||
* next to-be-run one. */
|
||||
zend_uint op_num = execute_data->opline - op_array->opcodes - 1;
|
||||
|
||||
int i;
|
||||
for (i = 0; i < op_array->last_brk_cont; ++i) {
|
||||
zend_brk_cont_element *brk_cont = op_array->brk_cont_array + i;
|
||||
|
||||
if (brk_cont->start < 0) {
|
||||
continue;
|
||||
} else if (brk_cont->start > op_num) {
|
||||
break;
|
||||
} else if (brk_cont->brk > op_num) {
|
||||
zend_op *brk_opline = op_array->opcodes + brk_cont->brk;
|
||||
|
||||
switch (brk_opline->opcode) {
|
||||
case ZEND_SWITCH_FREE:
|
||||
{
|
||||
temp_variable *var = EX_TMP_VAR(execute_data, brk_opline->op1.var);
|
||||
zval_ptr_dtor(&var->var.ptr);
|
||||
}
|
||||
break;
|
||||
case ZEND_FREE:
|
||||
{
|
||||
temp_variable *var = EX_TMP_VAR(execute_data, brk_opline->op1.var);
|
||||
zval_dtor(&var->tmp_var);
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* Clear any backed up stack arguments */
|
||||
if (generator->stack != EG(argument_stack)) {
|
||||
void **ptr = generator->stack->top - 1;
|
||||
void **end = zend_vm_stack_frame_base(execute_data);
|
||||
|
||||
/* If the top stack element is the argument count, skip it */
|
||||
if (execute_data->function_state.arguments) {
|
||||
ptr--;
|
||||
}
|
||||
|
||||
for (; ptr >= end; --ptr) {
|
||||
zval_ptr_dtor((zval**) ptr);
|
||||
}
|
||||
}
|
||||
|
||||
while (execute_data->call >= execute_data->call_slots) {
|
||||
if (execute_data->call->object) {
|
||||
zval_ptr_dtor(&execute_data->call->object);
|
||||
}
|
||||
execute_data->call--;
|
||||
}
|
||||
|
||||
/* We have added an additional stack frame in prev_execute_data, so we
|
||||
* have to free it. It also contains the arguments passed to the
|
||||
* generator (for func_get_args) so those have to be freed too. */
|
||||
@@ -147,12 +138,6 @@ ZEND_API void zend_generator_close(zend_generator *generator, zend_bool finished
|
||||
}
|
||||
}
|
||||
|
||||
/* Some cleanups are only necessary if the generator was closued
|
||||
* before it could finish execution (reach a return statement). */
|
||||
if (!finished_execution) {
|
||||
zend_generator_cleanup_unfinished_execution(generator TSRMLS_CC);
|
||||
}
|
||||
|
||||
/* Free a clone of closure */
|
||||
if (op_array->fn_flags & ZEND_ACC_CLOSURE) {
|
||||
destroy_op_array(op_array TSRMLS_CC);
|
||||
@@ -160,6 +145,10 @@ ZEND_API void zend_generator_close(zend_generator *generator, zend_bool finished
|
||||
}
|
||||
|
||||
efree(generator->stack);
|
||||
if (generator->stack == EG(argument_stack)) {
|
||||
/* abnormal exit for running generator */
|
||||
EG(argument_stack) = NULL;
|
||||
}
|
||||
generator->execute_data = NULL;
|
||||
}
|
||||
}
|
||||
@@ -530,12 +519,8 @@ ZEND_METHOD(Generator, send)
|
||||
return;
|
||||
}
|
||||
|
||||
/* Put sent value in the target VAR slot, if it is used */
|
||||
if (generator->send_target) {
|
||||
Z_DELREF_PP(generator->send_target);
|
||||
Z_ADDREF_P(value);
|
||||
*generator->send_target = value;
|
||||
}
|
||||
/* Put sent value into the TMP_VAR slot */
|
||||
MAKE_COPY_ZVAL(&value, &generator->send_target->tmp_var);
|
||||
|
||||
zend_generator_resume(generator TSRMLS_CC);
|
||||
|
||||
@@ -561,8 +546,6 @@ ZEND_METHOD(Generator, throw)
|
||||
|
||||
generator = (zend_generator *) zend_object_store_get_object(getThis() TSRMLS_CC);
|
||||
|
||||
zend_generator_ensure_initialized(generator TSRMLS_CC);
|
||||
|
||||
if (generator->execute_data) {
|
||||
/* Throw the exception in the context of the generator */
|
||||
zend_execute_data *current_execute_data = EG(current_execute_data);
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2015 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
@@ -49,7 +49,7 @@ typedef struct _zend_generator {
|
||||
/* Current key */
|
||||
zval *key;
|
||||
/* Variable to put sent value into */
|
||||
zval **send_target;
|
||||
temp_variable *send_target;
|
||||
/* Largest used integer key for auto-incrementing keys */
|
||||
long largest_used_integer_key;
|
||||
|
||||
|
||||
+1
-1
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2015 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2015 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
+1
-1
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2015 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
+1
-1
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2015 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
Loaded 100 of 1721 files, more files were not shown because too many files have changed in this diff.
Show more
Reference in new issue
Block a user