mirror of
https://github.com/bdnugget/php-src.git
synced 2026-11-08 01:37:30 +00:00
Compare commits
355
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
45d2df5f11 | ||
|
|
e5ded6e843 | ||
|
|
190c7772c1 | ||
|
|
bf0d383aba | ||
|
|
7d62a321c7 | ||
|
|
b35c788a62 | ||
|
|
ff390d788f | ||
|
|
6c1cdd0814 | ||
|
|
60846fab58 | ||
|
|
f27eaa1578 | ||
|
|
2e8e2db82a | ||
|
|
0e764dc657 | ||
|
|
6597d86389 | ||
|
|
eacab735e0 | ||
|
|
8aaec7d1c3 | ||
|
|
202dcc0f6a | ||
|
|
ee42849f8f | ||
|
|
37f4f132fc | ||
|
|
4c6816ddf2 | ||
|
|
dc02b5a1fd | ||
|
|
f08e8772a7 | ||
|
|
0893a13e32 | ||
|
|
f197dafd1c | ||
|
|
5ed1bdf9a5 | ||
|
|
11e47b1cdc | ||
|
|
d76a6a3e4d | ||
|
|
210b444e1d | ||
|
|
ba8cdc855d | ||
|
|
c91ad8233b | ||
|
|
79e0c273b8 | ||
|
|
1c7f54d4f7 | ||
|
|
cbb1097770 | ||
|
|
83c302840e | ||
|
|
3828b5d83d | ||
|
|
6edc84fcdf | ||
|
|
4bc8f94b58 | ||
|
|
fb5c7cda5d | ||
|
|
3834771b2e | ||
|
|
d9078c7c8d | ||
|
|
4b8c098f02 | ||
|
|
b1396cc7a5 | ||
|
|
aafce7353e | ||
|
|
9f3a98b124 | ||
|
|
473cd4d6a9 | ||
|
|
586f379b88 | ||
|
|
909ef53e9d | ||
|
|
4e89151159 | ||
|
|
ceca4d2490 | ||
|
|
a0445644e0 | ||
|
|
8e08f6c28d | ||
|
|
c4259f90b1 | ||
|
|
6dd41435a3 | ||
|
|
c2a93ba3af | ||
|
|
1eee68d3f4 | ||
|
|
0f62b94971 | ||
|
|
a791671f40 | ||
|
|
3aa6f8bfdd | ||
|
|
dc6b14149d | ||
|
|
874a0bb7eb | ||
|
|
28e0a2129b | ||
|
|
7072db5a6b | ||
|
|
4904be6d94 | ||
|
|
03dfe0d5e0 | ||
|
|
dcdf236467 | ||
|
|
74fff1512a | ||
|
|
36a7f48e84 | ||
|
|
9cefeea860 | ||
|
|
d5f79e40e5 | ||
|
|
4b7148711b | ||
|
|
676864684b | ||
|
|
807d937e91 | ||
|
|
2bf13b2042 | ||
|
|
15acd4ee50 | ||
|
|
a3541301eb | ||
|
|
aaad97675a | ||
|
|
89a9acea1f | ||
|
|
d501707248 | ||
|
|
5b5b9b9239 | ||
|
|
3b82a477b0 | ||
|
|
fd45f1eb78 | ||
|
|
d788a85736 | ||
|
|
9eb4bc2f84 | ||
|
|
4e5195f82c | ||
|
|
89eab884d9 | ||
|
|
84efb8fc71 | ||
|
|
86096a99ec | ||
|
|
f1fc5a5bf5 | ||
|
|
deb56c010e | ||
|
|
cfce5a4d02 | ||
|
|
a053e69991 | ||
|
|
feb4eb850d | ||
|
|
998f506b6d | ||
|
|
7691926bbe | ||
|
|
7b5b2b4efa | ||
|
|
511a375e60 | ||
|
|
61028ad45e | ||
|
|
e4f1eee6c3 | ||
|
|
a92c5b14cf | ||
|
|
ee4e5ce2cf | ||
|
|
42c134df4b | ||
|
|
aca07343ce | ||
|
|
25e57e702b | ||
|
|
681e1a5ce0 | ||
|
|
d599d36d49 | ||
|
|
bbc37e78e8 | ||
|
|
73008bb5ce | ||
|
|
5980e987d2 | ||
|
|
de137e5a8d | ||
|
|
127eb33b84 | ||
|
|
e141592da6 | ||
|
|
f5182741a6 | ||
|
|
3458dac342 | ||
|
|
cf9966671c | ||
|
|
01d5e28057 | ||
|
|
aab2e8eb7e | ||
|
|
a86e869ee8 | ||
|
|
4facc35413 | ||
|
|
82dfe1acc8 | ||
|
|
9aaea81cfe | ||
|
|
3572a0482d | ||
|
|
83b00bbd08 | ||
|
|
e9883779a0 | ||
|
|
32d9409a24 | ||
|
|
6fe34014f0 | ||
|
|
28beaaad9c | ||
|
|
42f084c692 | ||
|
|
24cc7c0be2 | ||
|
|
e797e058c5 | ||
|
|
ac875f8f7e | ||
|
|
19aafe43b2 | ||
|
|
250ee4c17a | ||
|
|
6e7d24dd14 | ||
|
|
b502c0a3dc | ||
|
|
b209c27302 | ||
|
|
af6c11c5f0 | ||
|
|
0f53e37494 | ||
|
|
c9f909cd42 | ||
|
|
63d390cdf9 | ||
|
|
9e4ab7c53f | ||
|
|
57a6209051 | ||
|
|
73db3cda8b | ||
|
|
79d1c70e99 | ||
|
|
056f3441fd | ||
|
|
a3c7971f94 | ||
|
|
7844fb292c | ||
|
|
717dcdaa67 | ||
|
|
764190c1d6 | ||
|
|
6b34343479 | ||
|
|
8b72df0608 | ||
|
|
408ae9a452 | ||
|
|
bd3e5aab1d | ||
|
|
8785e22bca | ||
|
|
50f09d8256 | ||
|
|
fb4678f1ac | ||
|
|
c0476ff44b | ||
|
|
1a4863d560 | ||
|
|
65fd18fd88 | ||
|
|
d6713f3989 | ||
|
|
ef56cfb991 | ||
|
|
c676f5b36d | ||
|
|
734c28d242 | ||
|
|
bd0a8f31a4 | ||
|
|
03e36cd5b8 | ||
|
|
b3c43a1aec | ||
|
|
3af0ee0ea3 | ||
|
|
c02acf3c29 | ||
|
|
ca8ff0725b | ||
|
|
e07dfa96b3 | ||
|
|
ad358593a8 | ||
|
|
6daa84f199 | ||
|
|
056f6fd895 | ||
|
|
392f6830a1 | ||
|
|
67eccf8617 | ||
|
|
bd88bed670 | ||
|
|
209ec406ca | ||
|
|
f4a96983e1 | ||
|
|
62fa84a031 | ||
|
|
5bc9e006e8 | ||
|
|
6a2a2b52f9 | ||
|
|
befdd1770a | ||
|
|
523a6b50ae | ||
|
|
8ce521a6a7 | ||
|
|
621862a192 | ||
|
|
e700cbff22 | ||
|
|
2bf271bbb0 | ||
|
|
5b1f6caaf0 | ||
|
|
0cc89be244 | ||
|
|
e2b75e5bb7 | ||
|
|
1b1b706818 | ||
|
|
3926362d30 | ||
|
|
f500be8838 | ||
|
|
ba51a375ae | ||
|
|
db025b3789 | ||
|
|
e1a5edaac2 | ||
|
|
e75b967610 | ||
|
|
551569262b | ||
|
|
ce4ba54583 | ||
|
|
b11b3d201f | ||
|
|
26096aa73f | ||
|
|
a8a36b7d52 | ||
|
|
aed4b086ac | ||
|
|
c83598119b | ||
|
|
d02340bb39 | ||
|
|
f883d3cc7a | ||
|
|
ed5a8d510f | ||
|
|
f70f89c1b1 | ||
|
|
520d969fea | ||
|
|
432e91f112 | ||
|
|
e6b471933c | ||
|
|
bd58146ad6 | ||
|
|
2eb9bd316d | ||
|
|
d14670ccdb | ||
|
|
c0f1e6946d | ||
|
|
72389dd53f | ||
|
|
a9c503bc27 | ||
|
|
ac719610f4 | ||
|
|
5613d70ee8 | ||
|
|
d7d0ceb90d | ||
|
|
82d67af60d | ||
|
|
48dcc43488 | ||
|
|
304d97933f | ||
|
|
fc4761a07c | ||
|
|
50377b5bf2 | ||
|
|
735f930bac | ||
|
|
9b829c92b5 | ||
|
|
914de05bf5 | ||
|
|
e92ea13bff | ||
|
|
1433dec2d0 | ||
|
|
0fc8e6af0a | ||
|
|
4411641b1e | ||
|
|
8708b13d62 | ||
|
|
6a299514f8 | ||
|
|
0fbb421ec1 | ||
|
|
fd4a7388d7 | ||
|
|
c0e87e9bb1 | ||
|
|
9d08f09e06 | ||
|
|
bc1c2b3b31 | ||
|
|
a23bcba875 | ||
|
|
8738e6d86f | ||
|
|
58b754ca4a | ||
|
|
b97156113e | ||
|
|
98d929290c | ||
|
|
fa1802381f | ||
|
|
2f707bf246 | ||
|
|
9a5944d960 | ||
|
|
35b8f57906 | ||
|
|
8e29235b6c | ||
|
|
ad4f0c7812 | ||
|
|
d439b3970a | ||
|
|
90c5689b59 | ||
|
|
6eaf57eb3c | ||
|
|
1dafdaa31b | ||
|
|
78265a44c5 | ||
|
|
c786c30108 | ||
|
|
b260cb92e4 | ||
|
|
6b6a4e466a | ||
|
|
21fd125343 | ||
|
|
912be12432 | ||
|
|
e3ebe995c9 | ||
|
|
d81d61fcc4 | ||
|
|
01a13bb8c1 | ||
|
|
9adfcea241 | ||
|
|
ecf95a4cc5 | ||
|
|
44ff944b37 | ||
|
|
5a420c8680 | ||
|
|
de3b9bc77c | ||
|
|
0cb38a3d26 | ||
|
|
406d5a5ecc | ||
|
|
e51ddf9dc8 | ||
|
|
8f11f7f179 | ||
|
|
f0c85fab45 | ||
|
|
b0415856fd | ||
|
|
9e309a2d10 | ||
|
|
a7f0465c0b | ||
|
|
f4912e3a96 | ||
|
|
48cc47d55a | ||
|
|
a87233f98a | ||
|
|
c23a1f78b4 | ||
|
|
7cd702640d | ||
|
|
df484b0008 | ||
|
|
f8148a3905 | ||
|
|
86c806a36e | ||
|
|
1acee05579 | ||
|
|
cb9000f15e | ||
|
|
52611a2c7e | ||
|
|
508738251f | ||
|
|
2e0a960e97 | ||
|
|
065c8e77e2 | ||
|
|
f65e652f9f | ||
|
|
0eb519de66 | ||
|
|
f92eba241e | ||
|
|
77cdda452d | ||
|
|
38574614c5 | ||
|
|
0d65cd50dd | ||
|
|
b6ef87f803 | ||
|
|
a1193b23b6 | ||
|
|
609efa2623 | ||
|
|
7fa9032d0b | ||
|
|
be5b98ef0d | ||
|
|
98f3c410d9 | ||
|
|
fe451e9a72 | ||
|
|
e7a6d0b163 | ||
|
|
45d399b96e | ||
|
|
fca64efd62 | ||
|
|
bc68ab8b57 | ||
|
|
a3cb536d24 | ||
|
|
42a35c9b8b | ||
|
|
e9f2de918d | ||
|
|
3baad45b21 | ||
|
|
b64ac1faa3 | ||
|
|
9960ecc5cd | ||
|
|
dd7c33d0c9 | ||
|
|
0d61202427 | ||
|
|
ccd1babbfc | ||
|
|
bbdcbbdba5 | ||
|
|
9c036b13f9 | ||
|
|
1d65e8f135 | ||
|
|
8b83b48e98 | ||
|
|
34a55790f2 | ||
|
|
854c9abcd4 | ||
|
|
b3ce714cbf | ||
|
|
36a3011613 | ||
|
|
704b24d048 | ||
|
|
7f0d637de4 | ||
|
|
e09e45eb86 | ||
|
|
6f2d32fd1f | ||
|
|
bccead024d | ||
|
|
b2ca20312d | ||
|
|
b41a2755c4 | ||
|
|
e68792dbb2 | ||
|
|
a833f7d460 | ||
|
|
9e3551ba1f | ||
|
|
f046189e34 | ||
|
|
b93f8e6277 | ||
|
|
5a282136a3 | ||
|
|
3e4e173296 | ||
|
|
a37ff1fa4b | ||
|
|
6cf46f49e3 | ||
|
|
b6f76adef4 | ||
|
|
b8525baecf | ||
|
|
91cb087727 | ||
|
|
fac240b5d1 | ||
|
|
7e01935dc2 | ||
|
|
90d4ae4da8 | ||
|
|
43cb6ba763 | ||
|
|
8f097fb466 | ||
|
|
6357cdaecf | ||
|
|
4c13992f0d | ||
|
|
911ba0293a | ||
|
|
308edceb51 | ||
|
|
0d506131af | ||
|
|
d17b684b91 | ||
|
|
117955daf6 | ||
|
|
1d93f396bb | ||
|
|
a90a93f1a4 |
No files matched your search
@@ -1,130 +1,11 @@
|
||||
PHP NEWS
|
||||
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
||||
?? ??? 2014, PHP 5.6.0 Alpha 2
|
||||
- mysqli
|
||||
. Added new function mysqli_get_links_stats() as well as new INI variable
|
||||
mysqli.rollback_on_cached_plink of type bool (Andrey)
|
||||
?? ??? 20??, PHP 5.7.0
|
||||
|
||||
- PCRE:
|
||||
. Upgraded to PCRE 8.34. (Anatol)
|
||||
- DBA:
|
||||
. Fixed bug #62490 (dba_delete returns true on missing item (inifile)). (Mike)
|
||||
|
||||
|
||||
23 Jan 2014, PHP 5.6.0 Alpha 1
|
||||
- CLI server:
|
||||
. Added some MIME types to the CLI web server. (Chris Jones)
|
||||
|
||||
- Core:
|
||||
. Improved IS_VAR operands fetching. (Laruence, Dmitry)
|
||||
. Improved empty string handling. Now ZE uses an interned string instead of
|
||||
allocation new empty string each time. (Laruence, Dmitry)
|
||||
. Implemented internal operator overloading
|
||||
(RFC: https://wiki.php.net/rfc/operator_overloading_gmp). (Nikita)
|
||||
. Made calls from incompatible context issue an E_DEPRECATED warning instead
|
||||
of E_STRICT (phase 1 of RFC: https://wiki.php.net/rfc/incompat_ctx).
|
||||
(Gustavo)
|
||||
. Uploads equal or greater than 2GB in size are now accepted.
|
||||
(Ralf Lang, Mike)
|
||||
. Reduced POST data memory usage by 200-300%. Changed INI setting
|
||||
always_populate_raw_post_data to throw a deprecation warning when enabling
|
||||
and to accept -1 for never populating the $HTTP_RAW_POST_DATA global
|
||||
variable, which will be the default in future PHP versions. (Mike)
|
||||
. Implemented dedicated syntax for variadic functions
|
||||
(RFC: https://wiki.php.net/rfc/variadics). (Nikita)
|
||||
. Fixed bug #50333 Improving multi-threaded scalability by using
|
||||
emalloc/efree/estrdup (Anatol, Dmitry)
|
||||
. Implemented constant scalar expressions (with support for constants)
|
||||
(RFC: https://wiki.php.net/rfc/const_scalar_exprs). (Bob)
|
||||
. Fixed bug #65784 (Segfault with finally). (Laruence, Dmitry)
|
||||
. Fixed bug #66509 (copy() arginfo has changed starting from 5.4). (willfitch)
|
||||
|
||||
- cURL:
|
||||
. Implemented FR #65646 (re-enable CURLOPT_FOLLOWLOCATION with open_basedir
|
||||
or safe_mode). (Adam)
|
||||
|
||||
- GMP:
|
||||
. Moved GMP to use object as the underlying structure and implemented various
|
||||
improvements based on this.
|
||||
(RFC: https://wiki.php.net/rfc/operator_overloading_gmp). (Nikita)
|
||||
. Added gmp_root() and gmp_rootrem() functions for calculating nth roots.
|
||||
(Nikita)
|
||||
|
||||
- Hash:
|
||||
. Added gost-crypto (CryptoPro S-box) GOST hash algo. (Manuel Mausz)
|
||||
|
||||
- JSON:
|
||||
. Fixed case part of bug #64874 ("json_decode handles whitespace and
|
||||
case-sensitivity incorrectly")
|
||||
|
||||
- mysqlnd:
|
||||
. Disabled flag for SP OUT variables for 5.5+ servers as they are not natively
|
||||
supported by the overlying APIs. (Andrey)
|
||||
|
||||
- OPcache:
|
||||
. Added an optimization of class constants and constant calls to some
|
||||
internal functions (Laruence, Dmitry)
|
||||
. Added an optimization pass to convert FCALL_BY_NAME into DO_FCALL.
|
||||
(Laruence, Dmitry)
|
||||
. Added an optimization pass to merged identical constants (and related
|
||||
cache_slots) in op_array->literals table. (Laruence, Dmitry)
|
||||
. Added script level constant replacement optimization pass. (Dmitry)
|
||||
|
||||
- Openssl:
|
||||
. Added crypto_method option for the ssl stream context. (Martin Jansen)
|
||||
. Added certificate fingerprint support. (Tjerk Meesters)
|
||||
. Added explicit TLSv1.1 and TLSv1.2 stream transports. (Daniel Lowrey)
|
||||
. Fixed bug #65729 (CN_match gives false positive). (Tjerk Meesters)
|
||||
. Peer name verification matches SAN DNS names for certs using
|
||||
the Subject Alternative Name x509 extension. (Daniel Lowrey)
|
||||
. Fixed segfault when built against OpenSSL>=1.0.1 (Daniel Lowrey)
|
||||
. Peer certificates now verified by default in client socket operations
|
||||
(RFC: https://wiki.php.net/rfc/tls-peer-verification). (Daniel Lowrey)
|
||||
. Added SPKAC support. (Jason Gerfen)
|
||||
|
||||
- PDO_pgsql:
|
||||
. Fixed Bug #42614 (PDO_pgsql: add pg_get_notify support). (Matteo)
|
||||
. Fixed Bug #63657 (pgsqlCopyFromFile, pgsqlCopyToArray use Postgres < 7.3
|
||||
syntax). (Matteo)
|
||||
|
||||
- phpdbg:
|
||||
. Included phpdbg sapi (RFC: https://wiki.php.net/rfc/phpdbg).
|
||||
(Felipe Pena, Joe Watkins and Bob Weinand)
|
||||
|
||||
- pgsql:
|
||||
. pg_version() returns full report which obtained by PQparameterStatus().
|
||||
(Yasuo)
|
||||
. Added pg_lo_truncate(). (Yasuo)
|
||||
. Added 64bit large object support for PostgreSQL 9.3 and later. (Yasuo)
|
||||
|
||||
- Session:
|
||||
. Fixed Bug #65315 (session.hash_function silently fallback to default md5)
|
||||
(Yasuo)
|
||||
. Implemented Request #54649 (Create session_serializer_name()). (Yasuo)
|
||||
. Implemented Request #17860 (Session write short circuit). (Yasuo)
|
||||
. Implemented Request #20421 (session_abort() and session_reset() function).
|
||||
(Yasuo)
|
||||
. Implemented Request #11100 (session_gc() function). (Yasuo)
|
||||
|
||||
- Standard:
|
||||
. Implemented FR #65634 (HTTP wrapper is very slow with protocol_version
|
||||
1.1). (Adam)
|
||||
. Implemented Change crypt() behavior w/o salt RFC. (Yasuo)
|
||||
https://wiki.php.net/rfc/crypt_function_salt
|
||||
. Implemented request #49824 (Change array_fill() to allow creating empty
|
||||
array). (Nikita)
|
||||
|
||||
- XMLReader:
|
||||
. Fixed bug #55285 (XMLReader::getAttribute/No/Ns methods inconsistency).
|
||||
(Mike)
|
||||
|
||||
- Zip:
|
||||
. update libzip to version 1.11.2.
|
||||
PHP don't use any ilibzip private symbol anymore. (Pierre, Remi)
|
||||
. new method ZipArchive::setPassword($password). (Pierre)
|
||||
. add --with-libzip option to build with system libzip. (Remi)
|
||||
. new methods:
|
||||
ZipArchive::setExternalAttributesName($name, $opsys, $attr [, $flags])
|
||||
ZipArchive::setExternalAttributesIndex($idx, $opsys, $attr [, $flags])
|
||||
ZipArchive::getExternalAttributesName($name, &$opsys, &$attr [, $flags])
|
||||
ZipArchive::getExternalAttributesIndex($idx, &$opsys, &$attr [, $flags])
|
||||
- XSL:
|
||||
. Fixed bug #64776 (The XSLT extension is not thread safe). (Mike)
|
||||
|
||||
<<< NOTE: Insert NEWS from last stable release here prior to actual release! >>>
|
||||
@@ -20,103 +20,34 @@ PHP X.Y UPGRADE NOTES
|
||||
1. Backward Incompatible Changes
|
||||
========================================
|
||||
|
||||
- JSON:
|
||||
json_decode() no longer accepts non-lowercase variants of lone JSON true,
|
||||
false or null values. For example, True or FALSE will now cause json_decode to
|
||||
return NULL and set an error value you can fetch with json_last_error().
|
||||
This affects JSON texts consisting solely of true, false or null. Text
|
||||
containing non-lowercase values inside JSON arrays or objects has never been
|
||||
accepted.
|
||||
|
||||
- openssl:
|
||||
To prevent Man-in-the-Middle attacks against encrypted transfers client
|
||||
streams now verify peer certificates by default. Previous versions
|
||||
required users to manually enable peer verification. As a result of this
|
||||
change, existing code using ssl:// or tls:// stream wrappers (e.g.
|
||||
file_get_contents(), fsockopen(), stream_socket_client()) may no longer
|
||||
connect successfully without manually disabling peer verification via the
|
||||
stream context's "verify_peer" setting. Encrypted transfers delegate to
|
||||
operating system certificate stores by default, so many/most users *should*
|
||||
be unaffected by this transparent security enhancement.
|
||||
- DBA
|
||||
. dba_delete() now returns false if the key was not found for the inifile
|
||||
handler, too.
|
||||
|
||||
========================================
|
||||
2. New Features
|
||||
========================================
|
||||
|
||||
- Added constant scalar expressions syntax
|
||||
(https://wiki.php.net/rfc/const_scalar_exprs)
|
||||
|
||||
- Added dedicated syntax for variadic functions.
|
||||
(https://wiki.php.net/rfc/variadics)
|
||||
|
||||
- Added support for argument unpacking to complement the variadic syntax.
|
||||
(https://wiki.php.net/rfc/argument_unpacking)
|
||||
|
||||
- The php://input stream is now re-usable and can be used concurrently with
|
||||
enable_post_data_reading=0.
|
||||
|
||||
- Added gost-crypto (CryptoPro S-box) hash algo.
|
||||
|
||||
- Added openssl certificate fingerprint support (inclusive stream context
|
||||
option).
|
||||
|
||||
- Added openssl crypto method stream context option.
|
||||
|
||||
- Added openssl peer verification support for SAN x509 extension
|
||||
|
||||
- Added use function and use const.
|
||||
(https://wiki.php.net/rfc/use_function)
|
||||
|
||||
========================================
|
||||
2. Changes in SAPI modules
|
||||
========================================
|
||||
|
||||
- Added phpdbg sapi.
|
||||
(https://wiki.php.net/rfc/phpdbg)
|
||||
|
||||
========================================
|
||||
3. Deprecated Functionality
|
||||
========================================
|
||||
|
||||
- Incompatible context calls:
|
||||
Instance calls from an incompatible context are now deprecated and issue
|
||||
E_DEPRECATED instead of E_STRICT. See https://wiki.php.net/rfc/incompat_ctx
|
||||
|
||||
========================================
|
||||
4. Changed Functions
|
||||
========================================
|
||||
|
||||
- cURL:
|
||||
CURLOPT_SAFE_UPLOAD is now turned on by default and uploads with @file
|
||||
do not work unless it is explicitly set to false.
|
||||
|
||||
- Crypt:
|
||||
crypt() will now raise an E_NOTICE error if the salt parameter is omitted.
|
||||
See: https://wiki.php.net/rfc/crypt_function_salt
|
||||
|
||||
- XMLReader:
|
||||
XMLReader::getAttributeNs and XMLReader::getAttributeNo now return NULL if
|
||||
the attribute could not be found, just like XMLReader::getAttribute.
|
||||
|
||||
========================================
|
||||
5. New Functions
|
||||
========================================
|
||||
|
||||
- GMP:
|
||||
Added gmp_root($a, $nth) and gmp_rootrem($a, $nth) for calculating nth roots.
|
||||
|
||||
- Openssl:
|
||||
Added string openssl_x509_fingerprint($x509, $type, $binary).
|
||||
Added string openssl_spki_new($private_key, $challenge, $algorithm)
|
||||
Added bool openssl_spki_verify($spkac)
|
||||
Added string openssl_spki_export($spkac)
|
||||
Added string openssl_spki_export_challenge($spkac)
|
||||
|
||||
- LDAP:
|
||||
Added ldap_escape($value, $ignore = "", $flags = 0).
|
||||
|
||||
- Zip:
|
||||
Added ZipArchive::setPassword($password)
|
||||
|
||||
========================================
|
||||
6. New Classes and Interfaces
|
||||
@@ -132,50 +63,18 @@ PHP X.Y UPGRADE NOTES
|
||||
8. Other Changes to Extensions
|
||||
========================================
|
||||
|
||||
- GMP:
|
||||
The GMP extension now uses objects as the underlying data structure, rather
|
||||
than resources. GMP instances now support dumping, serialization, cloning,
|
||||
casts to primitive types and have overloaded operators.
|
||||
(RFC: https://wiki.php.net/rfc/operator_overloading_gmp)
|
||||
|
||||
- OCI8:
|
||||
- Added Implicit Result Set support for Oracle Database 12c with a
|
||||
new oci_get_implicit_resultset() function.
|
||||
- Using 'oci_execute($s, OCI_NO_AUTO_COMMIT)' for a SELECT no longer
|
||||
unnecessarily initiates an internal ROLLBACK during connection
|
||||
close.
|
||||
- Added DTrace probes enabled with PHP's generic --enable-dtrace
|
||||
- The oci_internal_debug() function is now a no-op.
|
||||
- The phpinfo() output format for OCI8 has changed.
|
||||
|
||||
========================================
|
||||
9. New Global Constants
|
||||
========================================
|
||||
|
||||
- LDAP:
|
||||
LDAP_ESCAPE_FILTER int(1)
|
||||
LDAP_ESCAPE_DN int(2)
|
||||
|
||||
========================================
|
||||
10. Changes to INI File Handling
|
||||
========================================
|
||||
|
||||
- Core:
|
||||
Changed always_populate_raw_post_data to throw a deprecation warning when
|
||||
enabled and to recognize ohe value -1 for never populating the global
|
||||
$HTTP_RAW_POST_DATA variable, which will be default in future PHP versions.
|
||||
|
||||
========================================
|
||||
11. Other Changes
|
||||
========================================
|
||||
|
||||
- File upload:
|
||||
Uploads equal or greater than 2GB in size are now accepted.
|
||||
|
||||
- HTTP stream wrapper:
|
||||
HTTP 1.1 requests now include a Connection: close header unless explicitly
|
||||
overridden by setting a Connection header via the header context option.
|
||||
|
||||
- Zip:
|
||||
New --with-libzip option allow to use system libzip. Version > 0.11 required,
|
||||
Version >= 0.11.2 recommended for all features.
|
||||
+1
-98
@@ -17,108 +17,11 @@ UPGRADE NOTES - PHP X.Y
|
||||
1. Internal API changes
|
||||
========================
|
||||
|
||||
a. Addition of do_operation and compare object handlers
|
||||
a. zend_set_memory_limit() now takes the TSRMLS_CC macro as its last argument
|
||||
|
||||
Two new object handlers have been added:
|
||||
|
||||
do_operation:
|
||||
typedef int (*zend_object_do_operation_t)(
|
||||
zend_uchar opcode, zval *result, zval *op1, zval *op2 TSRMLS_DC
|
||||
);
|
||||
|
||||
compare:
|
||||
typedef int (*zend_object_compare_zvals_t)(
|
||||
zval *result, zval *op1, zval *op2 TSRMLS_DC
|
||||
);
|
||||
|
||||
The first handler is used to overload arithmetic operations. The first
|
||||
argument specifies the opcode of the operator, result is the target zval,
|
||||
op1 the first operand and op2 the second operand. For unary operations
|
||||
op2 is NULL. If the handler returns FAILURE PHP falls back to the default
|
||||
behavior for the operation.
|
||||
|
||||
The second handler is used to perform comparison operations with
|
||||
non-objects. The value written into result must be an IS_LONG with value
|
||||
-1 (smaller), 0 (equal) or 1 (greater). The return value is a SUCCESS/FAILURE
|
||||
return code. The difference between this handler and compare_objects is
|
||||
that it will be triggered for comparisons with non-objects and objects of
|
||||
different types. It takes precedence over compare_objects.
|
||||
|
||||
Further docs in the RFC: https://wiki.php.net/rfc/operator_overloading_gmp
|
||||
|
||||
b. return_value_ptr now always available, RETVAL_ZVAL_FAST macros
|
||||
|
||||
The return_value_ptr argument to internal functions is now always set.
|
||||
Previously it was only available for functions returning by-reference.
|
||||
return_value_ptr can now be used to return zvals without copying them.
|
||||
For this purpose two new macros are provided:
|
||||
|
||||
RETVAL_ZVAL_FAST(zv); /* analog to RETVAL_ZVAL(zv, 1, 0) */
|
||||
RETURN_ZVAL_FAST(zv); /* analog to RETURN_ZVAL(zv, 1, 0) */
|
||||
|
||||
The macros behave similarly to the non-FAST variants with copy=1 and
|
||||
dtor=0, but will try to return the zval without making a copy by utilizing
|
||||
return_value_ptr.
|
||||
|
||||
c. POST data handling
|
||||
|
||||
The sapi_request_info's members post_data, post_data_len and raw_post_data as
|
||||
well as raw_post_data_len have been replaced with a temp PHP stream
|
||||
request_body.
|
||||
|
||||
The recommended way to access raw POST data is to open and use a php://input
|
||||
stream wrapper. It is safe to be used concurrently and more than once.
|
||||
|
||||
d. Arginfo changes
|
||||
|
||||
The pass_rest_by_reference argument of the ZEND_BEGIN_ARG_INFO and
|
||||
ZEND_BEGIN_ARG_INFO_EX() is no longer used. The value passed to it is ignored.
|
||||
|
||||
Instead a variadic argument is created using ZEND_ARG_VARIADIC_INFO():
|
||||
|
||||
ZEND_ARG_VARIADIC_INFO(0, name) /* pass rest by value */
|
||||
ZEND_ARG_VARIADIC_INFO(1, name) /* pass rest by reference */
|
||||
ZEND_ARG_VARIADIC_INFO(ZEND_SEND_PREFER_REF, name)
|
||||
/* pass rest by prefer-ref */
|
||||
|
||||
ZEND_ARG_VARIADIC_INFO() should only be used for the last argument.
|
||||
|
||||
The following changes were applied to the zend_arg_info struct:
|
||||
|
||||
typedef struct _zend_arg_info {
|
||||
const char *class_name;
|
||||
zend_uint class_name_len;
|
||||
zend_uchar type_hint;
|
||||
+ zend_uchar pass_by_reference;
|
||||
zend_bool allow_null;
|
||||
- zend_bool pass_by_reference;
|
||||
+ zend_bool is_variadic;
|
||||
} zend_arg_info;
|
||||
|
||||
The following changes were applied to the zend_internal_function_info struct:
|
||||
|
||||
typedef struct _zend_internal_function_info {
|
||||
zend_uint required_num_args;
|
||||
zend_uchar _type_hint;
|
||||
zend_bool return_reference;
|
||||
- zend_bool pass_rest_by_reference;
|
||||
+ zend_bool _allow_null;
|
||||
+ zend_bool _is_variadic;
|
||||
} zend_internal_function_info;
|
||||
|
||||
The CHECK_ARG_SEND_TYPE(), ARG_MUST_BE_SENT_BY_REF(),
|
||||
ARG_SHOULD_BE_SENT_BY_REF() and ARG_MAY_BE_SENT_BY_REF() macros now assume
|
||||
that the argument passed to them is a zend_function* and that it is non-NULL.
|
||||
|
||||
========================
|
||||
2. Build system changes
|
||||
========================
|
||||
|
||||
a. Unix build system changes
|
||||
- The bison version check is now a blacklist instead of a whitelist.
|
||||
- The bison binary can be specified through the YACC environment/configure
|
||||
variable. Previously `bison` was assumed to be in $PATH.
|
||||
|
||||
b. Windows build system changes
|
||||
-
|
||||
|
||||
+1
-1
@@ -52,7 +52,7 @@ ZEND_API FILE *(*zend_fopen)(const char *filename, char **opened_path TSRMLS_DC)
|
||||
ZEND_API int (*zend_stream_open_function)(const char *filename, zend_file_handle *handle TSRMLS_DC);
|
||||
ZEND_API void (*zend_block_interruptions)(void);
|
||||
ZEND_API void (*zend_unblock_interruptions)(void);
|
||||
ZEND_API void (*zend_ticks_function)(int ticks);
|
||||
ZEND_API void (*zend_ticks_function)(int ticks TSRMLS_DC);
|
||||
ZEND_API void (*zend_error_cb)(int type, const char *error_filename, const uint error_lineno, const char *format, va_list args);
|
||||
int (*zend_vspprintf)(char **pbuf, size_t max_len, const char *format, va_list ap);
|
||||
ZEND_API char *(*zend_getenv)(char *name, size_t name_len TSRMLS_DC);
|
||||
|
||||
+3
-3
@@ -22,7 +22,7 @@
|
||||
#ifndef ZEND_H
|
||||
#define ZEND_H
|
||||
|
||||
#define ZEND_VERSION "2.6.0-dev"
|
||||
#define ZEND_VERSION "2.7.0-dev"
|
||||
|
||||
#define ZEND_ENGINE_2
|
||||
|
||||
@@ -550,7 +550,7 @@ typedef struct _zend_utility_functions {
|
||||
void (*block_interruptions)(void);
|
||||
void (*unblock_interruptions)(void);
|
||||
int (*get_configuration_directive)(const char *name, uint name_length, zval *contents);
|
||||
void (*ticks_function)(int ticks);
|
||||
void (*ticks_function)(int ticks TSRMLS_DC);
|
||||
void (*on_timeout)(int seconds TSRMLS_DC);
|
||||
int (*stream_open_function)(const char *filename, zend_file_handle *handle TSRMLS_DC);
|
||||
int (*vspprintf_function)(char **pbuf, size_t max_len, const char *format, va_list ap);
|
||||
@@ -702,7 +702,7 @@ extern ZEND_API zend_write_func_t zend_write;
|
||||
extern ZEND_API FILE *(*zend_fopen)(const char *filename, char **opened_path TSRMLS_DC);
|
||||
extern ZEND_API void (*zend_block_interruptions)(void);
|
||||
extern ZEND_API void (*zend_unblock_interruptions)(void);
|
||||
extern ZEND_API void (*zend_ticks_function)(int ticks);
|
||||
extern ZEND_API void (*zend_ticks_function)(int ticks TSRMLS_DC);
|
||||
extern ZEND_API void (*zend_error_cb)(int type, const char *error_filename, const uint error_lineno, const char *format, va_list args) ZEND_ATTRIBUTE_PTR_FORMAT(printf, 4, 0);
|
||||
extern ZEND_API void (*zend_on_timeout)(int seconds TSRMLS_DC);
|
||||
extern ZEND_API int (*zend_stream_open_function)(const char *filename, zend_file_handle *handle TSRMLS_DC);
|
||||
|
||||
+1
-3
@@ -2313,10 +2313,8 @@ ZEND_API void zend_unregister_functions(const zend_function_entry *functions, in
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
ZEND_API int zend_startup_module(zend_module_entry *module) /* {{{ */
|
||||
ZEND_API int zend_startup_module(zend_module_entry *module TSRMLS_DC) /* {{{ */
|
||||
{
|
||||
TSRMLS_FETCH();
|
||||
|
||||
if ((module = zend_register_internal_module(module TSRMLS_CC)) != NULL && zend_startup_module_ex(module TSRMLS_CC) == SUCCESS) {
|
||||
return SUCCESS;
|
||||
}
|
||||
|
||||
+1
-1
@@ -266,7 +266,7 @@ ZEND_API int zend_parse_parameter(int flags, int arg_num TSRMLS_DC, zval **arg,
|
||||
|
||||
ZEND_API int zend_register_functions(zend_class_entry *scope, const zend_function_entry *functions, HashTable *function_table, int type TSRMLS_DC);
|
||||
ZEND_API void zend_unregister_functions(const zend_function_entry *functions, int count, HashTable *function_table TSRMLS_DC);
|
||||
ZEND_API int zend_startup_module(zend_module_entry *module_entry);
|
||||
ZEND_API int zend_startup_module(zend_module_entry *module_entry TSRMLS_DC);
|
||||
ZEND_API zend_module_entry* zend_register_internal_module(zend_module_entry *module_entry TSRMLS_DC);
|
||||
ZEND_API zend_module_entry* zend_register_module_ex(zend_module_entry *module TSRMLS_DC);
|
||||
ZEND_API int zend_startup_module_ex(zend_module_entry *module TSRMLS_DC);
|
||||
|
||||
+1
-3
@@ -2682,10 +2682,8 @@ ZEND_API char *zend_strndup(const char *s, uint length)
|
||||
}
|
||||
|
||||
|
||||
ZEND_API int zend_set_memory_limit(size_t memory_limit)
|
||||
ZEND_API int zend_set_memory_limit(size_t memory_limit TSRMLS_DC)
|
||||
{
|
||||
TSRMLS_FETCH();
|
||||
|
||||
AG(mm_heap)->limit = (memory_limit >= AG(mm_heap)->block_size) ? memory_limit : AG(mm_heap)->block_size;
|
||||
|
||||
return SUCCESS;
|
||||
|
||||
+1
-1
@@ -139,7 +139,7 @@ inline static void * __zend_realloc(void *p, size_t len)
|
||||
#define safe_estrdup(ptr) ((ptr)?(estrdup(ptr)):STR_EMPTY_ALLOC())
|
||||
#define safe_estrndup(ptr, len) ((ptr)?(estrndup((ptr), (len))):STR_EMPTY_ALLOC())
|
||||
|
||||
ZEND_API int zend_set_memory_limit(size_t memory_limit);
|
||||
ZEND_API int zend_set_memory_limit(size_t memory_limit TSRMLS_DC);
|
||||
|
||||
ZEND_API void start_memory_manager(TSRMLS_D);
|
||||
ZEND_API void shutdown_memory_manager(int silent, int full_shutdown TSRMLS_DC);
|
||||
|
||||
+5
-5
@@ -231,9 +231,9 @@ ZEND_API void zend_ast_evaluate(zval *result, zend_ast *ast, zend_class_entry *s
|
||||
break;
|
||||
case ZEND_BOOL_AND:
|
||||
zend_ast_evaluate(&op1, (&ast->u.child)[0], scope TSRMLS_CC);
|
||||
if (zend_is_true(&op1)) {
|
||||
if (zend_is_true(&op1 TSRMLS_CC)) {
|
||||
zend_ast_evaluate(&op2, (&ast->u.child)[1], scope TSRMLS_CC);
|
||||
ZVAL_BOOL(result, zend_is_true(&op2));
|
||||
ZVAL_BOOL(result, zend_is_true(&op2 TSRMLS_CC));
|
||||
zval_dtor(&op2);
|
||||
} else {
|
||||
ZVAL_BOOL(result, 0);
|
||||
@@ -242,18 +242,18 @@ ZEND_API void zend_ast_evaluate(zval *result, zend_ast *ast, zend_class_entry *s
|
||||
break;
|
||||
case ZEND_BOOL_OR:
|
||||
zend_ast_evaluate(&op1, (&ast->u.child)[0], scope TSRMLS_CC);
|
||||
if (zend_is_true(&op1)) {
|
||||
if (zend_is_true(&op1 TSRMLS_CC)) {
|
||||
ZVAL_BOOL(result, 1);
|
||||
} else {
|
||||
zend_ast_evaluate(&op2, (&ast->u.child)[1], scope TSRMLS_CC);
|
||||
ZVAL_BOOL(result, zend_is_true(&op2));
|
||||
ZVAL_BOOL(result, zend_is_true(&op2 TSRMLS_CC));
|
||||
zval_dtor(&op2);
|
||||
}
|
||||
zval_dtor(&op1);
|
||||
break;
|
||||
case ZEND_SELECT:
|
||||
zend_ast_evaluate(&op1, (&ast->u.child)[0], scope TSRMLS_CC);
|
||||
if (zend_is_true(&op1)) {
|
||||
if (zend_is_true(&op1 TSRMLS_CC)) {
|
||||
if (!(&ast->u.child)[1]) {
|
||||
*result = op1;
|
||||
} else {
|
||||
|
||||
+2
-4
@@ -60,7 +60,7 @@ ZEND_API zend_execute_data *zend_create_execute_data_from_op_array(zend_op_array
|
||||
ZEND_API void zend_execute(zend_op_array *op_array TSRMLS_DC);
|
||||
ZEND_API void execute_ex(zend_execute_data *execute_data TSRMLS_DC);
|
||||
ZEND_API void execute_internal(zend_execute_data *execute_data_ptr, struct _zend_fcall_info *fci, int return_value_used TSRMLS_DC);
|
||||
ZEND_API int zend_is_true(zval *op);
|
||||
ZEND_API int zend_is_true(zval *op TSRMLS_DC);
|
||||
ZEND_API int zend_lookup_class(const char *name, int name_length, zend_class_entry ***ce TSRMLS_DC);
|
||||
ZEND_API int zend_lookup_class_ex(const char *name, int name_length, const zend_literal *key, int use_autoload, zend_class_entry ***ce TSRMLS_DC);
|
||||
ZEND_API int zend_eval_string(char *str, zval *retval_ptr, char *string_name TSRMLS_DC);
|
||||
@@ -101,7 +101,7 @@ static zend_always_inline void i_zval_ptr_dtor_nogc(zval *zval_ptr ZEND_FILE_LIN
|
||||
}
|
||||
}
|
||||
|
||||
static zend_always_inline int i_zend_is_true(zval *op)
|
||||
static zend_always_inline int i_zend_is_true(zval *op TSRMLS_DC)
|
||||
{
|
||||
int result;
|
||||
|
||||
@@ -130,8 +130,6 @@ static zend_always_inline int i_zend_is_true(zval *op)
|
||||
break;
|
||||
case IS_OBJECT:
|
||||
if(IS_ZEND_STD_OBJECT(*op)) {
|
||||
TSRMLS_FETCH();
|
||||
|
||||
if (Z_OBJ_HT_P(op)->cast_object) {
|
||||
zval tmp;
|
||||
if (Z_OBJ_HT_P(op)->cast_object(op, &tmp, IS_BOOL TSRMLS_CC) == SUCCESS) {
|
||||
|
||||
@@ -443,9 +443,9 @@ ZEND_API void _zval_internal_ptr_dtor(zval **zval_ptr ZEND_FILE_LINE_DC) /* {{{
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
ZEND_API int zend_is_true(zval *op) /* {{{ */
|
||||
ZEND_API int zend_is_true(zval *op TSRMLS_DC) /* {{{ */
|
||||
{
|
||||
return i_zend_is_true(op);
|
||||
return i_zend_is_true(op TSRMLS_CC);
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
|
||||
@@ -24,7 +24,7 @@
|
||||
ZEND_API zend_llist zend_extensions;
|
||||
static int last_resource_number;
|
||||
|
||||
int zend_load_extension(const char *path)
|
||||
int zend_load_extension(const char *path TSRMLS_DC)
|
||||
{
|
||||
#if ZEND_EXTENSIONS_SUPPORT
|
||||
DL_HANDLE handle;
|
||||
@@ -107,7 +107,7 @@ int zend_load_extension(const char *path)
|
||||
return FAILURE;
|
||||
}
|
||||
|
||||
return zend_register_extension(new_extension, handle);
|
||||
return zend_register_extension(new_extension, handle TSRMLS_CC);
|
||||
#else
|
||||
fprintf(stderr, "Extensions are not supported on this platform.\n");
|
||||
/* See http://support.microsoft.com/kb/190351 */
|
||||
@@ -119,7 +119,7 @@ int zend_load_extension(const char *path)
|
||||
}
|
||||
|
||||
|
||||
int zend_register_extension(zend_extension *new_extension, DL_HANDLE handle)
|
||||
int zend_register_extension(zend_extension *new_extension, DL_HANDLE handle TSRMLS_DC)
|
||||
{
|
||||
#if ZEND_EXTENSIONS_SUPPORT
|
||||
zend_extension extension;
|
||||
@@ -127,7 +127,7 @@ int zend_register_extension(zend_extension *new_extension, DL_HANDLE handle)
|
||||
extension = *new_extension;
|
||||
extension.handle = handle;
|
||||
|
||||
zend_extension_dispatch_message(ZEND_EXTMSG_NEW_EXTENSION, &extension);
|
||||
zend_extension_dispatch_message(ZEND_EXTMSG_NEW_EXTENSION, &extension TSRMLS_CC);
|
||||
|
||||
zend_llist_add_element(&zend_extensions, &extension);
|
||||
|
||||
@@ -208,10 +208,8 @@ static void zend_extension_message_dispatcher(const zend_extension *extension, i
|
||||
}
|
||||
|
||||
|
||||
ZEND_API void zend_extension_dispatch_message(int message, void *arg)
|
||||
ZEND_API void zend_extension_dispatch_message(int message, void *arg TSRMLS_DC)
|
||||
{
|
||||
TSRMLS_FETCH();
|
||||
|
||||
zend_llist_apply_with_arguments(&zend_extensions, (llist_apply_with_args_func_t) zend_extension_message_dispatcher TSRMLS_CC, 2, message, arg);
|
||||
}
|
||||
|
||||
|
||||
@@ -28,7 +28,7 @@
|
||||
/* The first number is the engine version and the rest is the date.
|
||||
* This way engine 2/3 API no. is always greater than engine 1 API no..
|
||||
*/
|
||||
#define ZEND_EXTENSION_API_NO 220131226
|
||||
#define ZEND_EXTENSION_API_NO 220131227
|
||||
|
||||
typedef struct _zend_extension_version_info {
|
||||
int zend_extension_api_no;
|
||||
@@ -94,7 +94,7 @@ struct _zend_extension {
|
||||
|
||||
BEGIN_EXTERN_C()
|
||||
ZEND_API int zend_get_resource_handle(zend_extension *extension);
|
||||
ZEND_API void zend_extension_dispatch_message(int message, void *arg);
|
||||
ZEND_API void zend_extension_dispatch_message(int message, void *arg TSRMLS_DC);
|
||||
END_EXTERN_C()
|
||||
|
||||
#define ZEND_EXTMSG_NEW_EXTENSION 1
|
||||
@@ -117,8 +117,8 @@ int zend_startup_extensions(void);
|
||||
void zend_shutdown_extensions(TSRMLS_D);
|
||||
|
||||
BEGIN_EXTERN_C()
|
||||
ZEND_API int zend_load_extension(const char *path);
|
||||
ZEND_API int zend_register_extension(zend_extension *new_extension, DL_HANDLE handle);
|
||||
ZEND_API int zend_load_extension(const char *path TSRMLS_DC);
|
||||
ZEND_API int zend_register_extension(zend_extension *new_extension, DL_HANDLE handle TSRMLS_DC);
|
||||
ZEND_API zend_extension *zend_get_extension(const char *extension_name);
|
||||
END_EXTERN_C()
|
||||
|
||||
|
||||
+1
-2
@@ -47,7 +47,7 @@ static void handle_whitespace(int *emit_whitespace)
|
||||
}
|
||||
|
||||
|
||||
ZEND_API void zend_indent()
|
||||
ZEND_API void zend_indent(TSRMLS_D)
|
||||
{
|
||||
zval token;
|
||||
int token_type;
|
||||
@@ -55,7 +55,6 @@ ZEND_API void zend_indent()
|
||||
int nest_level=0;
|
||||
int emit_whitespace[256];
|
||||
int i;
|
||||
TSRMLS_FETCH();
|
||||
|
||||
memset(emit_whitespace, 0, sizeof(int)*256);
|
||||
|
||||
|
||||
+1
-1
@@ -23,7 +23,7 @@
|
||||
#define ZEND_INDENT_H
|
||||
|
||||
BEGIN_EXTERN_C()
|
||||
ZEND_API void zend_indent(void);
|
||||
ZEND_API void zend_indent(TSRMLS_D);
|
||||
END_EXTERN_C()
|
||||
|
||||
#endif /* ZEND_INDENT_H */
|
||||
|
||||
+4663
-4663
File diff suppressed because it is too large.
Load diff
@@ -1,13 +1,13 @@
|
||||
/* Generated by re2c 0.13.5 */
|
||||
#line 3 "Zend/zend_ini_scanner_defs.h"
|
||||
|
||||
enum YYCONDTYPE {
|
||||
yycINITIAL,
|
||||
yycST_OFFSET,
|
||||
yycST_SECTION_VALUE,
|
||||
yycST_VALUE,
|
||||
yycST_SECTION_RAW,
|
||||
yycST_DOUBLE_QUOTES,
|
||||
yycST_VARNAME,
|
||||
yycST_RAW,
|
||||
};
|
||||
/* Generated by re2c 0.13.5 */
|
||||
#line 3 "Zend/zend_ini_scanner_defs.h"
|
||||
|
||||
enum YYCONDTYPE {
|
||||
yycINITIAL,
|
||||
yycST_OFFSET,
|
||||
yycST_SECTION_VALUE,
|
||||
yycST_VALUE,
|
||||
yycST_SECTION_RAW,
|
||||
yycST_DOUBLE_QUOTES,
|
||||
yycST_VARNAME,
|
||||
yycST_RAW,
|
||||
};
|
||||
@@ -162,7 +162,7 @@ ZEND_API int zend_user_it_valid(zend_object_iterator *_iter TSRMLS_DC)
|
||||
|
||||
zend_call_method_with_0_params(&object, iter->ce, &iter->ce->iterator_funcs.zf_valid, "valid", &more);
|
||||
if (more) {
|
||||
result = i_zend_is_true(more);
|
||||
result = i_zend_is_true(more TSRMLS_CC);
|
||||
zval_ptr_dtor(&more);
|
||||
return result ? SUCCESS : FAILURE;
|
||||
}
|
||||
|
||||
@@ -72,7 +72,7 @@ static YYSIZE_T zend_yytnamerr(char*, const char*);
|
||||
%token T_PRINT "print (T_PRINT)"
|
||||
%right T_YIELD
|
||||
%token T_YIELD "yield (T_YIELD)"
|
||||
%left '=' T_PLUS_EQUAL T_MINUS_EQUAL T_MUL_EQUAL T_DIV_EQUAL T_CONCAT_EQUAL T_MOD_EQUAL T_AND_EQUAL T_OR_EQUAL T_XOR_EQUAL T_SL_EQUAL T_SR_EQUAL
|
||||
%left '=' T_PLUS_EQUAL T_MINUS_EQUAL T_MUL_EQUAL T_DIV_EQUAL T_CONCAT_EQUAL T_MOD_EQUAL T_AND_EQUAL T_OR_EQUAL T_XOR_EQUAL T_SL_EQUAL T_SR_EQUAL T_POW_EQUAL
|
||||
%token T_PLUS_EQUAL "+= (T_PLUS_EQUAL)"
|
||||
%token T_MINUS_EQUAL "-= (T_MINUS_EQUAL)"
|
||||
%token T_MUL_EQUAL "*= (T_MUL_EQUAL)"
|
||||
@@ -109,6 +109,7 @@ static YYSIZE_T zend_yytnamerr(char*, const char*);
|
||||
%nonassoc T_INSTANCEOF
|
||||
%token T_INSTANCEOF "instanceof (T_INSTANCEOF)"
|
||||
%right '~' T_INC T_DEC T_INT_CAST T_DOUBLE_CAST T_STRING_CAST T_ARRAY_CAST T_OBJECT_CAST T_BOOL_CAST T_UNSET_CAST '@'
|
||||
%right T_POW
|
||||
%token T_INC "++ (T_INC)"
|
||||
%token T_DEC "-- (T_DEC)"
|
||||
%token T_INT_CAST "(int) (T_INT_CAST)"
|
||||
@@ -213,6 +214,8 @@ static YYSIZE_T zend_yytnamerr(char*, const char*);
|
||||
%token T_DIR "__DIR__ (T_DIR)"
|
||||
%token T_NS_SEPARATOR "\\ (T_NS_SEPARATOR)"
|
||||
%token T_ELLIPSIS "... (T_ELLIPSIS)"
|
||||
%token T_POW "** (T_POW)"
|
||||
%token T_POW_EQUAL "**= (T_POW_EQUAL)"
|
||||
|
||||
%% /* Rules */
|
||||
|
||||
@@ -778,6 +781,7 @@ expr_without_variable:
|
||||
| variable T_PLUS_EQUAL expr { zend_check_writable_variable(&$1); zend_do_end_variable_parse(&$1, BP_VAR_RW, 0 TSRMLS_CC); zend_do_binary_assign_op(ZEND_ASSIGN_ADD, &$$, &$1, &$3 TSRMLS_CC); }
|
||||
| variable T_MINUS_EQUAL expr { zend_check_writable_variable(&$1); zend_do_end_variable_parse(&$1, BP_VAR_RW, 0 TSRMLS_CC); zend_do_binary_assign_op(ZEND_ASSIGN_SUB, &$$, &$1, &$3 TSRMLS_CC); }
|
||||
| variable T_MUL_EQUAL expr { zend_check_writable_variable(&$1); zend_do_end_variable_parse(&$1, BP_VAR_RW, 0 TSRMLS_CC); zend_do_binary_assign_op(ZEND_ASSIGN_MUL, &$$, &$1, &$3 TSRMLS_CC); }
|
||||
| variable T_POW_EQUAL expr { zend_check_writable_variable(&$1); zend_do_end_variable_parse(&$1, BP_VAR_RW, 0 TSRMLS_CC); zend_do_binary_assign_op(ZEND_ASSIGN_POW, &$$, &$1, &$3 TSRMLS_CC); }
|
||||
| variable T_DIV_EQUAL expr { zend_check_writable_variable(&$1); zend_do_end_variable_parse(&$1, BP_VAR_RW, 0 TSRMLS_CC); zend_do_binary_assign_op(ZEND_ASSIGN_DIV, &$$, &$1, &$3 TSRMLS_CC); }
|
||||
| variable T_CONCAT_EQUAL expr { zend_check_writable_variable(&$1); zend_do_end_variable_parse(&$1, BP_VAR_RW, 0 TSRMLS_CC); zend_do_binary_assign_op(ZEND_ASSIGN_CONCAT, &$$, &$1, &$3 TSRMLS_CC); }
|
||||
| variable T_MOD_EQUAL expr { zend_check_writable_variable(&$1); zend_do_end_variable_parse(&$1, BP_VAR_RW, 0 TSRMLS_CC); zend_do_binary_assign_op(ZEND_ASSIGN_MOD, &$$, &$1, &$3 TSRMLS_CC); }
|
||||
@@ -802,6 +806,7 @@ expr_without_variable:
|
||||
| expr '+' expr { zend_do_binary_op(ZEND_ADD, &$$, &$1, &$3 TSRMLS_CC); }
|
||||
| expr '-' expr { zend_do_binary_op(ZEND_SUB, &$$, &$1, &$3 TSRMLS_CC); }
|
||||
| expr '*' expr { zend_do_binary_op(ZEND_MUL, &$$, &$1, &$3 TSRMLS_CC); }
|
||||
| expr T_POW expr { zend_do_binary_op(ZEND_POW, &$$, &$1, &$3 TSRMLS_CC); }
|
||||
| expr '/' expr { zend_do_binary_op(ZEND_DIV, &$$, &$1, &$3 TSRMLS_CC); }
|
||||
| expr '%' expr { zend_do_binary_op(ZEND_MOD, &$$, &$1, &$3 TSRMLS_CC); }
|
||||
| expr T_SL expr { zend_do_binary_op(ZEND_SL, &$$, &$1, &$3 TSRMLS_CC); }
|
||||
|
||||
+2324
-2302
File diff suppressed because it is too large.
Load diff
@@ -1383,6 +1383,14 @@ NEWLINE ("\r"|"\n"|"\r\n")
|
||||
return T_MUL_EQUAL;
|
||||
}
|
||||
|
||||
<ST_IN_SCRIPTING>"*\*" {
|
||||
return T_POW;
|
||||
}
|
||||
|
||||
<ST_IN_SCRIPTING>"*\*=" {
|
||||
return T_POW_EQUAL;
|
||||
}
|
||||
|
||||
<ST_IN_SCRIPTING>"/=" {
|
||||
return T_DIV_EQUAL;
|
||||
}
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* Generated by re2c 0.13.5 on Sun Dec 22 13:03:33 2013 */
|
||||
/* Generated by re2c 0.13.5 */
|
||||
#line 3 "Zend/zend_language_scanner_defs.h"
|
||||
|
||||
enum YYCONDTYPE {
|
||||
|
||||
+1
-1
@@ -33,7 +33,7 @@
|
||||
#define ZEND_MODULE_INFO_FUNC_ARGS zend_module_entry *zend_module TSRMLS_DC
|
||||
#define ZEND_MODULE_INFO_FUNC_ARGS_PASSTHRU zend_module TSRMLS_CC
|
||||
|
||||
#define ZEND_MODULE_API_NO 20131226
|
||||
#define ZEND_MODULE_API_NO 20131227
|
||||
#ifdef ZTS
|
||||
#define USING_ZTS 1
|
||||
#else
|
||||
|
||||
@@ -29,6 +29,7 @@
|
||||
#include "zend_interfaces.h"
|
||||
#include "zend_closures.h"
|
||||
#include "zend_compile.h"
|
||||
#include "zend_hash.h"
|
||||
|
||||
#define DEBUG_OBJECT_HANDLERS 0
|
||||
|
||||
@@ -188,7 +189,7 @@ static int zend_std_call_setter(zval *object, zval *member, zval *value TSRMLS_D
|
||||
zval_ptr_dtor(&value);
|
||||
|
||||
if (retval) {
|
||||
result = i_zend_is_true(retval) ? SUCCESS : FAILURE;
|
||||
result = i_zend_is_true(retval TSRMLS_CC) ? SUCCESS : FAILURE;
|
||||
zval_ptr_dtor(&retval);
|
||||
return result;
|
||||
} else {
|
||||
@@ -693,12 +694,12 @@ static int zend_std_has_dimension(zval *object, zval *offset, int check_empty TS
|
||||
SEPARATE_ARG_IF_REF(offset);
|
||||
zend_call_method_with_1_params(&object, ce, NULL, "offsetexists", &retval, offset);
|
||||
if (EXPECTED(retval != NULL)) {
|
||||
result = i_zend_is_true(retval);
|
||||
result = i_zend_is_true(retval TSRMLS_CC);
|
||||
zval_ptr_dtor(&retval);
|
||||
if (check_empty && result && EXPECTED(!EG(exception))) {
|
||||
zend_call_method_with_1_params(&object, ce, NULL, "offsetget", &retval, offset);
|
||||
if (retval) {
|
||||
result = i_zend_is_true(retval);
|
||||
result = i_zend_is_true(retval TSRMLS_CC);
|
||||
zval_ptr_dtor(&retval);
|
||||
}
|
||||
}
|
||||
@@ -1442,7 +1443,7 @@ static int zend_std_has_property(zval *object, zval *member, int has_set_exists,
|
||||
guard->in_isset = 1; /* prevent circular getting */
|
||||
rv = zend_std_call_issetter(object, member TSRMLS_CC);
|
||||
if (rv) {
|
||||
result = zend_is_true(rv);
|
||||
result = zend_is_true(rv TSRMLS_CC);
|
||||
zval_ptr_dtor(&rv);
|
||||
if (has_set_exists && result) {
|
||||
if (EXPECTED(!EG(exception)) && zobj->ce->__get && !guard->in_get) {
|
||||
@@ -1451,7 +1452,7 @@ static int zend_std_has_property(zval *object, zval *member, int has_set_exists,
|
||||
guard->in_get = 0;
|
||||
if (rv) {
|
||||
Z_ADDREF_P(rv);
|
||||
result = i_zend_is_true(rv);
|
||||
result = i_zend_is_true(rv TSRMLS_CC);
|
||||
zval_ptr_dtor(&rv);
|
||||
} else {
|
||||
result = 0;
|
||||
@@ -1470,7 +1471,7 @@ static int zend_std_has_property(zval *object, zval *member, int has_set_exists,
|
||||
result = (Z_TYPE_PP(value) != IS_NULL);
|
||||
break;
|
||||
default:
|
||||
result = zend_is_true(*value);
|
||||
result = zend_is_true(*value TSRMLS_CC);
|
||||
break;
|
||||
case 2:
|
||||
result = 1;
|
||||
|
||||
@@ -768,6 +768,9 @@ ZEND_API binary_op_type get_binary_op(int opcode)
|
||||
case ZEND_ASSIGN_MUL:
|
||||
return (binary_op_type) mul_function;
|
||||
break;
|
||||
case ZEND_POW:
|
||||
return (binary_op_type) pow_function;
|
||||
break;
|
||||
case ZEND_DIV:
|
||||
case ZEND_ASSIGN_DIV:
|
||||
return (binary_op_type) div_function;
|
||||
|
||||
@@ -963,6 +963,87 @@ ZEND_API int mul_function(zval *result, zval *op1, zval *op2 TSRMLS_DC) /* {{{ *
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
ZEND_API int pow_function(zval *result, zval *op1, zval *op2 TSRMLS_DC)
|
||||
{
|
||||
zval op1_copy, op2_copy;
|
||||
int converted = 0;
|
||||
|
||||
while (1) {
|
||||
switch (TYPE_PAIR(Z_TYPE_P(op1), Z_TYPE_P(op2))) {
|
||||
case TYPE_PAIR(IS_LONG, IS_LONG):
|
||||
if (Z_LVAL_P(op2) >= 0) {
|
||||
long l1 = 1, l2 = Z_LVAL_P(op1), i = Z_LVAL_P(op2);
|
||||
|
||||
if (i == 0) {
|
||||
ZVAL_LONG(result, 1L);
|
||||
return SUCCESS;
|
||||
} else if (l2 == 0) {
|
||||
ZVAL_LONG(result, 0);
|
||||
return SUCCESS;
|
||||
}
|
||||
|
||||
while (i >= 1) {
|
||||
long overflow;
|
||||
double dval = 0.0;
|
||||
|
||||
if (i % 2) {
|
||||
--i;
|
||||
ZEND_SIGNED_MULTIPLY_LONG(l1, l2, l1, dval, overflow);
|
||||
if (overflow) {
|
||||
ZVAL_DOUBLE(result, dval * pow(l2, i));
|
||||
return SUCCESS;
|
||||
}
|
||||
} else {
|
||||
i /= 2;
|
||||
ZEND_SIGNED_MULTIPLY_LONG(l2, l2, l2, dval, overflow);
|
||||
if (overflow) {
|
||||
ZVAL_DOUBLE(result, (double)l1 * pow(dval, i));
|
||||
return SUCCESS;
|
||||
}
|
||||
}
|
||||
}
|
||||
/* i == 0 */
|
||||
ZVAL_LONG(result, l1);
|
||||
} else {
|
||||
ZVAL_DOUBLE(result, pow((double)Z_LVAL_P(op1), (double)Z_LVAL_P(op2)));
|
||||
}
|
||||
return SUCCESS;
|
||||
|
||||
case TYPE_PAIR(IS_LONG, IS_DOUBLE):
|
||||
ZVAL_DOUBLE(result, pow((double)Z_LVAL_P(op1), Z_DVAL_P(op2)));
|
||||
return SUCCESS;
|
||||
|
||||
case TYPE_PAIR(IS_DOUBLE, IS_LONG):
|
||||
ZVAL_DOUBLE(result, pow(Z_DVAL_P(op1), (double)Z_LVAL_P(op2)));
|
||||
return SUCCESS;
|
||||
|
||||
case TYPE_PAIR(IS_DOUBLE, IS_DOUBLE):
|
||||
ZVAL_DOUBLE(result, pow(Z_DVAL_P(op1), Z_DVAL_P(op2)));
|
||||
return SUCCESS;
|
||||
|
||||
default:
|
||||
if (!converted) {
|
||||
ZEND_TRY_BINARY_OBJECT_OPERATION(ZEND_POW);
|
||||
|
||||
if (Z_TYPE_P(op1) == IS_ARRAY) {
|
||||
ZVAL_LONG(op1, 0);
|
||||
} else {
|
||||
zendi_convert_scalar_to_number(op1, op1_copy, result);
|
||||
}
|
||||
if (Z_TYPE_P(op2) == IS_ARRAY) {
|
||||
ZVAL_LONG(op2, 0);
|
||||
} else {
|
||||
zendi_convert_scalar_to_number(op2, op2_copy, result);
|
||||
}
|
||||
converted = 1;
|
||||
} else {
|
||||
zend_error(E_ERROR, "Unsupported operand types");
|
||||
return FAILURE;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
ZEND_API int div_function(zval *result, zval *op1, zval *op2 TSRMLS_DC) /* {{{ */
|
||||
{
|
||||
zval op1_copy, op2_copy;
|
||||
|
||||
@@ -47,6 +47,7 @@ BEGIN_EXTERN_C()
|
||||
ZEND_API int add_function(zval *result, zval *op1, zval *op2 TSRMLS_DC);
|
||||
ZEND_API int sub_function(zval *result, zval *op1, zval *op2 TSRMLS_DC);
|
||||
ZEND_API int mul_function(zval *result, zval *op1, zval *op2 TSRMLS_DC);
|
||||
ZEND_API int pow_function(zval *result, zval *op1, zval *op2 TSRMLS_DC);
|
||||
ZEND_API int div_function(zval *result, zval *op1, zval *op2 TSRMLS_DC);
|
||||
ZEND_API int mod_function(zval *result, zval *op1, zval *op2 TSRMLS_DC);
|
||||
ZEND_API int boolean_xor_function(zval *result, zval *op1, zval *op2 TSRMLS_DC);
|
||||
|
||||
+31
-11
@@ -2104,7 +2104,7 @@ ZEND_VM_HANDLER(43, ZEND_JMPZ, CONST|TMP|VAR|CV, ANY)
|
||||
if (OP1_TYPE == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) {
|
||||
ret = Z_LVAL_P(val);
|
||||
} else {
|
||||
ret = i_zend_is_true(val);
|
||||
ret = i_zend_is_true(val TSRMLS_CC);
|
||||
FREE_OP1();
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
HANDLE_EXCEPTION();
|
||||
@@ -2134,7 +2134,7 @@ ZEND_VM_HANDLER(44, ZEND_JMPNZ, CONST|TMP|VAR|CV, ANY)
|
||||
if (OP1_TYPE == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) {
|
||||
ret = Z_LVAL_P(val);
|
||||
} else {
|
||||
ret = i_zend_is_true(val);
|
||||
ret = i_zend_is_true(val TSRMLS_CC);
|
||||
FREE_OP1();
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
HANDLE_EXCEPTION();
|
||||
@@ -2164,7 +2164,7 @@ ZEND_VM_HANDLER(45, ZEND_JMPZNZ, CONST|TMP|VAR|CV, ANY)
|
||||
if (OP1_TYPE == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) {
|
||||
retval = Z_LVAL_P(val);
|
||||
} else {
|
||||
retval = i_zend_is_true(val);
|
||||
retval = i_zend_is_true(val TSRMLS_CC);
|
||||
FREE_OP1();
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
HANDLE_EXCEPTION();
|
||||
@@ -2198,7 +2198,7 @@ ZEND_VM_HANDLER(46, ZEND_JMPZ_EX, CONST|TMP|VAR|CV, ANY)
|
||||
if (OP1_TYPE == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) {
|
||||
retval = Z_LVAL_P(val);
|
||||
} else {
|
||||
retval = i_zend_is_true(val);
|
||||
retval = i_zend_is_true(val TSRMLS_CC);
|
||||
FREE_OP1();
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
HANDLE_EXCEPTION();
|
||||
@@ -2229,7 +2229,7 @@ ZEND_VM_HANDLER(47, ZEND_JMPNZ_EX, CONST|TMP|VAR|CV, ANY)
|
||||
if (OP1_TYPE == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) {
|
||||
retval = Z_LVAL_P(val);
|
||||
} else {
|
||||
retval = i_zend_is_true(val);
|
||||
retval = i_zend_is_true(val TSRMLS_CC);
|
||||
FREE_OP1();
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
HANDLE_EXCEPTION();
|
||||
@@ -3484,7 +3484,7 @@ ZEND_VM_HANDLER(52, ZEND_BOOL, CONST|TMP|VAR|CV, ANY)
|
||||
|
||||
SAVE_OPLINE();
|
||||
/* PHP 3.0 returned "" for false and 1 for true, here we use 0 and 1 for now */
|
||||
ZVAL_BOOL(retval, i_zend_is_true(GET_OP1_ZVAL_PTR(BP_VAR_R)));
|
||||
ZVAL_BOOL(retval, i_zend_is_true(GET_OP1_ZVAL_PTR(BP_VAR_R) TSRMLS_CC));
|
||||
FREE_OP1();
|
||||
|
||||
CHECK_EXCEPTION();
|
||||
@@ -4647,7 +4647,7 @@ ZEND_VM_HANDLER(114, ZEND_ISSET_ISEMPTY_VAR, CONST|TMP|VAR|CV, UNUSED|CONST|VAR)
|
||||
ZVAL_BOOL(&EX_T(opline->result.var).tmp_var, 0);
|
||||
}
|
||||
} else /* if (opline->extended_value & ZEND_ISEMPTY) */ {
|
||||
if (!isset || !i_zend_is_true(*value)) {
|
||||
if (!isset || !i_zend_is_true(*value TSRMLS_CC)) {
|
||||
ZVAL_BOOL(&EX_T(opline->result.var).tmp_var, 1);
|
||||
} else {
|
||||
ZVAL_BOOL(&EX_T(opline->result.var).tmp_var, 0);
|
||||
@@ -4719,7 +4719,7 @@ ZEND_VM_C_LABEL(num_index_prop):
|
||||
result = isset;
|
||||
}
|
||||
} else /* if (opline->extended_value & ZEND_ISEMPTY) */ {
|
||||
if (!isset || !i_zend_is_true(*value)) {
|
||||
if (!isset || !i_zend_is_true(*value TSRMLS_CC)) {
|
||||
result = 0;
|
||||
} else {
|
||||
result = 1;
|
||||
@@ -4913,7 +4913,7 @@ ZEND_VM_HANDLER(152, ZEND_JMP_SET, CONST|TMP|VAR|CV, ANY)
|
||||
SAVE_OPLINE();
|
||||
value = GET_OP1_ZVAL_PTR(BP_VAR_R);
|
||||
|
||||
if (i_zend_is_true(value)) {
|
||||
if (i_zend_is_true(value TSRMLS_CC)) {
|
||||
ZVAL_COPY_VALUE(&EX_T(opline->result.var).tmp_var, value);
|
||||
if (!IS_OP1_TMP_FREE()) {
|
||||
zendi_zval_copy_ctor(EX_T(opline->result.var).tmp_var);
|
||||
@@ -4939,7 +4939,7 @@ ZEND_VM_HANDLER(158, ZEND_JMP_SET_VAR, CONST|TMP|VAR|CV, ANY)
|
||||
SAVE_OPLINE();
|
||||
value = GET_OP1_ZVAL_PTR(BP_VAR_R);
|
||||
|
||||
if (i_zend_is_true(value)) {
|
||||
if (i_zend_is_true(value TSRMLS_CC)) {
|
||||
if (OP1_TYPE == IS_VAR || OP1_TYPE == IS_CV) {
|
||||
Z_ADDREF_P(value);
|
||||
EX_T(opline->result.var).var.ptr = value;
|
||||
@@ -5094,7 +5094,7 @@ ZEND_VM_HANDLER(105, ZEND_TICKS, ANY, ANY)
|
||||
if (++EG(ticks_count)>=opline->extended_value) {
|
||||
EG(ticks_count)=0;
|
||||
if (zend_ticks_function) {
|
||||
zend_ticks_function(opline->extended_value);
|
||||
zend_ticks_function(opline->extended_value TSRMLS_CC);
|
||||
}
|
||||
}
|
||||
CHECK_EXCEPTION();
|
||||
@@ -5659,4 +5659,24 @@ ZEND_VM_HANDLER(163, ZEND_FAST_RET, ANY, ANY)
|
||||
}
|
||||
}
|
||||
|
||||
ZEND_VM_HANDLER(166, ZEND_POW, CONST|TMP|VAR|CV, CONST|TMP|VAR|CV)
|
||||
{
|
||||
USE_OPLINE
|
||||
zend_free_op free_op1, free_op2;
|
||||
|
||||
SAVE_OPLINE();
|
||||
pow_function(&EX_T(opline->result.var).tmp_var,
|
||||
GET_OP1_ZVAL_PTR(BP_VAR_R),
|
||||
GET_OP2_ZVAL_PTR(BP_VAR_R) TSRMLS_CC);
|
||||
FREE_OP1();
|
||||
FREE_OP2();
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
}
|
||||
|
||||
ZEND_VM_HANDLER(167, ZEND_ASSIGN_POW, VAR|UNUSED|CV, CONST|TMP|VAR|UNUSED|CV)
|
||||
{
|
||||
ZEND_VM_DISPATCH_TO_HELPER_EX(zend_binary_assign_op_helper, binary_op,pow_function);
|
||||
}
|
||||
|
||||
ZEND_VM_EXPORT_HELPER(zend_do_fcall, zend_do_fcall_common_helper)
|
||||
+422
-57
@@ -1107,7 +1107,7 @@ static int ZEND_FASTCALL ZEND_TICKS_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
if (++EG(ticks_count)>=opline->extended_value) {
|
||||
EG(ticks_count)=0;
|
||||
if (zend_ticks_function) {
|
||||
zend_ticks_function(opline->extended_value);
|
||||
zend_ticks_function(opline->extended_value TSRMLS_CC);
|
||||
}
|
||||
}
|
||||
CHECK_EXCEPTION();
|
||||
@@ -2416,7 +2416,7 @@ static int ZEND_FASTCALL ZEND_JMPZ_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
if (IS_CONST == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) {
|
||||
ret = Z_LVAL_P(val);
|
||||
} else {
|
||||
ret = i_zend_is_true(val);
|
||||
ret = i_zend_is_true(val TSRMLS_CC);
|
||||
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
HANDLE_EXCEPTION();
|
||||
@@ -2446,7 +2446,7 @@ static int ZEND_FASTCALL ZEND_JMPNZ_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS
|
||||
if (IS_CONST == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) {
|
||||
ret = Z_LVAL_P(val);
|
||||
} else {
|
||||
ret = i_zend_is_true(val);
|
||||
ret = i_zend_is_true(val TSRMLS_CC);
|
||||
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
HANDLE_EXCEPTION();
|
||||
@@ -2476,7 +2476,7 @@ static int ZEND_FASTCALL ZEND_JMPZNZ_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARG
|
||||
if (IS_CONST == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) {
|
||||
retval = Z_LVAL_P(val);
|
||||
} else {
|
||||
retval = i_zend_is_true(val);
|
||||
retval = i_zend_is_true(val TSRMLS_CC);
|
||||
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
HANDLE_EXCEPTION();
|
||||
@@ -2510,7 +2510,7 @@ static int ZEND_FASTCALL ZEND_JMPZ_EX_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_AR
|
||||
if (IS_CONST == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) {
|
||||
retval = Z_LVAL_P(val);
|
||||
} else {
|
||||
retval = i_zend_is_true(val);
|
||||
retval = i_zend_is_true(val TSRMLS_CC);
|
||||
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
HANDLE_EXCEPTION();
|
||||
@@ -2541,7 +2541,7 @@ static int ZEND_FASTCALL ZEND_JMPNZ_EX_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_A
|
||||
if (IS_CONST == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) {
|
||||
retval = Z_LVAL_P(val);
|
||||
} else {
|
||||
retval = i_zend_is_true(val);
|
||||
retval = i_zend_is_true(val TSRMLS_CC);
|
||||
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
HANDLE_EXCEPTION();
|
||||
@@ -2769,7 +2769,7 @@ static int ZEND_FASTCALL ZEND_BOOL_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
|
||||
SAVE_OPLINE();
|
||||
/* PHP 3.0 returned "" for false and 1 for true, here we use 0 and 1 for now */
|
||||
ZVAL_BOOL(retval, i_zend_is_true(opline->op1.zv));
|
||||
ZVAL_BOOL(retval, i_zend_is_true(opline->op1.zv TSRMLS_CC));
|
||||
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
@@ -3226,7 +3226,7 @@ static int ZEND_FASTCALL ZEND_JMP_SET_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_AR
|
||||
SAVE_OPLINE();
|
||||
value = opline->op1.zv;
|
||||
|
||||
if (i_zend_is_true(value)) {
|
||||
if (i_zend_is_true(value TSRMLS_CC)) {
|
||||
ZVAL_COPY_VALUE(&EX_T(opline->result.var).tmp_var, value);
|
||||
if (!0) {
|
||||
zendi_zval_copy_ctor(EX_T(opline->result.var).tmp_var);
|
||||
@@ -3251,7 +3251,7 @@ static int ZEND_FASTCALL ZEND_JMP_SET_VAR_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLE
|
||||
SAVE_OPLINE();
|
||||
value = opline->op1.zv;
|
||||
|
||||
if (i_zend_is_true(value)) {
|
||||
if (i_zend_is_true(value TSRMLS_CC)) {
|
||||
if (IS_CONST == IS_VAR || IS_CONST == IS_CV) {
|
||||
Z_ADDREF_P(value);
|
||||
EX_T(opline->result.var).var.ptr = value;
|
||||
@@ -4282,7 +4282,7 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_CONST_CONST_HANDLER(ZEND_O
|
||||
ZVAL_BOOL(&EX_T(opline->result.var).tmp_var, 0);
|
||||
}
|
||||
} else /* if (opline->extended_value & ZEND_ISEMPTY) */ {
|
||||
if (!isset || !i_zend_is_true(*value)) {
|
||||
if (!isset || !i_zend_is_true(*value TSRMLS_CC)) {
|
||||
ZVAL_BOOL(&EX_T(opline->result.var).tmp_var, 1);
|
||||
} else {
|
||||
ZVAL_BOOL(&EX_T(opline->result.var).tmp_var, 0);
|
||||
@@ -4492,6 +4492,21 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLE
|
||||
ZEND_VM_RETURN();
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL ZEND_POW_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
USE_OPLINE
|
||||
|
||||
|
||||
SAVE_OPLINE();
|
||||
pow_function(&EX_T(opline->result.var).tmp_var,
|
||||
opline->op1.zv,
|
||||
opline->op2.zv TSRMLS_CC);
|
||||
|
||||
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL ZEND_ADD_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
USE_OPLINE
|
||||
@@ -5179,6 +5194,21 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_
|
||||
ZEND_VM_RETURN();
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL ZEND_POW_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
USE_OPLINE
|
||||
zend_free_op free_op2;
|
||||
|
||||
SAVE_OPLINE();
|
||||
pow_function(&EX_T(opline->result.var).tmp_var,
|
||||
opline->op1.zv,
|
||||
_get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC);
|
||||
|
||||
zval_dtor(free_op2.var);
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL ZEND_ADD_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
USE_OPLINE
|
||||
@@ -6021,7 +6051,7 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_CONST_VAR_HANDLER(ZEND_OPC
|
||||
ZVAL_BOOL(&EX_T(opline->result.var).tmp_var, 0);
|
||||
}
|
||||
} else /* if (opline->extended_value & ZEND_ISEMPTY) */ {
|
||||
if (!isset || !i_zend_is_true(*value)) {
|
||||
if (!isset || !i_zend_is_true(*value TSRMLS_CC)) {
|
||||
ZVAL_BOOL(&EX_T(opline->result.var).tmp_var, 1);
|
||||
} else {
|
||||
ZVAL_BOOL(&EX_T(opline->result.var).tmp_var, 0);
|
||||
@@ -6192,6 +6222,21 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_
|
||||
ZEND_VM_RETURN();
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL ZEND_POW_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
USE_OPLINE
|
||||
zend_free_op free_op2;
|
||||
|
||||
SAVE_OPLINE();
|
||||
pow_function(&EX_T(opline->result.var).tmp_var,
|
||||
opline->op1.zv,
|
||||
_get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC);
|
||||
|
||||
zval_ptr_dtor_nogc(&free_op2.var);
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_CONST_UNUSED(int type, ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
USE_OPLINE
|
||||
@@ -6726,7 +6771,7 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_CONST_UNUSED_HANDLER(ZEND_
|
||||
ZVAL_BOOL(&EX_T(opline->result.var).tmp_var, 0);
|
||||
}
|
||||
} else /* if (opline->extended_value & ZEND_ISEMPTY) */ {
|
||||
if (!isset || !i_zend_is_true(*value)) {
|
||||
if (!isset || !i_zend_is_true(*value TSRMLS_CC)) {
|
||||
ZVAL_BOOL(&EX_T(opline->result.var).tmp_var, 1);
|
||||
} else {
|
||||
ZVAL_BOOL(&EX_T(opline->result.var).tmp_var, 0);
|
||||
@@ -7660,6 +7705,21 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_A
|
||||
ZEND_VM_RETURN();
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL ZEND_POW_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
USE_OPLINE
|
||||
|
||||
|
||||
SAVE_OPLINE();
|
||||
pow_function(&EX_T(opline->result.var).tmp_var,
|
||||
opline->op1.zv,
|
||||
_get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC);
|
||||
|
||||
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL ZEND_BW_NOT_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
USE_OPLINE
|
||||
@@ -7726,7 +7786,7 @@ static int ZEND_FASTCALL ZEND_JMPZ_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
if (IS_TMP_VAR == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) {
|
||||
ret = Z_LVAL_P(val);
|
||||
} else {
|
||||
ret = i_zend_is_true(val);
|
||||
ret = i_zend_is_true(val TSRMLS_CC);
|
||||
zval_dtor(free_op1.var);
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
HANDLE_EXCEPTION();
|
||||
@@ -7756,7 +7816,7 @@ static int ZEND_FASTCALL ZEND_JMPNZ_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
if (IS_TMP_VAR == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) {
|
||||
ret = Z_LVAL_P(val);
|
||||
} else {
|
||||
ret = i_zend_is_true(val);
|
||||
ret = i_zend_is_true(val TSRMLS_CC);
|
||||
zval_dtor(free_op1.var);
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
HANDLE_EXCEPTION();
|
||||
@@ -7786,7 +7846,7 @@ static int ZEND_FASTCALL ZEND_JMPZNZ_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
if (IS_TMP_VAR == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) {
|
||||
retval = Z_LVAL_P(val);
|
||||
} else {
|
||||
retval = i_zend_is_true(val);
|
||||
retval = i_zend_is_true(val TSRMLS_CC);
|
||||
zval_dtor(free_op1.var);
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
HANDLE_EXCEPTION();
|
||||
@@ -7820,7 +7880,7 @@ static int ZEND_FASTCALL ZEND_JMPZ_EX_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS
|
||||
if (IS_TMP_VAR == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) {
|
||||
retval = Z_LVAL_P(val);
|
||||
} else {
|
||||
retval = i_zend_is_true(val);
|
||||
retval = i_zend_is_true(val TSRMLS_CC);
|
||||
zval_dtor(free_op1.var);
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
HANDLE_EXCEPTION();
|
||||
@@ -7851,7 +7911,7 @@ static int ZEND_FASTCALL ZEND_JMPNZ_EX_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARG
|
||||
if (IS_TMP_VAR == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) {
|
||||
retval = Z_LVAL_P(val);
|
||||
} else {
|
||||
retval = i_zend_is_true(val);
|
||||
retval = i_zend_is_true(val TSRMLS_CC);
|
||||
zval_dtor(free_op1.var);
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
HANDLE_EXCEPTION();
|
||||
@@ -8067,7 +8127,7 @@ static int ZEND_FASTCALL ZEND_BOOL_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
|
||||
SAVE_OPLINE();
|
||||
/* PHP 3.0 returned "" for false and 1 for true, here we use 0 and 1 for now */
|
||||
ZVAL_BOOL(retval, i_zend_is_true(_get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC)));
|
||||
ZVAL_BOOL(retval, i_zend_is_true(_get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC) TSRMLS_CC));
|
||||
zval_dtor(free_op1.var);
|
||||
|
||||
CHECK_EXCEPTION();
|
||||
@@ -8554,7 +8614,7 @@ static int ZEND_FASTCALL ZEND_JMP_SET_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS
|
||||
SAVE_OPLINE();
|
||||
value = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC);
|
||||
|
||||
if (i_zend_is_true(value)) {
|
||||
if (i_zend_is_true(value TSRMLS_CC)) {
|
||||
ZVAL_COPY_VALUE(&EX_T(opline->result.var).tmp_var, value);
|
||||
if (!1) {
|
||||
zendi_zval_copy_ctor(EX_T(opline->result.var).tmp_var);
|
||||
@@ -8580,7 +8640,7 @@ static int ZEND_FASTCALL ZEND_JMP_SET_VAR_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_
|
||||
SAVE_OPLINE();
|
||||
value = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC);
|
||||
|
||||
if (i_zend_is_true(value)) {
|
||||
if (i_zend_is_true(value TSRMLS_CC)) {
|
||||
if (IS_TMP_VAR == IS_VAR || IS_TMP_VAR == IS_CV) {
|
||||
Z_ADDREF_P(value);
|
||||
EX_T(opline->result.var).var.ptr = value;
|
||||
@@ -9539,7 +9599,7 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_TMP_CONST_HANDLER(ZEND_OPC
|
||||
ZVAL_BOOL(&EX_T(opline->result.var).tmp_var, 0);
|
||||
}
|
||||
} else /* if (opline->extended_value & ZEND_ISEMPTY) */ {
|
||||
if (!isset || !i_zend_is_true(*value)) {
|
||||
if (!isset || !i_zend_is_true(*value TSRMLS_CC)) {
|
||||
ZVAL_BOOL(&EX_T(opline->result.var).tmp_var, 1);
|
||||
} else {
|
||||
ZVAL_BOOL(&EX_T(opline->result.var).tmp_var, 0);
|
||||
@@ -9709,6 +9769,21 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_
|
||||
ZEND_VM_RETURN();
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL ZEND_POW_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
USE_OPLINE
|
||||
zend_free_op free_op1;
|
||||
|
||||
SAVE_OPLINE();
|
||||
pow_function(&EX_T(opline->result.var).tmp_var,
|
||||
_get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC),
|
||||
opline->op2.zv TSRMLS_CC);
|
||||
zval_dtor(free_op1.var);
|
||||
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL ZEND_ADD_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
USE_OPLINE
|
||||
@@ -10398,6 +10473,21 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR
|
||||
ZEND_VM_RETURN();
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL ZEND_POW_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
USE_OPLINE
|
||||
zend_free_op free_op1, free_op2;
|
||||
|
||||
SAVE_OPLINE();
|
||||
pow_function(&EX_T(opline->result.var).tmp_var,
|
||||
_get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC),
|
||||
_get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC);
|
||||
zval_dtor(free_op1.var);
|
||||
zval_dtor(free_op2.var);
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL ZEND_ADD_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
USE_OPLINE
|
||||
@@ -11242,7 +11332,7 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_TMP_VAR_HANDLER(ZEND_OPCOD
|
||||
ZVAL_BOOL(&EX_T(opline->result.var).tmp_var, 0);
|
||||
}
|
||||
} else /* if (opline->extended_value & ZEND_ISEMPTY) */ {
|
||||
if (!isset || !i_zend_is_true(*value)) {
|
||||
if (!isset || !i_zend_is_true(*value TSRMLS_CC)) {
|
||||
ZVAL_BOOL(&EX_T(opline->result.var).tmp_var, 1);
|
||||
} else {
|
||||
ZVAL_BOOL(&EX_T(opline->result.var).tmp_var, 0);
|
||||
@@ -11413,6 +11503,21 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR
|
||||
ZEND_VM_RETURN();
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL ZEND_POW_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
USE_OPLINE
|
||||
zend_free_op free_op1, free_op2;
|
||||
|
||||
SAVE_OPLINE();
|
||||
pow_function(&EX_T(opline->result.var).tmp_var,
|
||||
_get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC),
|
||||
_get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC);
|
||||
zval_dtor(free_op1.var);
|
||||
zval_ptr_dtor_nogc(&free_op2.var);
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_TMP_UNUSED(int type, ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
USE_OPLINE
|
||||
@@ -11822,7 +11927,7 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_TMP_UNUSED_HANDLER(ZEND_OP
|
||||
ZVAL_BOOL(&EX_T(opline->result.var).tmp_var, 0);
|
||||
}
|
||||
} else /* if (opline->extended_value & ZEND_ISEMPTY) */ {
|
||||
if (!isset || !i_zend_is_true(*value)) {
|
||||
if (!isset || !i_zend_is_true(*value TSRMLS_CC)) {
|
||||
ZVAL_BOOL(&EX_T(opline->result.var).tmp_var, 1);
|
||||
} else {
|
||||
ZVAL_BOOL(&EX_T(opline->result.var).tmp_var, 0);
|
||||
@@ -12678,6 +12783,21 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG
|
||||
ZEND_VM_RETURN();
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL ZEND_POW_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
USE_OPLINE
|
||||
zend_free_op free_op1;
|
||||
|
||||
SAVE_OPLINE();
|
||||
pow_function(&EX_T(opline->result.var).tmp_var,
|
||||
_get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC),
|
||||
_get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC);
|
||||
zval_dtor(free_op1.var);
|
||||
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL ZEND_BW_NOT_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
USE_OPLINE
|
||||
@@ -12924,7 +13044,7 @@ static int ZEND_FASTCALL ZEND_JMPZ_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
if (IS_VAR == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) {
|
||||
ret = Z_LVAL_P(val);
|
||||
} else {
|
||||
ret = i_zend_is_true(val);
|
||||
ret = i_zend_is_true(val TSRMLS_CC);
|
||||
zval_ptr_dtor_nogc(&free_op1.var);
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
HANDLE_EXCEPTION();
|
||||
@@ -12954,7 +13074,7 @@ static int ZEND_FASTCALL ZEND_JMPNZ_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
if (IS_VAR == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) {
|
||||
ret = Z_LVAL_P(val);
|
||||
} else {
|
||||
ret = i_zend_is_true(val);
|
||||
ret = i_zend_is_true(val TSRMLS_CC);
|
||||
zval_ptr_dtor_nogc(&free_op1.var);
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
HANDLE_EXCEPTION();
|
||||
@@ -12984,7 +13104,7 @@ static int ZEND_FASTCALL ZEND_JMPZNZ_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
if (IS_VAR == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) {
|
||||
retval = Z_LVAL_P(val);
|
||||
} else {
|
||||
retval = i_zend_is_true(val);
|
||||
retval = i_zend_is_true(val TSRMLS_CC);
|
||||
zval_ptr_dtor_nogc(&free_op1.var);
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
HANDLE_EXCEPTION();
|
||||
@@ -13018,7 +13138,7 @@ static int ZEND_FASTCALL ZEND_JMPZ_EX_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS
|
||||
if (IS_VAR == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) {
|
||||
retval = Z_LVAL_P(val);
|
||||
} else {
|
||||
retval = i_zend_is_true(val);
|
||||
retval = i_zend_is_true(val TSRMLS_CC);
|
||||
zval_ptr_dtor_nogc(&free_op1.var);
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
HANDLE_EXCEPTION();
|
||||
@@ -13049,7 +13169,7 @@ static int ZEND_FASTCALL ZEND_JMPNZ_EX_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG
|
||||
if (IS_VAR == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) {
|
||||
retval = Z_LVAL_P(val);
|
||||
} else {
|
||||
retval = i_zend_is_true(val);
|
||||
retval = i_zend_is_true(val TSRMLS_CC);
|
||||
zval_ptr_dtor_nogc(&free_op1.var);
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
HANDLE_EXCEPTION();
|
||||
@@ -13370,7 +13490,7 @@ static int ZEND_FASTCALL ZEND_BOOL_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
|
||||
SAVE_OPLINE();
|
||||
/* PHP 3.0 returned "" for false and 1 for true, here we use 0 and 1 for now */
|
||||
ZVAL_BOOL(retval, i_zend_is_true(_get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC)));
|
||||
ZVAL_BOOL(retval, i_zend_is_true(_get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC) TSRMLS_CC));
|
||||
zval_ptr_dtor_nogc(&free_op1.var);
|
||||
|
||||
CHECK_EXCEPTION();
|
||||
@@ -13969,7 +14089,7 @@ static int ZEND_FASTCALL ZEND_JMP_SET_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS
|
||||
SAVE_OPLINE();
|
||||
value = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC);
|
||||
|
||||
if (i_zend_is_true(value)) {
|
||||
if (i_zend_is_true(value TSRMLS_CC)) {
|
||||
ZVAL_COPY_VALUE(&EX_T(opline->result.var).tmp_var, value);
|
||||
if (!0) {
|
||||
zendi_zval_copy_ctor(EX_T(opline->result.var).tmp_var);
|
||||
@@ -13995,7 +14115,7 @@ static int ZEND_FASTCALL ZEND_JMP_SET_VAR_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_
|
||||
SAVE_OPLINE();
|
||||
value = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC);
|
||||
|
||||
if (i_zend_is_true(value)) {
|
||||
if (i_zend_is_true(value TSRMLS_CC)) {
|
||||
if (IS_VAR == IS_VAR || IS_VAR == IS_CV) {
|
||||
Z_ADDREF_P(value);
|
||||
EX_T(opline->result.var).var.ptr = value;
|
||||
@@ -16257,7 +16377,7 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_VAR_CONST_HANDLER(ZEND_OPC
|
||||
ZVAL_BOOL(&EX_T(opline->result.var).tmp_var, 0);
|
||||
}
|
||||
} else /* if (opline->extended_value & ZEND_ISEMPTY) */ {
|
||||
if (!isset || !i_zend_is_true(*value)) {
|
||||
if (!isset || !i_zend_is_true(*value TSRMLS_CC)) {
|
||||
ZVAL_BOOL(&EX_T(opline->result.var).tmp_var, 1);
|
||||
} else {
|
||||
ZVAL_BOOL(&EX_T(opline->result.var).tmp_var, 0);
|
||||
@@ -16329,7 +16449,7 @@ num_index_prop:
|
||||
result = isset;
|
||||
}
|
||||
} else /* if (opline->extended_value & ZEND_ISEMPTY) */ {
|
||||
if (!isset || !i_zend_is_true(*value)) {
|
||||
if (!isset || !i_zend_is_true(*value TSRMLS_CC)) {
|
||||
result = 0;
|
||||
} else {
|
||||
result = 1;
|
||||
@@ -16575,6 +16695,26 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_
|
||||
ZEND_VM_RETURN();
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL ZEND_POW_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
USE_OPLINE
|
||||
zend_free_op free_op1;
|
||||
|
||||
SAVE_OPLINE();
|
||||
pow_function(&EX_T(opline->result.var).tmp_var,
|
||||
_get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC),
|
||||
opline->op2.zv TSRMLS_CC);
|
||||
zval_ptr_dtor_nogc(&free_op1.var);
|
||||
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL ZEND_ASSIGN_POW_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
return zend_binary_assign_op_helper_SPEC_VAR_CONST(pow_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU);
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL ZEND_ADD_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
USE_OPLINE
|
||||
@@ -18399,7 +18539,7 @@ num_index_prop:
|
||||
result = isset;
|
||||
}
|
||||
} else /* if (opline->extended_value & ZEND_ISEMPTY) */ {
|
||||
if (!isset || !i_zend_is_true(*value)) {
|
||||
if (!isset || !i_zend_is_true(*value TSRMLS_CC)) {
|
||||
result = 0;
|
||||
} else {
|
||||
result = 1;
|
||||
@@ -18645,6 +18785,26 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR
|
||||
ZEND_VM_RETURN();
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL ZEND_POW_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
USE_OPLINE
|
||||
zend_free_op free_op1, free_op2;
|
||||
|
||||
SAVE_OPLINE();
|
||||
pow_function(&EX_T(opline->result.var).tmp_var,
|
||||
_get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC),
|
||||
_get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC);
|
||||
zval_ptr_dtor_nogc(&free_op1.var);
|
||||
zval_dtor(free_op2.var);
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL ZEND_ASSIGN_POW_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
return zend_binary_assign_op_helper_SPEC_VAR_TMP(pow_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU);
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL ZEND_ADD_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
USE_OPLINE
|
||||
@@ -20777,7 +20937,7 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_VAR_VAR_HANDLER(ZEND_OPCOD
|
||||
ZVAL_BOOL(&EX_T(opline->result.var).tmp_var, 0);
|
||||
}
|
||||
} else /* if (opline->extended_value & ZEND_ISEMPTY) */ {
|
||||
if (!isset || !i_zend_is_true(*value)) {
|
||||
if (!isset || !i_zend_is_true(*value TSRMLS_CC)) {
|
||||
ZVAL_BOOL(&EX_T(opline->result.var).tmp_var, 1);
|
||||
} else {
|
||||
ZVAL_BOOL(&EX_T(opline->result.var).tmp_var, 0);
|
||||
@@ -20849,7 +21009,7 @@ num_index_prop:
|
||||
result = isset;
|
||||
}
|
||||
} else /* if (opline->extended_value & ZEND_ISEMPTY) */ {
|
||||
if (!isset || !i_zend_is_true(*value)) {
|
||||
if (!isset || !i_zend_is_true(*value TSRMLS_CC)) {
|
||||
result = 0;
|
||||
} else {
|
||||
result = 1;
|
||||
@@ -21096,6 +21256,26 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR
|
||||
ZEND_VM_RETURN();
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL ZEND_POW_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
USE_OPLINE
|
||||
zend_free_op free_op1, free_op2;
|
||||
|
||||
SAVE_OPLINE();
|
||||
pow_function(&EX_T(opline->result.var).tmp_var,
|
||||
_get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC),
|
||||
_get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC);
|
||||
zval_ptr_dtor_nogc(&free_op1.var);
|
||||
zval_ptr_dtor_nogc(&free_op2.var);
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL ZEND_ASSIGN_POW_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
return zend_binary_assign_op_helper_SPEC_VAR_VAR(pow_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU);
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_VAR_UNUSED(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
USE_OPLINE
|
||||
@@ -22051,7 +22231,7 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_VAR_UNUSED_HANDLER(ZEND_OP
|
||||
ZVAL_BOOL(&EX_T(opline->result.var).tmp_var, 0);
|
||||
}
|
||||
} else /* if (opline->extended_value & ZEND_ISEMPTY) */ {
|
||||
if (!isset || !i_zend_is_true(*value)) {
|
||||
if (!isset || !i_zend_is_true(*value TSRMLS_CC)) {
|
||||
ZVAL_BOOL(&EX_T(opline->result.var).tmp_var, 1);
|
||||
} else {
|
||||
ZVAL_BOOL(&EX_T(opline->result.var).tmp_var, 0);
|
||||
@@ -22243,6 +22423,11 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER
|
||||
ZEND_VM_RETURN();
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL ZEND_ASSIGN_POW_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
return zend_binary_assign_op_helper_SPEC_VAR_UNUSED(pow_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU);
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL ZEND_ADD_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
USE_OPLINE
|
||||
@@ -24116,7 +24301,7 @@ num_index_prop:
|
||||
result = isset;
|
||||
}
|
||||
} else /* if (opline->extended_value & ZEND_ISEMPTY) */ {
|
||||
if (!isset || !i_zend_is_true(*value)) {
|
||||
if (!isset || !i_zend_is_true(*value TSRMLS_CC)) {
|
||||
result = 0;
|
||||
} else {
|
||||
result = 1;
|
||||
@@ -24362,6 +24547,26 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG
|
||||
ZEND_VM_RETURN();
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL ZEND_POW_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
USE_OPLINE
|
||||
zend_free_op free_op1;
|
||||
|
||||
SAVE_OPLINE();
|
||||
pow_function(&EX_T(opline->result.var).tmp_var,
|
||||
_get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC),
|
||||
_get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC);
|
||||
zval_ptr_dtor_nogc(&free_op1.var);
|
||||
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL ZEND_ASSIGN_POW_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
return zend_binary_assign_op_helper_SPEC_VAR_CV(pow_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU);
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL ZEND_CLONE_SPEC_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
USE_OPLINE
|
||||
@@ -25611,7 +25816,7 @@ num_index_prop:
|
||||
result = isset;
|
||||
}
|
||||
} else /* if (opline->extended_value & ZEND_ISEMPTY) */ {
|
||||
if (!isset || !i_zend_is_true(*value)) {
|
||||
if (!isset || !i_zend_is_true(*value TSRMLS_CC)) {
|
||||
result = 0;
|
||||
} else {
|
||||
result = 1;
|
||||
@@ -25854,6 +26059,11 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDL
|
||||
ZEND_VM_RETURN();
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL ZEND_ASSIGN_POW_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
return zend_binary_assign_op_helper_SPEC_UNUSED_CONST(pow_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU);
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_UNUSED_TMP(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
USE_OPLINE
|
||||
@@ -26920,7 +27130,7 @@ num_index_prop:
|
||||
result = isset;
|
||||
}
|
||||
} else /* if (opline->extended_value & ZEND_ISEMPTY) */ {
|
||||
if (!isset || !i_zend_is_true(*value)) {
|
||||
if (!isset || !i_zend_is_true(*value TSRMLS_CC)) {
|
||||
result = 0;
|
||||
} else {
|
||||
result = 1;
|
||||
@@ -27163,6 +27373,11 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER
|
||||
ZEND_VM_RETURN();
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL ZEND_ASSIGN_POW_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
return zend_binary_assign_op_helper_SPEC_UNUSED_TMP(pow_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU);
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_UNUSED_VAR(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
USE_OPLINE
|
||||
@@ -28229,7 +28444,7 @@ num_index_prop:
|
||||
result = isset;
|
||||
}
|
||||
} else /* if (opline->extended_value & ZEND_ISEMPTY) */ {
|
||||
if (!isset || !i_zend_is_true(*value)) {
|
||||
if (!isset || !i_zend_is_true(*value TSRMLS_CC)) {
|
||||
result = 0;
|
||||
} else {
|
||||
result = 1;
|
||||
@@ -28473,6 +28688,11 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER
|
||||
ZEND_VM_RETURN();
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL ZEND_ASSIGN_POW_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
return zend_binary_assign_op_helper_SPEC_UNUSED_VAR(pow_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU);
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_UNUSED_UNUSED(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
USE_OPLINE
|
||||
@@ -28897,6 +29117,11 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_UNUSED_HANDLER(ZEND_OPCODE_HAND
|
||||
ZEND_VM_RETURN();
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL ZEND_ASSIGN_POW_SPEC_UNUSED_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
return zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED(pow_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU);
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_UNUSED_CV(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
USE_OPLINE
|
||||
@@ -29960,7 +30185,7 @@ num_index_prop:
|
||||
result = isset;
|
||||
}
|
||||
} else /* if (opline->extended_value & ZEND_ISEMPTY) */ {
|
||||
if (!isset || !i_zend_is_true(*value)) {
|
||||
if (!isset || !i_zend_is_true(*value TSRMLS_CC)) {
|
||||
result = 0;
|
||||
} else {
|
||||
result = 1;
|
||||
@@ -30203,6 +30428,11 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_
|
||||
ZEND_VM_RETURN();
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL ZEND_ASSIGN_POW_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
return zend_binary_assign_op_helper_SPEC_UNUSED_CV(pow_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU);
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL ZEND_BW_NOT_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
USE_OPLINE
|
||||
@@ -30444,7 +30674,7 @@ static int ZEND_FASTCALL ZEND_JMPZ_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
if (IS_CV == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) {
|
||||
ret = Z_LVAL_P(val);
|
||||
} else {
|
||||
ret = i_zend_is_true(val);
|
||||
ret = i_zend_is_true(val TSRMLS_CC);
|
||||
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
HANDLE_EXCEPTION();
|
||||
@@ -30474,7 +30704,7 @@ static int ZEND_FASTCALL ZEND_JMPNZ_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
if (IS_CV == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) {
|
||||
ret = Z_LVAL_P(val);
|
||||
} else {
|
||||
ret = i_zend_is_true(val);
|
||||
ret = i_zend_is_true(val TSRMLS_CC);
|
||||
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
HANDLE_EXCEPTION();
|
||||
@@ -30504,7 +30734,7 @@ static int ZEND_FASTCALL ZEND_JMPZNZ_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
if (IS_CV == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) {
|
||||
retval = Z_LVAL_P(val);
|
||||
} else {
|
||||
retval = i_zend_is_true(val);
|
||||
retval = i_zend_is_true(val TSRMLS_CC);
|
||||
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
HANDLE_EXCEPTION();
|
||||
@@ -30538,7 +30768,7 @@ static int ZEND_FASTCALL ZEND_JMPZ_EX_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
if (IS_CV == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) {
|
||||
retval = Z_LVAL_P(val);
|
||||
} else {
|
||||
retval = i_zend_is_true(val);
|
||||
retval = i_zend_is_true(val TSRMLS_CC);
|
||||
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
HANDLE_EXCEPTION();
|
||||
@@ -30569,7 +30799,7 @@ static int ZEND_FASTCALL ZEND_JMPNZ_EX_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS
|
||||
if (IS_CV == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) {
|
||||
retval = Z_LVAL_P(val);
|
||||
} else {
|
||||
retval = i_zend_is_true(val);
|
||||
retval = i_zend_is_true(val TSRMLS_CC);
|
||||
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
HANDLE_EXCEPTION();
|
||||
@@ -30874,7 +31104,7 @@ static int ZEND_FASTCALL ZEND_BOOL_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
|
||||
SAVE_OPLINE();
|
||||
/* PHP 3.0 returned "" for false and 1 for true, here we use 0 and 1 for now */
|
||||
ZVAL_BOOL(retval, i_zend_is_true(_get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC)));
|
||||
ZVAL_BOOL(retval, i_zend_is_true(_get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC) TSRMLS_CC));
|
||||
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
@@ -31331,7 +31561,7 @@ static int ZEND_FASTCALL ZEND_JMP_SET_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
SAVE_OPLINE();
|
||||
value = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC);
|
||||
|
||||
if (i_zend_is_true(value)) {
|
||||
if (i_zend_is_true(value TSRMLS_CC)) {
|
||||
ZVAL_COPY_VALUE(&EX_T(opline->result.var).tmp_var, value);
|
||||
if (!0) {
|
||||
zendi_zval_copy_ctor(EX_T(opline->result.var).tmp_var);
|
||||
@@ -31356,7 +31586,7 @@ static int ZEND_FASTCALL ZEND_JMP_SET_VAR_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_A
|
||||
SAVE_OPLINE();
|
||||
value = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC);
|
||||
|
||||
if (i_zend_is_true(value)) {
|
||||
if (i_zend_is_true(value TSRMLS_CC)) {
|
||||
if (IS_CV == IS_VAR || IS_CV == IS_CV) {
|
||||
Z_ADDREF_P(value);
|
||||
EX_T(opline->result.var).var.ptr = value;
|
||||
@@ -33384,7 +33614,7 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_CV_CONST_HANDLER(ZEND_OPCO
|
||||
ZVAL_BOOL(&EX_T(opline->result.var).tmp_var, 0);
|
||||
}
|
||||
} else /* if (opline->extended_value & ZEND_ISEMPTY) */ {
|
||||
if (!isset || !i_zend_is_true(*value)) {
|
||||
if (!isset || !i_zend_is_true(*value TSRMLS_CC)) {
|
||||
ZVAL_BOOL(&EX_T(opline->result.var).tmp_var, 1);
|
||||
} else {
|
||||
ZVAL_BOOL(&EX_T(opline->result.var).tmp_var, 0);
|
||||
@@ -33456,7 +33686,7 @@ num_index_prop:
|
||||
result = isset;
|
||||
}
|
||||
} else /* if (opline->extended_value & ZEND_ISEMPTY) */ {
|
||||
if (!isset || !i_zend_is_true(*value)) {
|
||||
if (!isset || !i_zend_is_true(*value TSRMLS_CC)) {
|
||||
result = 0;
|
||||
} else {
|
||||
result = 1;
|
||||
@@ -33699,6 +33929,26 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_A
|
||||
ZEND_VM_RETURN();
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL ZEND_POW_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
USE_OPLINE
|
||||
|
||||
|
||||
SAVE_OPLINE();
|
||||
pow_function(&EX_T(opline->result.var).tmp_var,
|
||||
_get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC),
|
||||
opline->op2.zv TSRMLS_CC);
|
||||
|
||||
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL ZEND_ASSIGN_POW_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
return zend_binary_assign_op_helper_SPEC_CV_CONST(pow_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU);
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL ZEND_ADD_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
USE_OPLINE
|
||||
@@ -35387,7 +35637,7 @@ num_index_prop:
|
||||
result = isset;
|
||||
}
|
||||
} else /* if (opline->extended_value & ZEND_ISEMPTY) */ {
|
||||
if (!isset || !i_zend_is_true(*value)) {
|
||||
if (!isset || !i_zend_is_true(*value TSRMLS_CC)) {
|
||||
result = 0;
|
||||
} else {
|
||||
result = 1;
|
||||
@@ -35630,6 +35880,26 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARG
|
||||
ZEND_VM_RETURN();
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL ZEND_POW_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
USE_OPLINE
|
||||
zend_free_op free_op2;
|
||||
|
||||
SAVE_OPLINE();
|
||||
pow_function(&EX_T(opline->result.var).tmp_var,
|
||||
_get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC),
|
||||
_get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC);
|
||||
|
||||
zval_dtor(free_op2.var);
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL ZEND_ASSIGN_POW_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
return zend_binary_assign_op_helper_SPEC_CV_TMP(pow_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU);
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL ZEND_ADD_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
USE_OPLINE
|
||||
@@ -37625,7 +37895,7 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_CV_VAR_HANDLER(ZEND_OPCODE
|
||||
ZVAL_BOOL(&EX_T(opline->result.var).tmp_var, 0);
|
||||
}
|
||||
} else /* if (opline->extended_value & ZEND_ISEMPTY) */ {
|
||||
if (!isset || !i_zend_is_true(*value)) {
|
||||
if (!isset || !i_zend_is_true(*value TSRMLS_CC)) {
|
||||
ZVAL_BOOL(&EX_T(opline->result.var).tmp_var, 1);
|
||||
} else {
|
||||
ZVAL_BOOL(&EX_T(opline->result.var).tmp_var, 0);
|
||||
@@ -37697,7 +37967,7 @@ num_index_prop:
|
||||
result = isset;
|
||||
}
|
||||
} else /* if (opline->extended_value & ZEND_ISEMPTY) */ {
|
||||
if (!isset || !i_zend_is_true(*value)) {
|
||||
if (!isset || !i_zend_is_true(*value TSRMLS_CC)) {
|
||||
result = 0;
|
||||
} else {
|
||||
result = 1;
|
||||
@@ -37941,6 +38211,26 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG
|
||||
ZEND_VM_RETURN();
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL ZEND_POW_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
USE_OPLINE
|
||||
zend_free_op free_op2;
|
||||
|
||||
SAVE_OPLINE();
|
||||
pow_function(&EX_T(opline->result.var).tmp_var,
|
||||
_get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC),
|
||||
_get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC);
|
||||
|
||||
zval_ptr_dtor_nogc(&free_op2.var);
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL ZEND_ASSIGN_POW_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
return zend_binary_assign_op_helper_SPEC_CV_VAR(pow_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU);
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_CV_UNUSED(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
USE_OPLINE
|
||||
@@ -38769,7 +39059,7 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_CV_UNUSED_HANDLER(ZEND_OPC
|
||||
ZVAL_BOOL(&EX_T(opline->result.var).tmp_var, 0);
|
||||
}
|
||||
} else /* if (opline->extended_value & ZEND_ISEMPTY) */ {
|
||||
if (!isset || !i_zend_is_true(*value)) {
|
||||
if (!isset || !i_zend_is_true(*value TSRMLS_CC)) {
|
||||
ZVAL_BOOL(&EX_T(opline->result.var).tmp_var, 1);
|
||||
} else {
|
||||
ZVAL_BOOL(&EX_T(opline->result.var).tmp_var, 0);
|
||||
@@ -38939,6 +39229,11 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_
|
||||
ZEND_VM_RETURN();
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL ZEND_ASSIGN_POW_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
return zend_binary_assign_op_helper_SPEC_CV_UNUSED(pow_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU);
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL ZEND_ADD_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
USE_OPLINE
|
||||
@@ -40675,7 +40970,7 @@ num_index_prop:
|
||||
result = isset;
|
||||
}
|
||||
} else /* if (opline->extended_value & ZEND_ISEMPTY) */ {
|
||||
if (!isset || !i_zend_is_true(*value)) {
|
||||
if (!isset || !i_zend_is_true(*value TSRMLS_CC)) {
|
||||
result = 0;
|
||||
} else {
|
||||
result = 1;
|
||||
@@ -40918,6 +41213,26 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS
|
||||
ZEND_VM_RETURN();
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL ZEND_POW_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
USE_OPLINE
|
||||
|
||||
|
||||
SAVE_OPLINE();
|
||||
pow_function(&EX_T(opline->result.var).tmp_var,
|
||||
_get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC),
|
||||
_get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC);
|
||||
|
||||
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL ZEND_ASSIGN_POW_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
return zend_binary_assign_op_helper_SPEC_CV_CV(pow_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU);
|
||||
}
|
||||
|
||||
static int ZEND_FASTCALL ZEND_NULL_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
{
|
||||
zend_error_noreturn(E_ERROR, "Invalid opcode %d/%d/%d.", OPLINE->opcode, OPLINE->op1_type, OPLINE->op2_type);
|
||||
@@ -45078,6 +45393,56 @@ void zend_init_opcodes_handlers(void)
|
||||
ZEND_SEND_UNPACK_SPEC_HANDLER,
|
||||
ZEND_SEND_UNPACK_SPEC_HANDLER,
|
||||
ZEND_SEND_UNPACK_SPEC_HANDLER,
|
||||
ZEND_POW_SPEC_CONST_CONST_HANDLER,
|
||||
ZEND_POW_SPEC_CONST_TMP_HANDLER,
|
||||
ZEND_POW_SPEC_CONST_VAR_HANDLER,
|
||||
ZEND_NULL_HANDLER,
|
||||
ZEND_POW_SPEC_CONST_CV_HANDLER,
|
||||
ZEND_POW_SPEC_TMP_CONST_HANDLER,
|
||||
ZEND_POW_SPEC_TMP_TMP_HANDLER,
|
||||
ZEND_POW_SPEC_TMP_VAR_HANDLER,
|
||||
ZEND_NULL_HANDLER,
|
||||
ZEND_POW_SPEC_TMP_CV_HANDLER,
|
||||
ZEND_POW_SPEC_VAR_CONST_HANDLER,
|
||||
ZEND_POW_SPEC_VAR_TMP_HANDLER,
|
||||
ZEND_POW_SPEC_VAR_VAR_HANDLER,
|
||||
ZEND_NULL_HANDLER,
|
||||
ZEND_POW_SPEC_VAR_CV_HANDLER,
|
||||
ZEND_NULL_HANDLER,
|
||||
ZEND_NULL_HANDLER,
|
||||
ZEND_NULL_HANDLER,
|
||||
ZEND_NULL_HANDLER,
|
||||
ZEND_NULL_HANDLER,
|
||||
ZEND_POW_SPEC_CV_CONST_HANDLER,
|
||||
ZEND_POW_SPEC_CV_TMP_HANDLER,
|
||||
ZEND_POW_SPEC_CV_VAR_HANDLER,
|
||||
ZEND_NULL_HANDLER,
|
||||
ZEND_POW_SPEC_CV_CV_HANDLER,
|
||||
ZEND_NULL_HANDLER,
|
||||
ZEND_NULL_HANDLER,
|
||||
ZEND_NULL_HANDLER,
|
||||
ZEND_NULL_HANDLER,
|
||||
ZEND_NULL_HANDLER,
|
||||
ZEND_NULL_HANDLER,
|
||||
ZEND_NULL_HANDLER,
|
||||
ZEND_NULL_HANDLER,
|
||||
ZEND_NULL_HANDLER,
|
||||
ZEND_NULL_HANDLER,
|
||||
ZEND_ASSIGN_POW_SPEC_VAR_CONST_HANDLER,
|
||||
ZEND_ASSIGN_POW_SPEC_VAR_TMP_HANDLER,
|
||||
ZEND_ASSIGN_POW_SPEC_VAR_VAR_HANDLER,
|
||||
ZEND_ASSIGN_POW_SPEC_VAR_UNUSED_HANDLER,
|
||||
ZEND_ASSIGN_POW_SPEC_VAR_CV_HANDLER,
|
||||
ZEND_ASSIGN_POW_SPEC_UNUSED_CONST_HANDLER,
|
||||
ZEND_ASSIGN_POW_SPEC_UNUSED_TMP_HANDLER,
|
||||
ZEND_ASSIGN_POW_SPEC_UNUSED_VAR_HANDLER,
|
||||
ZEND_ASSIGN_POW_SPEC_UNUSED_UNUSED_HANDLER,
|
||||
ZEND_ASSIGN_POW_SPEC_UNUSED_CV_HANDLER,
|
||||
ZEND_ASSIGN_POW_SPEC_CV_CONST_HANDLER,
|
||||
ZEND_ASSIGN_POW_SPEC_CV_TMP_HANDLER,
|
||||
ZEND_ASSIGN_POW_SPEC_CV_VAR_HANDLER,
|
||||
ZEND_ASSIGN_POW_SPEC_CV_UNUSED_HANDLER,
|
||||
ZEND_ASSIGN_POW_SPEC_CV_CV_HANDLER,
|
||||
ZEND_NULL_HANDLER
|
||||
};
|
||||
zend_opcode_handlers = (opcode_handler_t*)labels;
|
||||
|
||||
@@ -21,7 +21,7 @@
|
||||
#include <stdio.h>
|
||||
#include <zend.h>
|
||||
|
||||
const char *zend_vm_opcodes_map[166] = {
|
||||
const char *zend_vm_opcodes_map[168] = {
|
||||
"ZEND_NOP",
|
||||
"ZEND_ADD",
|
||||
"ZEND_SUB",
|
||||
@@ -188,6 +188,8 @@ const char *zend_vm_opcodes_map[166] = {
|
||||
"ZEND_FAST_RET",
|
||||
"ZEND_RECV_VARIADIC",
|
||||
"ZEND_SEND_UNPACK",
|
||||
"ZEND_POW",
|
||||
"ZEND_ASSIGN_POW",
|
||||
};
|
||||
|
||||
ZEND_API const char* zend_get_opcode_name(zend_uchar opcode) {
|
||||
|
||||
@@ -171,5 +171,7 @@ ZEND_API const char *zend_get_opcode_name(zend_uchar opcode);
|
||||
#define ZEND_FAST_RET 163
|
||||
#define ZEND_RECV_VARIADIC 164
|
||||
#define ZEND_SEND_UNPACK 165
|
||||
#define ZEND_POW 166
|
||||
#define ZEND_ASSIGN_POW 167
|
||||
|
||||
#endif
|
||||
+1
-1
@@ -118,7 +118,7 @@ int zend_sprintf(char *buffer, const char *format, ...);
|
||||
])
|
||||
|
||||
PHP_MAJOR_VERSION=5
|
||||
PHP_MINOR_VERSION=6
|
||||
PHP_MINOR_VERSION=7
|
||||
PHP_RELEASE_VERSION=0
|
||||
PHP_EXTRA_VERSION="-dev"
|
||||
PHP_VERSION="$PHP_MAJOR_VERSION.$PHP_MINOR_VERSION.$PHP_RELEASE_VERSION$PHP_EXTRA_VERSION"
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| PHP Version 5 |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1997-2013 The PHP Group |
|
||||
| Copyright (c) 1997-2014 The PHP Group |
|
||||
+----------------------------------------------------------------------+
|
||||
| This 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-2013 The PHP Group |
|
||||
| Copyright (c) 1997-2014 The PHP Group |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 3.01 of the PHP license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
@@ -124,14 +124,15 @@ DBA_EXISTS_FUNC(inifile)
|
||||
DBA_DELETE_FUNC(inifile)
|
||||
{
|
||||
int res;
|
||||
zend_bool found = 0;
|
||||
|
||||
INIFILE_DATA;
|
||||
INIFILE_GKEY;
|
||||
|
||||
res = inifile_delete(dba, &ini_key TSRMLS_CC);
|
||||
res = inifile_delete_ex(dba, &ini_key, &found TSRMLS_CC);
|
||||
|
||||
INIFILE_DONE;
|
||||
return (res == -1 ? FAILURE : SUCCESS);
|
||||
return (res == -1 || !found ? FAILURE : SUCCESS);
|
||||
}
|
||||
|
||||
DBA_FIRSTKEY_FUNC(inifile)
|
||||
|
||||
@@ -402,7 +402,7 @@ static int inifile_copy_to(inifile *dba, size_t pos_start, size_t pos_end, inifi
|
||||
return FAILURE;
|
||||
}
|
||||
php_stream_seek(dba->fp, pos_start, SEEK_SET);
|
||||
if (!php_stream_copy_to_stream_ex(dba->fp, fp, pos_end - pos_start, NULL)) {
|
||||
if (SUCCESS != php_stream_copy_to_stream_ex(dba->fp, fp, pos_end - pos_start, NULL)) {
|
||||
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Could not copy group [%zu - %zu] to temporary stream", pos_start, pos_end);
|
||||
return FAILURE;
|
||||
}
|
||||
@@ -413,7 +413,7 @@ static int inifile_copy_to(inifile *dba, size_t pos_start, size_t pos_end, inifi
|
||||
/* {{{ inifile_filter
|
||||
* copy from to dba while ignoring key name (group must equal)
|
||||
*/
|
||||
static int inifile_filter(inifile *dba, inifile *from, const key_type *key TSRMLS_DC)
|
||||
static int inifile_filter(inifile *dba, inifile *from, const key_type *key, zend_bool *found TSRMLS_DC)
|
||||
{
|
||||
size_t pos_start = 0, pos_next = 0, pos_curr;
|
||||
int ret = SUCCESS;
|
||||
@@ -424,10 +424,13 @@ static int inifile_filter(inifile *dba, inifile *from, const key_type *key TSRML
|
||||
while(inifile_read(from, &ln TSRMLS_CC)) {
|
||||
switch(inifile_key_cmp(&ln.key, key TSRMLS_CC)) {
|
||||
case 0:
|
||||
if (found) {
|
||||
*found = (zend_bool) 1;
|
||||
}
|
||||
pos_curr = php_stream_tell(from->fp);
|
||||
if (pos_start != pos_next) {
|
||||
php_stream_seek(from->fp, pos_start, SEEK_SET);
|
||||
if (!php_stream_copy_to_stream_ex(from->fp, dba->fp, pos_next - pos_start, NULL)) {
|
||||
if (SUCCESS != php_stream_copy_to_stream_ex(from->fp, dba->fp, pos_next - pos_start, NULL)) {
|
||||
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Could not copy [%zu - %zu] from temporary stream", pos_next, pos_start);
|
||||
ret = FAILURE;
|
||||
}
|
||||
@@ -446,7 +449,7 @@ static int inifile_filter(inifile *dba, inifile *from, const key_type *key TSRML
|
||||
}
|
||||
if (pos_start != pos_next) {
|
||||
php_stream_seek(from->fp, pos_start, SEEK_SET);
|
||||
if (!php_stream_copy_to_stream_ex(from->fp, dba->fp, pos_next - pos_start, NULL)) {
|
||||
if (SUCCESS != php_stream_copy_to_stream_ex(from->fp, dba->fp, pos_next - pos_start, NULL)) {
|
||||
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Could not copy [%zu - %zu] from temporary stream", pos_next, pos_start);
|
||||
ret = FAILURE;
|
||||
}
|
||||
@@ -458,7 +461,7 @@ static int inifile_filter(inifile *dba, inifile *from, const key_type *key TSRML
|
||||
|
||||
/* {{{ inifile_delete_replace_append
|
||||
*/
|
||||
static int inifile_delete_replace_append(inifile *dba, const key_type *key, const val_type *value, int append TSRMLS_DC)
|
||||
static int inifile_delete_replace_append(inifile *dba, const key_type *key, const val_type *value, int append, zend_bool *found TSRMLS_DC)
|
||||
{
|
||||
size_t pos_grp_start=0, pos_grp_next;
|
||||
inifile *ini_tmp = NULL;
|
||||
@@ -497,7 +500,7 @@ static int inifile_delete_replace_append(inifile *dba, const key_type *key, cons
|
||||
php_stream_seek(dba->fp, 0, SEEK_END);
|
||||
if (pos_grp_next != (size_t)php_stream_tell(dba->fp)) {
|
||||
php_stream_seek(dba->fp, pos_grp_next, SEEK_SET);
|
||||
if (!php_stream_copy_to_stream_ex(dba->fp, fp_tmp, PHP_STREAM_COPY_ALL, NULL)) {
|
||||
if (SUCCESS != php_stream_copy_to_stream_ex(dba->fp, fp_tmp, PHP_STREAM_COPY_ALL, NULL)) {
|
||||
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Could not copy remainder to temporary stream");
|
||||
ret = FAILURE;
|
||||
}
|
||||
@@ -516,7 +519,7 @@ static int inifile_delete_replace_append(inifile *dba, const key_type *key, cons
|
||||
if (key->name && strlen(key->name)) {
|
||||
/* 6 */
|
||||
if (!append && ini_tmp) {
|
||||
ret = inifile_filter(dba, ini_tmp, key TSRMLS_CC);
|
||||
ret = inifile_filter(dba, ini_tmp, key, found TSRMLS_CC);
|
||||
}
|
||||
|
||||
/* 7 */
|
||||
@@ -538,7 +541,7 @@ static int inifile_delete_replace_append(inifile *dba, const key_type *key, cons
|
||||
if (fp_tmp && php_stream_tell(fp_tmp)) {
|
||||
php_stream_seek(fp_tmp, 0, SEEK_SET);
|
||||
php_stream_seek(dba->fp, 0, SEEK_END);
|
||||
if (!php_stream_copy_to_stream_ex(fp_tmp, dba->fp, PHP_STREAM_COPY_ALL, NULL)) {
|
||||
if (SUCCESS != php_stream_copy_to_stream_ex(fp_tmp, dba->fp, PHP_STREAM_COPY_ALL, NULL)) {
|
||||
php_error_docref(NULL TSRMLS_CC, E_RECOVERABLE_ERROR, "Could not copy from temporary stream - ini file truncated");
|
||||
ret = FAILURE;
|
||||
}
|
||||
@@ -563,7 +566,15 @@ static int inifile_delete_replace_append(inifile *dba, const key_type *key, cons
|
||||
*/
|
||||
int inifile_delete(inifile *dba, const key_type *key TSRMLS_DC)
|
||||
{
|
||||
return inifile_delete_replace_append(dba, key, NULL, 0 TSRMLS_CC);
|
||||
return inifile_delete_replace_append(dba, key, NULL, 0, NULL TSRMLS_CC);
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
/* {{{ inifile_delete_ex
|
||||
*/
|
||||
int inifile_delete_ex(inifile *dba, const key_type *key, zend_bool *found TSRMLS_DC)
|
||||
{
|
||||
return inifile_delete_replace_append(dba, key, NULL, 0, found TSRMLS_CC);
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
@@ -571,7 +582,15 @@ int inifile_delete(inifile *dba, const key_type *key TSRMLS_DC)
|
||||
*/
|
||||
int inifile_replace(inifile *dba, const key_type *key, const val_type *value TSRMLS_DC)
|
||||
{
|
||||
return inifile_delete_replace_append(dba, key, value, 0 TSRMLS_CC);
|
||||
return inifile_delete_replace_append(dba, key, value, 0, NULL TSRMLS_CC);
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
/* {{{ inifile_replace_ex
|
||||
*/
|
||||
int inifile_replace_ex(inifile *dba, const key_type *key, const val_type *value, zend_bool *found TSRMLS_DC)
|
||||
{
|
||||
return inifile_delete_replace_append(dba, key, value, 0, found TSRMLS_CC);
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
@@ -579,7 +598,7 @@ int inifile_replace(inifile *dba, const key_type *key, const val_type *value TSR
|
||||
*/
|
||||
int inifile_append(inifile *dba, const key_type *key, const val_type *value TSRMLS_DC)
|
||||
{
|
||||
return inifile_delete_replace_append(dba, key, value, 1 TSRMLS_CC);
|
||||
return inifile_delete_replace_append(dba, key, value, 1, NULL TSRMLS_CC);
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
|
||||
@@ -49,7 +49,9 @@ val_type inifile_fetch(inifile *dba, const key_type *key, int skip TSRMLS_DC);
|
||||
int inifile_firstkey(inifile *dba TSRMLS_DC);
|
||||
int inifile_nextkey(inifile *dba TSRMLS_DC);
|
||||
int inifile_delete(inifile *dba, const key_type *key TSRMLS_DC);
|
||||
int inifile_delete_ex(inifile *dba, const key_type *key, zend_bool *found TSRMLS_DC);
|
||||
int inifile_replace(inifile *dba, const key_type *key, const val_type *val TSRMLS_DC);
|
||||
int inifile_replace_ex(inifile *dba, const key_type *key, const val_type *val, zend_bool *found TSRMLS_DC);
|
||||
int inifile_append(inifile *dba, const key_type *key, const val_type *val TSRMLS_DC);
|
||||
char *inifile_version();
|
||||
|
||||
|
||||
@@ -0,0 +1,43 @@
|
||||
--TEST--
|
||||
Bug #62490 (dba_delete returns true on missing item (inifile))
|
||||
--SKIPIF--
|
||||
<?php
|
||||
$handler = "inifile";
|
||||
include "skipif.inc";
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
$handler = "inifile";
|
||||
include "test.inc";
|
||||
|
||||
$dba = dba_open($db_filename, "n", $handler)
|
||||
or die;
|
||||
for ($i = 0; $i < 3; ++$i) {
|
||||
echo "insert $i:";
|
||||
var_dump(dba_insert("a", $i, $dba));
|
||||
}
|
||||
|
||||
echo "exists:";
|
||||
var_dump(dba_exists("a", $dba));
|
||||
echo "delete:";
|
||||
var_dump(dba_delete("a", $dba));
|
||||
echo "exists:";
|
||||
var_dump(dba_exists("a", $dba));
|
||||
echo "delete:";
|
||||
var_dump(dba_delete("a", $dba));
|
||||
|
||||
?>
|
||||
===DONE===
|
||||
--CLEAN--
|
||||
<?php
|
||||
include "clean.inc";
|
||||
?>
|
||||
--EXPECT--
|
||||
insert 0:bool(true)
|
||||
insert 1:bool(true)
|
||||
insert 2:bool(true)
|
||||
exists:bool(true)
|
||||
delete:bool(true)
|
||||
exists:bool(false)
|
||||
delete:bool(false)
|
||||
===DONE===
|
||||
@@ -39,8 +39,6 @@ require(dirname(__FILE__) .'/clean.inc');
|
||||
database handler: db4
|
||||
int(14)
|
||||
|
||||
Notice: dba_open(): %stest0.dbm: unexpected file type or format in %sdba_db4_003.php on line %d
|
||||
|
||||
Warning: dba_open(%stest0.dbm,c): Driver initialization failed for handler: db4: Invalid argument in %sdba_db4_003.php on line %d
|
||||
Error creating %stest0.dbm
|
||||
Dummy contents
|
||||
@@ -35,7 +35,5 @@ require(dirname(__FILE__) .'/clean.inc');
|
||||
database handler: db4
|
||||
int(14)
|
||||
|
||||
Notice: dba_popen(): %stest0.dbm: unexpected file type or format in %sdba_db4_007.php on line %d
|
||||
|
||||
Warning: dba_popen(%stest0.dbm,c): Driver initialization failed for handler: db4: Invalid argument in %sdba_db4_007.php on line %d
|
||||
Error creating %stest0.dbm
|
||||
@@ -1,38 +0,0 @@
|
||||
--TEST--
|
||||
DBA DB4 magic_quotes_runtime Test
|
||||
--SKIPIF--
|
||||
<?php
|
||||
$handler = "db4";
|
||||
require_once(dirname(__FILE__) .'/skipif.inc');
|
||||
die("info $HND handler used");
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
$handler = "db4";
|
||||
require_once(dirname(__FILE__) .'/test.inc');
|
||||
echo "database handler: $handler\n";
|
||||
if (($db_file=dba_open($db_file, "n", $handler))!==FALSE) {
|
||||
ini_set('magic_quotes_runtime', 0);
|
||||
dba_insert("key1", '"', $db_file);
|
||||
var_dump(dba_fetch("key1", $db_file));
|
||||
ini_set('magic_quotes_runtime', 1);
|
||||
var_dump(dba_fetch("key1", $db_file));
|
||||
dba_replace("key1", '\"', $db_file);
|
||||
var_dump(dba_fetch("key1", $db_file));
|
||||
ini_set('magic_quotes_runtime', 0);
|
||||
var_dump(dba_fetch("key1", $db_file));
|
||||
dba_close($db_file);
|
||||
} else {
|
||||
echo "Error creating database\n";
|
||||
}
|
||||
?>
|
||||
--CLEAN--
|
||||
<?php
|
||||
require(dirname(__FILE__) .'/clean.inc');
|
||||
?>
|
||||
--EXPECTF--
|
||||
database handler: db4
|
||||
string(1) """
|
||||
string(2) "\""
|
||||
string(2) "\""
|
||||
string(1) """
|
||||
@@ -82,7 +82,7 @@ do {
|
||||
dba_close($dba_reader);
|
||||
}
|
||||
if (($db_file = dba_popen($db_filename, 'r'.($lock_flag==''?'':'-'), $handler))!==FALSE) {
|
||||
if ($handler == 'dbm') {
|
||||
if ($handler == 'dbm' || $handler == "tcadb") {
|
||||
dba_close($db_file);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -12,6 +12,10 @@ DBA INIFILE handler test
|
||||
require_once dirname(__FILE__) .'/dba_handler.inc';
|
||||
?>
|
||||
===DONE===
|
||||
--CLEAN--
|
||||
<?php
|
||||
require(dirname(__FILE__) .'/clean.inc');
|
||||
?>
|
||||
--EXPECT--
|
||||
database handler: inifile
|
||||
3NYNYY
|
||||
@@ -19,7 +23,7 @@ Content String 2
|
||||
Content 2 replaced
|
||||
Read during write: not allowed
|
||||
"key number 6" written
|
||||
Failed to write "key number 6" 2nd time
|
||||
"key number 6" written 2nd time
|
||||
Content 2 replaced 2nd time
|
||||
The 6th value
|
||||
array(3) {
|
||||
@@ -36,7 +40,7 @@ Content String 2
|
||||
Content 2 replaced
|
||||
Read during write: not allowed
|
||||
"key number 6" written
|
||||
Failed to write "key number 6" 2nd time
|
||||
"key number 6" written 2nd time
|
||||
Content 2 replaced 2nd time
|
||||
The 6th value
|
||||
array(3) {
|
||||
|
||||
@@ -16,6 +16,12 @@ DBA TCADB handler test
|
||||
require_once dirname(__FILE__) .'/dba_handler.inc';
|
||||
?>
|
||||
===DONE===
|
||||
--CLEAN--
|
||||
<?php
|
||||
$db_filename = $db_file = dirname(__FILE__) .'/test0.tch';
|
||||
@unlink($db_filename);
|
||||
@unlink($db_filename.'.lck');
|
||||
?>
|
||||
--EXPECT--
|
||||
database handler: tcadb
|
||||
3NYNYY
|
||||
|
||||
+1
-1
@@ -448,7 +448,7 @@ static int dom_property_exists(zval *object, zval *member, int check_empty, cons
|
||||
Z_SET_REFCOUNT_P(tmp, 1);
|
||||
Z_UNSET_ISREF_P(tmp);
|
||||
if (check_empty == 1) {
|
||||
retval = zend_is_true(tmp);
|
||||
retval = zend_is_true(tmp TSRMLS_CC);
|
||||
} else if (check_empty == 0) {
|
||||
retval = (Z_TYPE_P(tmp) != IS_NULL);
|
||||
}
|
||||
|
||||
+9
-1
@@ -1050,7 +1050,15 @@ gdImageStringFTEx (gdImage * im, int *brect, int fg, char *fontlist, double ptsi
|
||||
}
|
||||
|
||||
/* transform glyph image */
|
||||
FT_Get_Glyph(slot, &image);
|
||||
if (FT_Get_Glyph(slot, &image)) {
|
||||
if (tmpstr) {
|
||||
gdFree(tmpstr);
|
||||
}
|
||||
gdCacheDelete(tc_cache);
|
||||
gdMutexUnlock(gdFontCacheMutex);
|
||||
return "Problem loading glyph";
|
||||
}
|
||||
|
||||
if (brect) { /* only if need brect */
|
||||
FT_Glyph_Get_CBox(image, ft_glyph_bbox_gridfit, &glyph_bbox);
|
||||
glyph_bbox.xMin += penf.x;
|
||||
|
||||
@@ -532,6 +532,9 @@ static int gmp_do_operation(zend_uchar opcode, zval *result, zval *op1, zval *op
|
||||
DO_BINARY_UI_OP(mpz_sub);
|
||||
case ZEND_MUL:
|
||||
DO_BINARY_UI_OP(mpz_mul);
|
||||
case ZEND_POW:
|
||||
shift_operator_helper(mpz_pow_ui, result, op1, op2 TSRMLS_CC);
|
||||
return SUCCESS;
|
||||
case ZEND_DIV:
|
||||
DO_BINARY_UI_OP_EX(mpz_tdiv_q, mpz_tdiv_q_ui, 1);
|
||||
case ZEND_MOD:
|
||||
|
||||
@@ -83,6 +83,10 @@ var_dump(--$a);
|
||||
var_dump($a--);
|
||||
var_dump($a);
|
||||
|
||||
$x = gmp_init(3);
|
||||
$y = gmp_init(2);
|
||||
var_dump($x ** $y);
|
||||
|
||||
?>
|
||||
--EXPECTF--
|
||||
object(GMP)#%d (1) {
|
||||
@@ -256,4 +260,7 @@ object(GMP)#%d (1) {
|
||||
["num"]=>
|
||||
string(2) "42"
|
||||
}
|
||||
|
||||
object(GMP)#%d (1) {
|
||||
["num"]=>
|
||||
string(1) "9"
|
||||
}
|
||||
+2
-2
@@ -190,10 +190,10 @@ static int json_determine_array_type(zval **val TSRMLS_DC) /* {{{ */
|
||||
}
|
||||
|
||||
if (i == HASH_KEY_IS_STRING) {
|
||||
return 1;
|
||||
return PHP_JSON_OUTPUT_OBJECT;
|
||||
} else {
|
||||
if (index != idx) {
|
||||
return 1;
|
||||
return PHP_JSON_OUTPUT_OBJECT;
|
||||
}
|
||||
}
|
||||
idx++;
|
||||
|
||||
@@ -0,0 +1,41 @@
|
||||
--TEST--
|
||||
libxml_disable_entity_loader()
|
||||
--SKIPIF--
|
||||
<?php if (!extension_loaded('libxml') || !extension_loaded('dom') || defined('PHP_WINDOWS_VERSION_MAJOR')) die('skip'); ?>
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
$xml = <<<EOT
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE test [<!ENTITY xxe SYSTEM "XXE_URI">]>
|
||||
<foo>&xxe;</foo>
|
||||
EOT;
|
||||
|
||||
$xml = str_replace('XXE_URI', __DIR__ . '/libxml_disable_entity_loader_payload.txt', $xml);
|
||||
|
||||
function parseXML($xml) {
|
||||
$doc = new DOMDocument();
|
||||
$doc->resolveExternals = true;
|
||||
$doc->substituteEntities = true;
|
||||
$doc->validateOnParse = false;
|
||||
$doc->loadXML($xml, 0);
|
||||
return $doc->saveXML();
|
||||
}
|
||||
|
||||
var_dump(strpos(parseXML($xml), 'SECRET_DATA') !== false);
|
||||
var_dump(libxml_disable_entity_loader(true));
|
||||
var_dump(strpos(parseXML($xml), 'SECRET_DATA') === false);
|
||||
|
||||
echo "Done\n";
|
||||
?>
|
||||
--EXPECTF--
|
||||
bool(true)
|
||||
bool(false)
|
||||
|
||||
Warning: DOMDocument::loadXML(): I/O warning : failed to load external entity "%s" in %s on line %d
|
||||
|
||||
Warning: DOMDocument::loadXML(): Failure to process entity xxe in Entity, line: %d in %s on line %d
|
||||
|
||||
Warning: DOMDocument::loadXML(): Entity 'xxe' not defined in Entity, line: %d in %s on line %d
|
||||
bool(true)
|
||||
Done
|
||||
@@ -0,0 +1 @@
|
||||
SECRET_DATA
|
||||
@@ -900,7 +900,11 @@ MYSQLND_METHOD(mysqlnd_net, enable_ssl)(MYSQLND_NET * const net TSRMLS_DC)
|
||||
ZVAL_STRING(&cipher_zval, net->data->options.ssl_cipher, 0);
|
||||
php_stream_context_set_option(context, "ssl", "ciphers", &cipher_zval);
|
||||
}
|
||||
#if PHP_API_VERSION >= 20131106
|
||||
php_stream_context_set(net_stream, context TSRMLS_CC);
|
||||
#else
|
||||
php_stream_context_set(net_stream, context);
|
||||
#endif
|
||||
if (php_stream_xport_crypto_setup(net_stream, STREAM_CRYPTO_METHOD_TLS_CLIENT, NULL TSRMLS_CC) < 0 ||
|
||||
php_stream_xport_crypto_enable(net_stream, 1 TSRMLS_CC) < 0)
|
||||
{
|
||||
@@ -916,7 +920,11 @@ MYSQLND_METHOD(mysqlnd_net, enable_ssl)(MYSQLND_NET * const net TSRMLS_DC)
|
||||
of the context, which means usage of already freed memory, bad. Actually we don't need this
|
||||
context anymore after we have enabled SSL on the connection. Thus it is very simple, we remove it.
|
||||
*/
|
||||
#if PHP_API_VERSION >= 20131106
|
||||
php_stream_context_set(net_stream, NULL TSRMLS_CC);
|
||||
#else
|
||||
php_stream_context_set(net_stream, NULL);
|
||||
#endif
|
||||
|
||||
if (net->data->options.timeout_read) {
|
||||
struct timeval tv;
|
||||
|
||||
@@ -38,6 +38,7 @@ const char * const mysqlnd_stmt_not_prepared = "Statement not prepared";
|
||||
|
||||
/* Exported by mysqlnd_ps_codec.c */
|
||||
enum_func_status mysqlnd_stmt_execute_generate_request(MYSQLND_STMT * const s, zend_uchar ** request, size_t *request_len, zend_bool * free_buffer TSRMLS_DC);
|
||||
enum_func_status mysqlnd_stmt_execute_batch_generate_request(MYSQLND_STMT * const s, zend_uchar ** request, size_t *request_len, zend_bool * free_buffer TSRMLS_DC);
|
||||
|
||||
enum_func_status mysqlnd_stmt_fetch_row_buffered(MYSQLND_RES *result, void *param,
|
||||
unsigned int flags,
|
||||
|
||||
@@ -1466,7 +1466,12 @@ static void zend_jmp_optimization(zend_code_block *block, zend_op_array *op_arra
|
||||
case ZEND_JMPNZ:
|
||||
/* constant conditional JMPs */
|
||||
if (ZEND_OP1_TYPE(last_op) == IS_CONST) {
|
||||
#if ZEND_EXTENSION_API_NO > PHP_5_6_X_API_NO
|
||||
int should_jmp = zend_is_true(&ZEND_OP1_LITERAL(last_op) TSRMLS_CC);
|
||||
#else
|
||||
int should_jmp = zend_is_true(&ZEND_OP1_LITERAL(last_op));
|
||||
#endif
|
||||
|
||||
if (last_op->opcode == ZEND_JMPZ) {
|
||||
should_jmp = !should_jmp;
|
||||
}
|
||||
@@ -1609,7 +1614,12 @@ next_target:
|
||||
case ZEND_JMPZ_EX:
|
||||
/* constant conditional JMPs */
|
||||
if (ZEND_OP1_TYPE(last_op) == IS_CONST) {
|
||||
#if ZEND_EXTENSION_API_NO > PHP_5_6_X_API_NO
|
||||
int should_jmp = zend_is_true(&ZEND_OP1_LITERAL(last_op) TSRMLS_CC);
|
||||
#else
|
||||
int should_jmp = zend_is_true(&ZEND_OP1_LITERAL(last_op));
|
||||
#endif
|
||||
|
||||
if (last_op->opcode == ZEND_JMPZ_EX) {
|
||||
should_jmp = !should_jmp;
|
||||
}
|
||||
@@ -1730,7 +1740,11 @@ next_target_ex:
|
||||
}
|
||||
|
||||
if (ZEND_OP1_TYPE(last_op) == IS_CONST) {
|
||||
#if ZEND_EXTENSION_API_NO > PHP_5_6_X_API_NO
|
||||
if (!zend_is_true(&ZEND_OP1_LITERAL(last_op) TSRMLS_CC)) {
|
||||
#else
|
||||
if (!zend_is_true(&ZEND_OP1_LITERAL(last_op))) {
|
||||
#endif
|
||||
/* JMPZNZ(false,L1,L2) -> JMP(L1) */
|
||||
zend_code_block *todel;
|
||||
|
||||
|
||||
@@ -89,7 +89,11 @@ if (ZEND_OPTIMIZER_PASS_2 & OPTIMIZATION_LEVEL) {
|
||||
/* convert Ti = JMPZ_EX(C, L) => Ti = QM_ASSIGN(C)
|
||||
in case we know it wouldn't jump */
|
||||
} else if (ZEND_OP1_TYPE(opline) == IS_CONST) {
|
||||
#if ZEND_EXTENSION_API_NO > PHP_5_6_X_API_NO
|
||||
int should_jmp = zend_is_true(&ZEND_OP1_LITERAL(opline) TSRMLS_CC);
|
||||
#else
|
||||
int should_jmp = zend_is_true(&ZEND_OP1_LITERAL(opline));
|
||||
#endif
|
||||
if (opline->opcode == ZEND_JMPZ_EX) {
|
||||
should_jmp = !should_jmp;
|
||||
}
|
||||
@@ -103,7 +107,11 @@ if (ZEND_OPTIMIZER_PASS_2 & OPTIMIZATION_LEVEL) {
|
||||
case ZEND_JMPZ:
|
||||
case ZEND_JMPNZ:
|
||||
if (ZEND_OP1_TYPE(opline) == IS_CONST) {
|
||||
#if ZEND_EXTENSION_API_NO > PHP_5_6_X_API_NO
|
||||
int should_jmp = zend_is_true(&ZEND_OP1_LITERAL(opline) TSRMLS_CC);
|
||||
#else
|
||||
int should_jmp = zend_is_true(&ZEND_OP1_LITERAL(opline));
|
||||
#endif
|
||||
|
||||
if (opline->opcode == ZEND_JMPZ) {
|
||||
should_jmp = !should_jmp;
|
||||
@@ -139,8 +147,11 @@ if (ZEND_OPTIMIZER_PASS_2 & OPTIMIZATION_LEVEL) {
|
||||
case ZEND_JMPZNZ:
|
||||
if (ZEND_OP1_TYPE(opline) == IS_CONST) {
|
||||
int opline_num;
|
||||
|
||||
#if ZEND_EXTENSION_API_NO > PHP_5_6_X_API_NO
|
||||
if (zend_is_true(&ZEND_OP1_LITERAL(opline) TSRMLS_CC)) {
|
||||
#else
|
||||
if (zend_is_true(&ZEND_OP1_LITERAL(opline))) {
|
||||
#endif
|
||||
opline_num = opline->extended_value; /* JMPNZ */
|
||||
} else {
|
||||
opline_num = ZEND_OP2(opline).opline_num; /* JMPZ */
|
||||
|
||||
@@ -2550,7 +2550,11 @@ static int accel_startup(zend_extension *extension)
|
||||
_setmaxstdio(2048); /* The default configuration is limited to 512 stdio files */
|
||||
#endif
|
||||
|
||||
#if ZEND_EXTENSION_API_NO > PHP_5_6_X_API_NO
|
||||
if (start_accel_module(TSRMLS_C) == FAILURE) {
|
||||
#else
|
||||
if (start_accel_module() == FAILURE) {
|
||||
#endif
|
||||
accel_startup_ok = 0;
|
||||
zend_error(E_WARNING, ACCELERATOR_PRODUCT_NAME ": module registration failed!");
|
||||
return FAILURE;
|
||||
|
||||
@@ -92,6 +92,7 @@
|
||||
#define PHP_5_3_X_API_NO 220090626
|
||||
#define PHP_5_4_X_API_NO 220100525
|
||||
#define PHP_5_5_X_API_NO 220121212
|
||||
#define PHP_5_6_X_API_NO 220131106
|
||||
|
||||
/*** file locking ***/
|
||||
#ifndef ZEND_WIN32
|
||||
|
||||
@@ -474,10 +474,17 @@ static zend_module_entry accel_module_entry = {
|
||||
STANDARD_MODULE_PROPERTIES
|
||||
};
|
||||
|
||||
#if ZEND_EXTENSION_API_NO > PHP_5_6_X_API_NO
|
||||
int start_accel_module(TSRMLS_D)
|
||||
{
|
||||
return zend_startup_module(&accel_module_entry TSRMLS_CC);
|
||||
}
|
||||
#else
|
||||
int start_accel_module(void)
|
||||
{
|
||||
return zend_startup_module(&accel_module_entry);
|
||||
}
|
||||
#endif
|
||||
|
||||
/* {{{ proto array accelerator_get_scripts()
|
||||
Get the scripts which are accelerated by ZendAccelerator */
|
||||
|
||||
@@ -22,7 +22,12 @@
|
||||
#ifndef ZEND_ACCELERATOR_MODULE_H
|
||||
#define ZEND_ACCELERATOR_MODULE_H
|
||||
|
||||
#if ZEND_EXTENSION_API_NO > PHP_5_6_X_API_NO
|
||||
int start_accel_module(TSRMLS_D);
|
||||
#else
|
||||
int start_accel_module(void);
|
||||
#endif
|
||||
|
||||
void zend_accel_override_file_functions(TSRMLS_D);
|
||||
|
||||
#endif /* _ZEND_ACCELERATOR_MODULE_H */
|
||||
@@ -407,7 +407,7 @@ static inline int php_openssl_setup_crypto(php_stream *stream,
|
||||
|
||||
if (stream->context && SUCCESS == php_stream_context_get_option(
|
||||
stream->context, "ssl", "no_ticket", &val) &&
|
||||
zend_is_true(*val)
|
||||
zend_is_true(*val TSRMLS_CC)
|
||||
) {
|
||||
SSL_CTX_set_options(sslsock->ctx, SSL_OP_NO_TICKET);
|
||||
}
|
||||
@@ -420,7 +420,7 @@ static inline int php_openssl_setup_crypto(php_stream *stream,
|
||||
|
||||
if (stream->context && SUCCESS == php_stream_context_get_option(
|
||||
stream->context, "ssl", "disable_compression", &val) &&
|
||||
zend_is_true(*val)
|
||||
zend_is_true(*val TSRMLS_CC)
|
||||
) {
|
||||
SSL_CTX_set_options(sslsock->ctx, SSL_OP_NO_COMPRESSION);
|
||||
}
|
||||
@@ -471,7 +471,7 @@ static inline int php_openssl_enable_crypto(php_stream *stream,
|
||||
|
||||
if (sslsock->is_client
|
||||
&& (php_stream_context_get_option(stream->context, "ssl", "SNI_enabled", &val) == FAILURE
|
||||
|| zend_is_true(*val))
|
||||
|| zend_is_true(*val TSRMLS_CC))
|
||||
) {
|
||||
if (php_stream_context_get_option(stream->context, "ssl", "SNI_server_name", &val) == SUCCESS) {
|
||||
convert_to_string_ex(val);
|
||||
@@ -578,7 +578,7 @@ static inline int php_openssl_enable_crypto(php_stream *stream,
|
||||
if (SUCCESS == php_stream_context_get_option(
|
||||
stream->context, "ssl",
|
||||
"capture_peer_cert", &val) &&
|
||||
zend_is_true(*val)) {
|
||||
zend_is_true(*val TSRMLS_CC)) {
|
||||
MAKE_STD_ZVAL(zcert);
|
||||
ZVAL_RESOURCE(zcert, zend_list_insert(peer_cert,
|
||||
php_openssl_get_x509_list_id() TSRMLS_CC));
|
||||
@@ -592,7 +592,7 @@ static inline int php_openssl_enable_crypto(php_stream *stream,
|
||||
if (SUCCESS == php_stream_context_get_option(
|
||||
stream->context, "ssl",
|
||||
"capture_peer_cert_chain", &val) &&
|
||||
zend_is_true(*val)) {
|
||||
zend_is_true(*val TSRMLS_CC)) {
|
||||
zval *arr;
|
||||
STACK_OF(X509) *chain;
|
||||
|
||||
|
||||
+1
-1
@@ -499,7 +499,7 @@ PHP_MINIT_FUNCTION(pcntl)
|
||||
{
|
||||
php_register_signal_constants(INIT_FUNC_ARGS_PASSTHRU);
|
||||
php_pcntl_register_errno_constants(INIT_FUNC_ARGS_PASSTHRU);
|
||||
php_add_tick_function(pcntl_signal_dispatch);
|
||||
php_add_tick_function(pcntl_signal_dispatch TSRMLS_CC);
|
||||
|
||||
return SUCCESS;
|
||||
}
|
||||
|
||||
@@ -1189,7 +1189,7 @@ static xmlNodePtr to_xml_bool(encodeTypePtr type, zval *data, int style, xmlNode
|
||||
xmlAddChild(parent, ret);
|
||||
FIND_ZVAL_NULL(data, ret, style);
|
||||
|
||||
if (zend_is_true(data)) {
|
||||
if (zend_is_true(data TSRMLS_CC)) {
|
||||
xmlNodeSetContent(ret, BAD_CAST("true"));
|
||||
} else {
|
||||
xmlNodeSetContent(ret, BAD_CAST("false"));
|
||||
|
||||
+3
-3
@@ -599,7 +599,7 @@ static int spl_array_has_dimension_ex(int check_inherited, zval *object, zval *o
|
||||
SEPARATE_ARG_IF_REF(offset);
|
||||
zend_call_method_with_1_params(&object, Z_OBJCE_P(object), &intern->fptr_offset_has, "offsetExists", &rv, offset);
|
||||
zval_ptr_dtor(&offset);
|
||||
if (rv && zend_is_true(rv)) {
|
||||
if (rv && zend_is_true(rv TSRMLS_CC)) {
|
||||
zval_ptr_dtor(&rv);
|
||||
return 1;
|
||||
}
|
||||
@@ -620,7 +620,7 @@ static int spl_array_has_dimension_ex(int check_inherited, zval *object, zval *o
|
||||
case 2:
|
||||
return 1;
|
||||
default:
|
||||
return zend_is_true(*tmp);
|
||||
return zend_is_true(*tmp TSRMLS_CC);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -643,7 +643,7 @@ static int spl_array_has_dimension_ex(int check_inherited, zval *object, zval *o
|
||||
case 2:
|
||||
return 1;
|
||||
default:
|
||||
return zend_is_true(*tmp);
|
||||
return zend_is_true(*tmp TSRMLS_CC);
|
||||
}
|
||||
}
|
||||
return 0;
|
||||
|
||||
@@ -836,7 +836,7 @@ SPL_METHOD(DirectoryIterator, seek)
|
||||
int valid = 0;
|
||||
zend_call_method_with_0_params(&this_ptr, Z_OBJCE_P(getThis()), &intern->u.dir.func_valid, "valid", &retval);
|
||||
if (retval) {
|
||||
valid = zend_is_true(retval);
|
||||
valid = zend_is_true(retval TSRMLS_CC);
|
||||
zval_ptr_dtor(&retval);
|
||||
}
|
||||
if (!valid) {
|
||||
@@ -1497,7 +1497,7 @@ SPL_METHOD(RecursiveDirectoryIterator, hasChildren)
|
||||
spl_filesystem_object_get_file_name(intern TSRMLS_CC);
|
||||
if (!allow_links && !(intern->flags & SPL_FILE_DIR_FOLLOW_SYMLINKS)) {
|
||||
php_stat(intern->file_name, intern->file_name_len, FS_IS_LINK, return_value TSRMLS_CC);
|
||||
if (zend_is_true(return_value)) {
|
||||
if (zend_is_true(return_value TSRMLS_CC)) {
|
||||
RETURN_FALSE;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -511,7 +511,7 @@ static inline int spl_fixedarray_object_has_dimension_helper(spl_fixedarray_obje
|
||||
if (!intern->array->elements[index]) {
|
||||
retval = 0;
|
||||
} else if (check_empty) {
|
||||
if (zend_is_true(intern->array->elements[index])) {
|
||||
if (zend_is_true(intern->array->elements[index] TSRMLS_CC)) {
|
||||
retval = 1;
|
||||
} else {
|
||||
retval = 0;
|
||||
@@ -540,7 +540,7 @@ static int spl_fixedarray_object_has_dimension(zval *object, zval *offset, int c
|
||||
zval_ptr_dtor(&intern->retval);
|
||||
MAKE_STD_ZVAL(intern->retval);
|
||||
ZVAL_ZVAL(intern->retval, rv, 1, 1);
|
||||
return zend_is_true(intern->retval);
|
||||
return zend_is_true(intern->retval TSRMLS_CC);
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -249,7 +249,7 @@ next_step:
|
||||
}
|
||||
}
|
||||
if (retval) {
|
||||
has_children = zend_is_true(retval);
|
||||
has_children = zend_is_true(retval TSRMLS_CC);
|
||||
zval_ptr_dtor(&retval);
|
||||
if (has_children) {
|
||||
if (object->max_depth == -1 || object->max_depth > object->level) {
|
||||
@@ -1774,7 +1774,7 @@ static inline void spl_filter_it_fetch(zval *zthis, spl_dual_it_object *intern T
|
||||
while (spl_dual_it_fetch(intern, 1 TSRMLS_CC) == SUCCESS) {
|
||||
zend_call_method_with_0_params(&zthis, intern->std.ce, NULL, "accept", &retval);
|
||||
if (retval) {
|
||||
if (zend_is_true(retval)) {
|
||||
if (zend_is_true(retval TSRMLS_CC)) {
|
||||
zval_ptr_dtor(&retval);
|
||||
return;
|
||||
}
|
||||
@@ -2598,7 +2598,7 @@ static inline void spl_caching_it_next(spl_dual_it_object *intern TSRMLS_DC)
|
||||
return;
|
||||
}
|
||||
} else {
|
||||
if (zend_is_true(retval)) {
|
||||
if (zend_is_true(retval TSRMLS_CC)) {
|
||||
zend_call_method_with_0_params(&intern->inner.zobject, intern->inner.ce, NULL, "getchildren", &zchildren);
|
||||
if (EG(exception)) {
|
||||
if (zchildren) {
|
||||
@@ -3573,7 +3573,7 @@ static int spl_iterator_func_apply(zend_object_iterator *iter, void *puser TSRML
|
||||
apply_info->count++;
|
||||
zend_fcall_info_call(&apply_info->fci, &apply_info->fcc, &retval, NULL TSRMLS_CC);
|
||||
if (retval) {
|
||||
result = zend_is_true(retval) ? ZEND_HASH_APPLY_KEEP : ZEND_HASH_APPLY_STOP;
|
||||
result = zend_is_true(retval TSRMLS_CC) ? ZEND_HASH_APPLY_KEEP : ZEND_HASH_APPLY_STOP;
|
||||
zval_ptr_dtor(&retval);
|
||||
} else {
|
||||
result = ZEND_HASH_APPLY_STOP;
|
||||
|
||||
@@ -4277,7 +4277,7 @@ PHP_FUNCTION(array_filter)
|
||||
fci.params = args;
|
||||
|
||||
if (zend_call_function(&fci, &fci_cache TSRMLS_CC) == SUCCESS && retval) {
|
||||
int retval_true = zend_is_true(retval);
|
||||
int retval_true = zend_is_true(retval TSRMLS_CC);
|
||||
|
||||
zval_ptr_dtor(&retval);
|
||||
if (use_type) {
|
||||
@@ -4290,7 +4290,7 @@ PHP_FUNCTION(array_filter)
|
||||
php_error_docref(NULL TSRMLS_CC, E_WARNING, "An error occurred while invoking the filter callback");
|
||||
return;
|
||||
}
|
||||
} else if (!zend_is_true(*operand)) {
|
||||
} else if (!zend_is_true(*operand TSRMLS_CC)) {
|
||||
continue;
|
||||
}
|
||||
|
||||
|
||||
@@ -5751,7 +5751,7 @@ PHP_FUNCTION(register_tick_function)
|
||||
zend_llist_init(BG(user_tick_functions),
|
||||
sizeof(user_tick_function_entry),
|
||||
(llist_dtor_func_t) user_tick_function_dtor, 0);
|
||||
php_add_tick_function(run_user_tick_functions);
|
||||
php_add_tick_function(run_user_tick_functions TSRMLS_CC);
|
||||
}
|
||||
|
||||
for (i = 0; i < tick_fe.arg_count; i++) {
|
||||
|
||||
@@ -163,7 +163,7 @@ static php_stream *php_ftp_fopen_connect(php_stream_wrapper *wrapper, const char
|
||||
goto connect_errexit;
|
||||
}
|
||||
|
||||
php_stream_context_set(stream, context);
|
||||
php_stream_context_set(stream, context TSRMLS_CC);
|
||||
php_stream_notify_info(context, PHP_STREAM_NOTIFY_CONNECT, NULL, 0);
|
||||
|
||||
/* Start talking to ftp server */
|
||||
@@ -571,7 +571,7 @@ php_stream * php_stream_url_wrap_ftp(php_stream_wrapper *wrapper, const char *pa
|
||||
goto errexit;
|
||||
}
|
||||
|
||||
php_stream_context_set(datastream, context);
|
||||
php_stream_context_set(datastream, context TSRMLS_CC);
|
||||
php_stream_notify_progress_init(context, 0, file_size);
|
||||
|
||||
if (use_ssl_on_data && (php_stream_xport_crypto_setup(datastream,
|
||||
@@ -745,7 +745,7 @@ php_stream * php_stream_ftp_opendir(php_stream_wrapper *wrapper, const char *pat
|
||||
goto opendir_errexit;
|
||||
}
|
||||
|
||||
php_stream_context_set(datastream, context);
|
||||
php_stream_context_set(datastream, context TSRMLS_CC);
|
||||
|
||||
if (use_ssl_on_data && (php_stream_xport_crypto_setup(stream,
|
||||
STREAM_CRYPTO_METHOD_SSLv23_CLIENT, NULL TSRMLS_CC) < 0 ||
|
||||
|
||||
@@ -337,7 +337,7 @@ finish:
|
||||
eol_detect = stream->flags & (PHP_STREAM_FLAG_DETECT_EOL | PHP_STREAM_FLAG_EOL_MAC);
|
||||
stream->flags &= ~(PHP_STREAM_FLAG_DETECT_EOL | PHP_STREAM_FLAG_EOL_MAC);
|
||||
|
||||
php_stream_context_set(stream, context);
|
||||
php_stream_context_set(stream, context TSRMLS_CC);
|
||||
|
||||
php_stream_notify_info(context, PHP_STREAM_NOTIFY_CONNECT, NULL, 0);
|
||||
|
||||
@@ -682,7 +682,7 @@ finish:
|
||||
response_code = 0;
|
||||
}
|
||||
if (context && SUCCESS==php_stream_context_get_option(context, "http", "ignore_errors", &tmpzval)) {
|
||||
ignore_errors = zend_is_true(*tmpzval);
|
||||
ignore_errors = zend_is_true(*tmpzval TSRMLS_CC);
|
||||
}
|
||||
/* when we request only the header, don't fail even on error codes */
|
||||
if ((options & STREAM_ONLY_GET_HEADERS) || ignore_errors) {
|
||||
|
||||
+1
-37
@@ -604,43 +604,7 @@ PHP_FUNCTION(pow)
|
||||
return;
|
||||
}
|
||||
|
||||
/* make sure we're dealing with numbers */
|
||||
convert_scalar_to_number(zbase TSRMLS_CC);
|
||||
convert_scalar_to_number(zexp TSRMLS_CC);
|
||||
|
||||
/* if both base and exponent were longs, we'll try to get a long out */
|
||||
if (Z_TYPE_P(zbase) == IS_LONG && Z_TYPE_P(zexp) == IS_LONG && Z_LVAL_P(zexp) >= 0) {
|
||||
long l1 = 1, l2 = Z_LVAL_P(zbase), i = Z_LVAL_P(zexp);
|
||||
|
||||
if (i == 0) {
|
||||
RETURN_LONG(1L);
|
||||
} else if (l2 == 0) {
|
||||
RETURN_LONG(0);
|
||||
}
|
||||
|
||||
/* calculate pow(long,long) in O(log exp) operations, bail if overflow */
|
||||
while (i >= 1) {
|
||||
long overflow;
|
||||
double dval = 0.0;
|
||||
|
||||
if (i % 2) {
|
||||
--i;
|
||||
ZEND_SIGNED_MULTIPLY_LONG(l1,l2,l1,dval,overflow);
|
||||
if (overflow) RETURN_DOUBLE(dval * pow(l2,i));
|
||||
} else {
|
||||
i /= 2;
|
||||
ZEND_SIGNED_MULTIPLY_LONG(l2,l2,l2,dval,overflow);
|
||||
if (overflow) RETURN_DOUBLE((double)l1 * pow(dval,i));
|
||||
}
|
||||
if (i == 0) {
|
||||
RETURN_LONG(l1);
|
||||
}
|
||||
}
|
||||
}
|
||||
convert_to_double(zbase);
|
||||
convert_to_double(zexp);
|
||||
|
||||
RETURN_DOUBLE(pow(Z_DVAL_P(zbase), Z_DVAL_P(zexp)));
|
||||
pow_function(return_value, zbase, zexp TSRMLS_CC);
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
|
||||
@@ -0,0 +1,22 @@
|
||||
--TEST--
|
||||
Various pow() tests
|
||||
--FILE--
|
||||
<?php // $Id$
|
||||
|
||||
$x = 2;
|
||||
$x **= 3;
|
||||
|
||||
$tests = <<<TESTS
|
||||
-3 ** 2 === -9
|
||||
(-3) **2 === 9
|
||||
2 ** 3 ** 2 === 512
|
||||
(2 ** 3) ** 2 === 64
|
||||
$x === 8
|
||||
TESTS;
|
||||
|
||||
echo "On failure, please mail result to php-dev@lists.php.net\n";
|
||||
include(dirname(__FILE__) . '/../../../../tests/quicktester.inc');
|
||||
|
||||
--EXPECT--
|
||||
On failure, please mail result to php-dev@lists.php.net
|
||||
OK
|
||||
@@ -149,7 +149,7 @@ int(0)
|
||||
int(0)
|
||||
|
||||
-- Iteration 19 --
|
||||
float(0)
|
||||
int(0)
|
||||
|
||||
-- Iteration 20 --
|
||||
int(0)
|
||||
|
||||
@@ -149,7 +149,7 @@ int(0)
|
||||
int(0)
|
||||
|
||||
-- Iteration 19 --
|
||||
float(0)
|
||||
int(0)
|
||||
|
||||
-- Iteration 20 --
|
||||
int(0)
|
||||
@@ -173,4 +173,4 @@ int(0)
|
||||
|
||||
-- Iteration 26 --
|
||||
%s
|
||||
===Done===
|
||||
===Done===
|
||||
+1
-1
@@ -186,7 +186,7 @@ PHP_FUNCTION(boolval)
|
||||
return;
|
||||
}
|
||||
|
||||
RETURN_BOOL(zend_is_true(*val));
|
||||
RETURN_BOOL(zend_is_true(*val TSRMLS_CC));
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
|
||||
@@ -17,7 +17,7 @@ array(14) {
|
||||
[0]=>
|
||||
array(3) {
|
||||
[0]=>
|
||||
int(374)
|
||||
int(376)
|
||||
[1]=>
|
||||
string(6) "<?php
|
||||
"
|
||||
@@ -27,7 +27,7 @@ array(14) {
|
||||
[1]=>
|
||||
array(3) {
|
||||
[0]=>
|
||||
int(378)
|
||||
int(380)
|
||||
[1]=>
|
||||
string(8) "<<<DOC1
|
||||
"
|
||||
@@ -37,7 +37,7 @@ array(14) {
|
||||
[2]=>
|
||||
array(3) {
|
||||
[0]=>
|
||||
int(381)
|
||||
int(383)
|
||||
[1]=>
|
||||
string(1) "{"
|
||||
[2]=>
|
||||
@@ -46,7 +46,7 @@ array(14) {
|
||||
[3]=>
|
||||
array(3) {
|
||||
[0]=>
|
||||
int(310)
|
||||
int(312)
|
||||
[1]=>
|
||||
string(2) "$s"
|
||||
[2]=>
|
||||
@@ -57,7 +57,7 @@ array(14) {
|
||||
[5]=>
|
||||
array(3) {
|
||||
[0]=>
|
||||
int(378)
|
||||
int(380)
|
||||
[1]=>
|
||||
string(8) "<<<DOC2
|
||||
"
|
||||
@@ -67,7 +67,7 @@ array(14) {
|
||||
[6]=>
|
||||
array(3) {
|
||||
[0]=>
|
||||
int(379)
|
||||
int(381)
|
||||
[1]=>
|
||||
string(4) "DOC2"
|
||||
[2]=>
|
||||
@@ -76,7 +76,7 @@ array(14) {
|
||||
[7]=>
|
||||
array(3) {
|
||||
[0]=>
|
||||
int(377)
|
||||
int(379)
|
||||
[1]=>
|
||||
string(1) "
|
||||
"
|
||||
@@ -90,7 +90,7 @@ array(14) {
|
||||
[10]=>
|
||||
array(3) {
|
||||
[0]=>
|
||||
int(315)
|
||||
int(317)
|
||||
[1]=>
|
||||
string(1) "
|
||||
"
|
||||
@@ -100,7 +100,7 @@ array(14) {
|
||||
[11]=>
|
||||
array(3) {
|
||||
[0]=>
|
||||
int(379)
|
||||
int(381)
|
||||
[1]=>
|
||||
string(4) "DOC1"
|
||||
[2]=>
|
||||
@@ -111,7 +111,7 @@ array(14) {
|
||||
[13]=>
|
||||
array(3) {
|
||||
[0]=>
|
||||
int(377)
|
||||
int(379)
|
||||
[1]=>
|
||||
string(1) "
|
||||
"
|
||||
|
||||
+4
-21
@@ -57,8 +57,8 @@ zend_module_entry xsl_module_entry = {
|
||||
xsl_functions,
|
||||
PHP_MINIT(xsl),
|
||||
PHP_MSHUTDOWN(xsl),
|
||||
PHP_RINIT(xsl), /* Replace with NULL if there's nothing to do at request start */
|
||||
PHP_RSHUTDOWN(xsl), /* Replace with NULL if there's nothing to do at request end */
|
||||
NULL,
|
||||
NULL,
|
||||
PHP_MINFO(xsl),
|
||||
#if ZEND_MODULE_API_NO >= 20010901
|
||||
"0.1", /* Replace with version number for your extension */
|
||||
@@ -170,6 +170,7 @@ PHP_MINIT_FUNCTION(xsl)
|
||||
xsltRegisterExtModuleFunction ((const xmlChar *) "function",
|
||||
(const xmlChar *) "http://php.net/xsl",
|
||||
xsl_ext_function_object_php);
|
||||
xsltSetGenericErrorFunc(NULL, php_libxml_error_handler);
|
||||
|
||||
REGISTER_LONG_CONSTANT("XSL_CLONE_AUTO", 0, CONST_CS | CONST_PERSISTENT);
|
||||
REGISTER_LONG_CONSTANT("XSL_CLONE_NEVER", -1, CONST_CS | CONST_PERSISTENT);
|
||||
@@ -273,7 +274,7 @@ PHP_MSHUTDOWN_FUNCTION(xsl)
|
||||
(const xmlChar *) "http://php.net/xsl");
|
||||
xsltUnregisterExtModuleFunction ((const xmlChar *) "function",
|
||||
(const xmlChar *) "http://php.net/xsl");
|
||||
|
||||
xsltSetGenericErrorFunc(NULL, NULL);
|
||||
xsltCleanupGlobals();
|
||||
|
||||
UNREGISTER_INI_ENTRIES();
|
||||
@@ -282,24 +283,6 @@ PHP_MSHUTDOWN_FUNCTION(xsl)
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
/* {{{ PHP_RINIT_FUNCTION
|
||||
*/
|
||||
PHP_RINIT_FUNCTION(xsl)
|
||||
{
|
||||
xsltSetGenericErrorFunc(NULL, php_libxml_error_handler);
|
||||
return SUCCESS;
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
/* {{{ PHP_RSHUTDOWN_FUNCTION
|
||||
*/
|
||||
PHP_RSHUTDOWN_FUNCTION(xsl)
|
||||
{
|
||||
xsltSetGenericErrorFunc(NULL, NULL);
|
||||
return SUCCESS;
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
/* {{{ PHP_MINFO_FUNCTION
|
||||
*/
|
||||
PHP_MINFO_FUNCTION(xsl)
|
||||
|
||||
+1
-1
@@ -999,7 +999,7 @@ SAPI_API int sapi_register_input_filter(unsigned int (*input_filter)(int arg, ch
|
||||
SAPI_API int sapi_flush(TSRMLS_D)
|
||||
{
|
||||
if (sapi_module.flush) {
|
||||
sapi_module.flush(SG(server_context));
|
||||
sapi_module.flush(SG(server_context) TSRMLS_CC);
|
||||
return SUCCESS;
|
||||
} else {
|
||||
return FAILURE;
|
||||
|
||||
+1
-1
@@ -227,7 +227,7 @@ struct _sapi_module_struct {
|
||||
int (*deactivate)(TSRMLS_D);
|
||||
|
||||
int (*ub_write)(const char *str, unsigned int str_length TSRMLS_DC);
|
||||
void (*flush)(void *server_context);
|
||||
void (*flush)(void *server_context TSRMLS_DC);
|
||||
struct stat *(*get_stat)(TSRMLS_D);
|
||||
char *(*getenv)(char *name, size_t name_len TSRMLS_DC);
|
||||
|
||||
|
||||
+12
-47
@@ -179,7 +179,7 @@ static PHP_INI_MH(OnChangeMemoryLimit)
|
||||
} else {
|
||||
PG(memory_limit) = 1<<30; /* effectively, no limit */
|
||||
}
|
||||
return zend_set_memory_limit(PG(memory_limit));
|
||||
return zend_set_memory_limit(PG(memory_limit) TSRMLS_CC);
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
@@ -460,40 +460,6 @@ static PHP_INI_MH(OnChangeMailForceExtra)
|
||||
/* defined in browscap.c */
|
||||
PHP_INI_MH(OnChangeBrowscap);
|
||||
|
||||
/* {{{ PHP_INI_MH
|
||||
*/
|
||||
static PHP_INI_MH(OnChangeAlwaysPopulateRawPostData)
|
||||
{
|
||||
signed char *p;
|
||||
#ifndef ZTS
|
||||
char *base = (char *) mh_arg2;
|
||||
#else
|
||||
char *base;
|
||||
|
||||
base = (char *) ts_resource(*((int *) mh_arg2));
|
||||
#endif
|
||||
|
||||
p = (signed char *) (base+(size_t) mh_arg1);
|
||||
|
||||
*p = zend_atol(new_value, new_value_length);
|
||||
if (new_value_length == 2 && strcasecmp("on", new_value) == 0) {
|
||||
*p = (signed char) 1;
|
||||
}
|
||||
else if (new_value_length == 3 && strcasecmp("yes", new_value) == 0) {
|
||||
*p = (signed char) 1;
|
||||
}
|
||||
else if (new_value_length == 4 && strcasecmp("true", new_value) == 0) {
|
||||
*p = (signed char) 1;
|
||||
}
|
||||
else if (new_value_length == 5 && strcasecmp("never", new_value) == 0) {
|
||||
*p = (signed char) -1;
|
||||
}
|
||||
else {
|
||||
*p = (signed char) atoi(new_value);
|
||||
}
|
||||
return SUCCESS;
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
/* Need to be read from the environment (?):
|
||||
* PHP_AUTO_PREPEND_FILE
|
||||
@@ -596,7 +562,6 @@ PHP_INI_BEGIN()
|
||||
STD_PHP_INI_BOOLEAN("allow_url_fopen", "1", PHP_INI_SYSTEM, OnUpdateBool, allow_url_fopen, php_core_globals, core_globals)
|
||||
STD_PHP_INI_BOOLEAN("allow_url_include", "0", PHP_INI_SYSTEM, OnUpdateBool, allow_url_include, php_core_globals, core_globals)
|
||||
STD_PHP_INI_BOOLEAN("enable_post_data_reading", "1", PHP_INI_SYSTEM|PHP_INI_PERDIR, OnUpdateBool, enable_post_data_reading, php_core_globals, core_globals)
|
||||
STD_PHP_INI_ENTRY("always_populate_raw_post_data", "0", PHP_INI_SYSTEM|PHP_INI_PERDIR, OnChangeAlwaysPopulateRawPostData, always_populate_raw_post_data, php_core_globals, core_globals)
|
||||
|
||||
STD_PHP_INI_ENTRY("realpath_cache_size", "16K", PHP_INI_SYSTEM, OnUpdateLong, realpath_cache_size_limit, virtual_cwd_globals, cwd_globals)
|
||||
STD_PHP_INI_ENTRY("realpath_cache_ttl", "120", PHP_INI_SYSTEM, OnUpdateLong, realpath_cache_ttl, virtual_cwd_globals, cwd_globals)
|
||||
@@ -1201,7 +1166,7 @@ static void php_error_cb(int type, const char *error_filename, const uint error_
|
||||
CG(parse_error) = 0;
|
||||
} else {
|
||||
/* restore memory limit */
|
||||
zend_set_memory_limit(PG(memory_limit));
|
||||
zend_set_memory_limit(PG(memory_limit) TSRMLS_CC);
|
||||
efree(buffer);
|
||||
zend_objects_store_mark_destructed(&EG(objects_store) TSRMLS_CC);
|
||||
zend_bailout();
|
||||
@@ -1828,7 +1793,7 @@ void php_request_shutdown(void *dummy)
|
||||
}
|
||||
} zend_end_try();
|
||||
|
||||
/* 7.5 free last error information */
|
||||
/* 8. free last error information */
|
||||
if (PG(last_error_message)) {
|
||||
free(PG(last_error_message));
|
||||
PG(last_error_message) = NULL;
|
||||
@@ -1838,34 +1803,34 @@ void php_request_shutdown(void *dummy)
|
||||
PG(last_error_file) = NULL;
|
||||
}
|
||||
|
||||
/* 7. Shutdown scanner/executor/compiler and restore ini entries */
|
||||
/* 9. Shutdown scanner/executor/compiler and restore ini entries */
|
||||
zend_deactivate(TSRMLS_C);
|
||||
|
||||
/* 8. Call all extensions post-RSHUTDOWN functions */
|
||||
/* 10. Call all extensions post-RSHUTDOWN functions */
|
||||
zend_try {
|
||||
zend_post_deactivate_modules(TSRMLS_C);
|
||||
} zend_end_try();
|
||||
|
||||
/* 9. SAPI related shutdown (free stuff) */
|
||||
/* 11. SAPI related shutdown (free stuff) */
|
||||
zend_try {
|
||||
sapi_deactivate(TSRMLS_C);
|
||||
} zend_end_try();
|
||||
|
||||
/* 9.5 free virtual CWD memory */
|
||||
/* 12. free virtual CWD memory */
|
||||
virtual_cwd_deactivate(TSRMLS_C);
|
||||
|
||||
/* 10. Destroy stream hashes */
|
||||
/* 13. Destroy stream hashes */
|
||||
zend_try {
|
||||
php_shutdown_stream_hashes(TSRMLS_C);
|
||||
} zend_end_try();
|
||||
|
||||
/* 11. Free Willy (here be crashes) */
|
||||
/* 14. Free Willy (here be crashes) */
|
||||
zend_try {
|
||||
shutdown_memory_manager(CG(unclean_shutdown) || !report_memleaks, 0 TSRMLS_CC);
|
||||
} zend_end_try();
|
||||
zend_interned_strings_restore(TSRMLS_C);
|
||||
|
||||
/* 12. Reset max_execution_time */
|
||||
/* 15. Reset max_execution_time */
|
||||
zend_try {
|
||||
zend_unset_timeout(TSRMLS_C);
|
||||
} zend_end_try();
|
||||
@@ -2678,9 +2643,9 @@ PHPAPI int php_lint_script(zend_file_handle *file TSRMLS_DC)
|
||||
#ifdef PHP_WIN32
|
||||
/* {{{ dummy_indent
|
||||
just so that this symbol gets exported... */
|
||||
PHPAPI void dummy_indent(void)
|
||||
PHPAPI void dummy_indent(TSRMLS_D)
|
||||
{
|
||||
zend_indent();
|
||||
zend_indent(TSRMLS_C);
|
||||
}
|
||||
/* }}} */
|
||||
#endif
|
||||
|
||||
+1
-1
@@ -26,7 +26,7 @@
|
||||
#include <dmalloc.h>
|
||||
#endif
|
||||
|
||||
#define PHP_API_VERSION 20131106
|
||||
#define PHP_API_VERSION 20131218
|
||||
#define PHP_HAVE_STREAMS
|
||||
#define YYDEBUG 0
|
||||
|
||||
|
||||
@@ -33,19 +33,6 @@ static sapi_post_entry php_post_entries[] = {
|
||||
};
|
||||
/* }}} */
|
||||
|
||||
static zend_bool populate_raw_post_data(TSRMLS_D)
|
||||
{
|
||||
if (!SG(request_info).request_body) {
|
||||
return (zend_bool) 0;
|
||||
}
|
||||
|
||||
if (!PG(always_populate_raw_post_data)) {
|
||||
return (zend_bool) !SG(request_info).post_entry;
|
||||
}
|
||||
|
||||
return (zend_bool) (PG(always_populate_raw_post_data) > 0);
|
||||
}
|
||||
|
||||
/* {{{ SAPI_POST_READER_FUNC
|
||||
*/
|
||||
SAPI_API SAPI_POST_READER_FUNC(php_default_post_reader)
|
||||
@@ -55,23 +42,6 @@ SAPI_API SAPI_POST_READER_FUNC(php_default_post_reader)
|
||||
/* no post handler registered, so we just swallow the data */
|
||||
sapi_read_standard_form_data(TSRMLS_C);
|
||||
}
|
||||
|
||||
if (populate_raw_post_data(TSRMLS_C)) {
|
||||
size_t length;
|
||||
char *data = NULL;
|
||||
|
||||
php_stream_rewind(SG(request_info).request_body);
|
||||
length = php_stream_copy_to_mem(SG(request_info).request_body, &data, PHP_STREAM_COPY_ALL, 0);
|
||||
php_stream_rewind(SG(request_info).request_body);
|
||||
|
||||
SET_VAR_STRINGL("HTTP_RAW_POST_DATA", data, length);
|
||||
|
||||
sapi_module.sapi_error(E_DEPRECATED,
|
||||
"Automatically populating $HTTP_RAW_POST_DATA is deprecated and "
|
||||
"will be removed in a future version. To avoid this warning set "
|
||||
"'always_populate_raw_post_data' to '-1' in php.ini and use the "
|
||||
"php://input stream instead.");
|
||||
}
|
||||
}
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
@@ -131,7 +131,6 @@ struct _php_core_globals {
|
||||
zend_bool during_request_startup;
|
||||
zend_bool allow_url_fopen;
|
||||
zend_bool enable_post_data_reading;
|
||||
signed char always_populate_raw_post_data;
|
||||
zend_bool report_zend_debug;
|
||||
|
||||
int last_error_type;
|
||||
|
||||
+2
-2
@@ -361,7 +361,7 @@ static void php_load_zend_extension_cb(void *arg TSRMLS_DC)
|
||||
int length = strlen(filename);
|
||||
|
||||
if (IS_ABSOLUTE_PATH(filename, length)) {
|
||||
zend_load_extension(filename);
|
||||
zend_load_extension(filename TSRMLS_CC);
|
||||
} else {
|
||||
char *libpath;
|
||||
char *extension_dir = INI_STR("extension_dir");
|
||||
@@ -372,7 +372,7 @@ static void php_load_zend_extension_cb(void *arg TSRMLS_DC)
|
||||
} else {
|
||||
spprintf(&libpath, 0, "%s%c%s", extension_dir, DEFAULT_SLASH, filename);
|
||||
}
|
||||
zend_load_extension(libpath);
|
||||
zend_load_extension(libpath TSRMLS_CC);
|
||||
efree(libpath);
|
||||
}
|
||||
}
|
||||
|
||||
+3
-9
@@ -46,17 +46,13 @@ static int php_compare_tick_functions(void *elem1, void *elem2)
|
||||
return (func1 == func2);
|
||||
}
|
||||
|
||||
PHPAPI void php_add_tick_function(void (*func)(int))
|
||||
PHPAPI void php_add_tick_function(void (*func)(int) TSRMLS_DC)
|
||||
{
|
||||
TSRMLS_FETCH();
|
||||
|
||||
zend_llist_add_element(&PG(tick_functions), (void *)&func);
|
||||
}
|
||||
|
||||
PHPAPI void php_remove_tick_function(void (*func)(int))
|
||||
PHPAPI void php_remove_tick_function(void (*func)(int) TSRMLS_DC)
|
||||
{
|
||||
TSRMLS_FETCH();
|
||||
|
||||
zend_llist_del_element(&PG(tick_functions), (void *)func,
|
||||
(int(*)(void*, void*))php_compare_tick_functions);
|
||||
}
|
||||
@@ -69,10 +65,8 @@ static void php_tick_iterator(void *data, void *arg TSRMLS_DC)
|
||||
func(*((int *)arg));
|
||||
}
|
||||
|
||||
void php_run_ticks(int count)
|
||||
void php_run_ticks(int count TSRMLS_DC)
|
||||
{
|
||||
TSRMLS_FETCH();
|
||||
|
||||
zend_llist_apply_with_argument(&PG(tick_functions), (llist_apply_with_arg_func_t) php_tick_iterator, &count TSRMLS_CC);
|
||||
}
|
||||
|
||||
|
||||
+3
-3
@@ -24,11 +24,11 @@
|
||||
int php_startup_ticks(TSRMLS_D);
|
||||
void php_deactivate_ticks(TSRMLS_D);
|
||||
void php_shutdown_ticks(TSRMLS_D);
|
||||
void php_run_ticks(int count);
|
||||
void php_run_ticks(int count TSRMLS_DC);
|
||||
|
||||
BEGIN_EXTERN_C()
|
||||
PHPAPI void php_add_tick_function(void (*func)(int));
|
||||
PHPAPI void php_remove_tick_function(void (*func)(int));
|
||||
PHPAPI void php_add_tick_function(void (*func)(int) TSRMLS_DC);
|
||||
PHPAPI void php_remove_tick_function(void (*func)(int) TSRMLS_DC);
|
||||
END_EXTERN_C()
|
||||
|
||||
#endif
|
||||
|
||||
@@ -734,6 +734,7 @@ static zend_bool php_auto_globals_create_post(const char *name, uint name_len TS
|
||||
|
||||
if (PG(variables_order) &&
|
||||
(strchr(PG(variables_order),'P') || strchr(PG(variables_order),'p')) &&
|
||||
!SG(headers_sent) &&
|
||||
SG(request_info).request_method &&
|
||||
!strcasecmp(SG(request_info).request_method, "POST")) {
|
||||
sapi_module.treat_data(PARSE_POST, NULL, NULL TSRMLS_CC);
|
||||
|
||||
+3
-3
@@ -1,8 +1,8 @@
|
||||
/* automatically generated by configure */
|
||||
/* edit configure.in to change version number */
|
||||
#define PHP_MAJOR_VERSION 5
|
||||
#define PHP_MINOR_VERSION 6
|
||||
#define PHP_MINOR_VERSION 7
|
||||
#define PHP_RELEASE_VERSION 0
|
||||
#define PHP_EXTRA_VERSION "-dev"
|
||||
#define PHP_VERSION "5.6.0-dev"
|
||||
#define PHP_VERSION_ID 50600
|
||||
#define PHP_VERSION "5.7.0-dev"
|
||||
#define PHP_VERSION_ID 50700
|
||||
@@ -87,7 +87,7 @@ END_EXTERN_C()
|
||||
BEGIN_EXTERN_C()
|
||||
PHPAPI void php_stream_notification_notify(php_stream_context *context, int notifycode, int severity,
|
||||
char *xmsg, int xcode, size_t bytes_sofar, size_t bytes_max, void * ptr TSRMLS_DC);
|
||||
PHPAPI php_stream_context *php_stream_context_set(php_stream *stream, php_stream_context *context);
|
||||
PHPAPI php_stream_context *php_stream_context_set(php_stream *stream, php_stream_context *context TSRMLS_DC);
|
||||
END_EXTERN_C()
|
||||
|
||||
#define php_stream_notify_info(context, code, xmsg, xcode) do { if ((context) && (context)->notifier) { \
|
||||
|
||||
@@ -2148,10 +2148,9 @@ PHPAPI php_stream *_php_stream_open_wrapper_ex(const char *path, const char *mod
|
||||
/* }}} */
|
||||
|
||||
/* {{{ context API */
|
||||
PHPAPI php_stream_context *php_stream_context_set(php_stream *stream, php_stream_context *context)
|
||||
PHPAPI php_stream_context *php_stream_context_set(php_stream *stream, php_stream_context *context TSRMLS_DC)
|
||||
{
|
||||
php_stream_context *oldcontext = stream->context;
|
||||
TSRMLS_FETCH();
|
||||
|
||||
stream->context = context;
|
||||
|
||||
|
||||
@@ -134,7 +134,7 @@ PHPAPI php_stream *_php_stream_xport_create(const char *name, size_t namelen, in
|
||||
context STREAMS_REL_CC TSRMLS_CC);
|
||||
|
||||
if (stream) {
|
||||
php_stream_context_set(stream, context);
|
||||
php_stream_context_set(stream, context TSRMLS_CC);
|
||||
|
||||
if ((flags & STREAM_XPORT_SERVER) == 0) {
|
||||
/* client */
|
||||
|
||||
@@ -1121,7 +1121,7 @@ static int php_userstreamop_set_option(php_stream *stream, int option, int value
|
||||
php_error_docref(NULL TSRMLS_CC, E_WARNING, "%s::" USERSTREAM_SET_OPTION " is not implemented!",
|
||||
us->wrapper->classname);
|
||||
ret = PHP_STREAM_OPTION_RETURN_ERR;
|
||||
} else if (retval && zend_is_true(retval)) {
|
||||
} else if (retval && zend_is_true(retval TSRMLS_CC)) {
|
||||
ret = PHP_STREAM_OPTION_RETURN_OK;
|
||||
} else {
|
||||
ret = PHP_STREAM_OPTION_RETURN_ERR;
|
||||
@@ -1629,7 +1629,7 @@ static int php_userstreamop_cast(php_stream *stream, int castas, void **retptr T
|
||||
us->wrapper->classname);
|
||||
break;
|
||||
}
|
||||
if (retval == NULL || !zend_is_true(retval)) {
|
||||
if (retval == NULL || !zend_is_true(retval TSRMLS_CC)) {
|
||||
break;
|
||||
}
|
||||
php_stream_from_zval_no_verify(intstream, &retval);
|
||||
|
||||
@@ -682,13 +682,6 @@ default_mimetype = "text/html"
|
||||
; http://php.net/default-charset
|
||||
;default_charset = "UTF-8"
|
||||
|
||||
; Always populate the $HTTP_RAW_POST_DATA variable. PHP's default behavior is
|
||||
; to disable this feature and it will be removed in a future version.
|
||||
; If post reading is disabled through enable_post_data_reading,
|
||||
; $HTTP_RAW_POST_DATA is *NOT* populated.
|
||||
; http://php.net/always-populate-raw-post-data
|
||||
;always_populate_raw_post_data = -1
|
||||
|
||||
;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
; Paths and Directories ;
|
||||
;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
|
||||
@@ -682,13 +682,6 @@ default_mimetype = "text/html"
|
||||
; http://php.net/default-charset
|
||||
;default_charset = "UTF-8"
|
||||
|
||||
; Always populate the $HTTP_RAW_POST_DATA variable. PHP's default behavior is
|
||||
; to disable this feature and it will be removed in a future version.
|
||||
; If post reading is disabled through enable_post_data_reading,
|
||||
; $HTTP_RAW_POST_DATA is *NOT* populated.
|
||||
; http://php.net/always-populate-raw-post-data
|
||||
;always_populate_raw_post_data = -1
|
||||
|
||||
;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
; Paths and Directories ;
|
||||
;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
|
||||
@@ -108,7 +108,7 @@ static int sapi_apache_ub_write(const char *str, uint str_length TSRMLS_DC)
|
||||
|
||||
/* {{{ sapi_apache_flush
|
||||
*/
|
||||
static void sapi_apache_flush(void *server_context)
|
||||
static void sapi_apache_flush(void *server_context TSRMLS_DC)
|
||||
{
|
||||
if (server_context) {
|
||||
#if MODULE_MAGIC_NUMBER > 19970110
|
||||
|
||||
@@ -245,14 +245,13 @@ php_apache_sapi_register_variables(zval *track_vars_array TSRMLS_DC)
|
||||
}
|
||||
|
||||
static void
|
||||
php_apache_sapi_flush(void *server_context)
|
||||
php_apache_sapi_flush(void *server_context TSRMLS_DC)
|
||||
{
|
||||
php_struct *ctx;
|
||||
apr_bucket_brigade *bb;
|
||||
apr_bucket_alloc_t *ba;
|
||||
apr_bucket *b;
|
||||
ap_filter_t *f; /* output filters */
|
||||
TSRMLS_FETCH();
|
||||
|
||||
ctx = server_context;
|
||||
|
||||
|
||||
@@ -287,11 +287,10 @@ php_apache_sapi_register_variables(zval *track_vars_array TSRMLS_DC)
|
||||
}
|
||||
|
||||
static void
|
||||
php_apache_sapi_flush(void *server_context)
|
||||
php_apache_sapi_flush(void *server_context TSRMLS_DC)
|
||||
{
|
||||
php_struct *ctx;
|
||||
request_rec *r;
|
||||
TSRMLS_FETCH();
|
||||
|
||||
ctx = server_context;
|
||||
|
||||
|
||||
@@ -253,7 +253,7 @@ static int sapi_apache_ub_write(const char *str, uint str_length TSRMLS_DC)
|
||||
|
||||
/* {{{ sapi_apache_flush
|
||||
*/
|
||||
static void sapi_apache_flush(void *server_context)
|
||||
static void sapi_apache_flush(void *server_context TSRMLS_DC)
|
||||
{
|
||||
if (server_context) {
|
||||
#if MODULE_MAGIC_NUMBER > 19970110
|
||||
|
||||
@@ -155,15 +155,13 @@ static request_rec *get_apache_request(zval *z TSRMLS_DC)
|
||||
return r;
|
||||
}
|
||||
|
||||
/* {{{ php_apache_request_new(request_rec *r)
|
||||
/* {{{ php_apache_request_new(request_rec *r TSRMLS_DC)
|
||||
* create a new zval-instance for ApacheRequest that wraps request_rec
|
||||
*/
|
||||
zval *php_apache_request_new(request_rec *r)
|
||||
zval *php_apache_request_new(request_rec *r TSRMLS_DC)
|
||||
{
|
||||
zval *req;
|
||||
zval *addr;
|
||||
|
||||
TSRMLS_FETCH();
|
||||
|
||||
MAKE_STD_ZVAL(addr);
|
||||
Z_TYPE_P(addr) = IS_LONG;
|
||||
@@ -1170,7 +1168,7 @@ PHP_FUNCTION(apache_request_sub_req_lookup_uri)
|
||||
if (!sub_r) {
|
||||
RETURN_FALSE;
|
||||
}
|
||||
return_value = php_apache_request_new(sub_r);
|
||||
return_value = php_apache_request_new(sub_r TSRMLS_CC);
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
@@ -1196,7 +1194,7 @@ PHP_FUNCTION(apache_request_sub_req_lookup_file)
|
||||
if (!sub_r) {
|
||||
RETURN_FALSE;
|
||||
}
|
||||
return_value = php_apache_request_new(sub_r);
|
||||
return_value = php_apache_request_new(sub_r TSRMLS_CC);
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
@@ -1222,7 +1220,7 @@ PHP_FUNCTION(apache_request_sub_req_method_uri)
|
||||
if (!sub_r) {
|
||||
RETURN_FALSE;
|
||||
}
|
||||
return_value = php_apache_request_new(sub_r);
|
||||
return_value = php_apache_request_new(sub_r TSRMLS_CC);
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
|
||||
Loaded 100 of 119 files, more files were not shown because too many files have changed in this diff.
Show more
Reference in new issue
Block a user