mirror of
https://github.com/bdnugget/php-src.git
synced 2026-11-22 16:35:43 +00:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
29b4532f61 | ||
|
|
f12f3abe8e | ||
|
|
82dd6b94f2 | ||
|
|
5a186a3e0a | ||
|
|
ba30c78d5c | ||
|
|
cd14de94d2 | ||
|
|
cb361ed27e | ||
|
|
8280393828 | ||
|
|
39612afc72 | ||
|
|
9ad97cd489 | ||
|
|
8c61758dc7 | ||
|
|
9d62807190 | ||
|
|
2b9f5ac252 | ||
|
|
7f69f07fc1 | ||
|
|
dcea4ec698 | ||
|
|
2874696a5a | ||
|
|
f3d18add08 | ||
|
|
f4dc2240a0 | ||
|
|
bab33f7e05 | ||
|
|
72aacbf735 | ||
|
|
87198989cd | ||
|
|
4134ebec8e | ||
|
|
76fd13f742 | ||
|
|
29f1aa2618 | ||
|
|
cf39c3d638 | ||
|
|
1a5c460ea2 | ||
|
|
5f5ff92bc0 | ||
|
|
24f36934ad | ||
|
|
473d66553d | ||
|
|
6b4971a29b | ||
|
|
36b759d1dd | ||
|
|
3f99ba6351 | ||
|
|
cdedee3fa1 | ||
|
|
143ec70638 | ||
|
|
503d39d925 | ||
|
|
ac538e5e16 | ||
|
|
bff1a96a0f | ||
|
|
2df95b1354 | ||
|
|
0ad81ac18a | ||
|
|
9d95a1a7d1 | ||
|
|
e9b128c1bf | ||
|
|
b27f6826d4 | ||
|
|
b33824bfea | ||
|
|
ac28283beb | ||
|
|
22d7002462 | ||
|
|
fc7fe62e3b | ||
|
|
c9243344a0 | ||
|
|
a188693a27 | ||
|
|
d3dae9a616 | ||
|
|
80fe5461a9 | ||
|
|
1e2f72d6b6 | ||
|
|
82a7ec72de | ||
|
|
ae4f8b2ab0 | ||
|
|
4ed133c4e2 | ||
|
|
c932d532c8 | ||
|
|
c6d977dd39 | ||
|
|
930183f961 | ||
|
|
2743c3aac8 | ||
|
|
aa042d0c35 | ||
|
|
a831499b4a | ||
|
|
6184753fab | ||
|
|
6e505f4969 | ||
|
|
4f87f26d06 | ||
|
|
0cd77475e0 | ||
|
|
18f17818a6 | ||
|
|
47d66a0b4e | ||
|
|
6e89818f2f | ||
|
|
3bbe5931bc | ||
|
|
a5c524f1be | ||
|
|
3c5e229212 | ||
|
|
b90b551228 | ||
|
|
ec4019e8f6 | ||
|
|
cabf38af6d | ||
|
|
963c1be38d | ||
|
|
cb8d1fc7f9 | ||
|
|
f718684a6c | ||
|
|
e59143e896 | ||
|
|
6f73a0c00f | ||
|
|
7d3fa7d8b6 | ||
|
|
a93a462dce | ||
|
|
e4f9619fad | ||
|
|
b80d73ce15 | ||
|
|
82b0e8be99 | ||
|
|
25e8fcc88f | ||
|
|
c793a65690 | ||
|
|
8d86597d73 | ||
|
|
3626db6142 | ||
|
|
5f137d080a | ||
|
|
626d96ab6d | ||
|
|
f17f596b27 | ||
|
|
a03f0943ca | ||
|
|
d24f31c65e | ||
|
|
d60e168a7a | ||
|
|
9ca7910661 | ||
|
|
ea75b1b5db | ||
|
|
3d0aca80f2 | ||
|
|
e55f08a5ae | ||
|
|
a85e71e655 | ||
|
|
5753b74fab | ||
|
|
47ac4f8670 | ||
|
|
6f1a762fab | ||
|
|
1e942dde24 | ||
|
|
ce9169e360 | ||
|
|
1c32b97bc3 | ||
|
|
cb13f8318b | ||
|
|
48ea95188e | ||
|
|
d884ec15e9 | ||
|
|
146b933ab4 | ||
|
|
c069b5f571 | ||
|
|
2ab080da2d | ||
|
|
017145bc57 | ||
|
|
4ed18d5955 | ||
|
|
3b4d2647f9 | ||
|
|
e3a4b87e89 | ||
|
|
0625d5ce67 | ||
|
|
4590070f31 | ||
|
|
5129892788 | ||
|
|
4395f70207 | ||
|
|
35872e101b | ||
|
|
fd8f454520 | ||
|
|
d69b3d8f59 | ||
|
|
f7c87fcc8c | ||
|
|
0a974f14d1 | ||
|
|
d9e2dc8084 | ||
|
|
f3aca8bc4d | ||
|
|
f14ed5bce0 | ||
|
|
7da3315015 | ||
|
|
c10d7e1afc | ||
|
|
2bd23530d8 | ||
|
|
02409669e4 | ||
|
|
8ca04e51aa | ||
|
|
cb17c99511 | ||
|
|
e2aba1cf9e | ||
|
|
3550f3d0aa | ||
|
|
e37fdbb2f2 | ||
|
|
ae5e70afac | ||
|
|
bafe0e5399 | ||
|
|
ef3d813d2c | ||
|
|
1d7b6970f2 | ||
|
|
8e79724c6f | ||
|
|
fd616ba50f | ||
|
|
4cab45946c | ||
|
|
29b2522df1 | ||
|
|
42e8f3ca28 | ||
|
|
979194351d | ||
|
|
9776504c5b | ||
|
|
515092917d | ||
|
|
1fbcfc9bdb | ||
|
|
9126909c08 | ||
|
|
9909c4d4c4 | ||
|
|
b8c8a04a85 | ||
|
|
96a53f6715 | ||
|
|
f9000fde98 | ||
|
|
f00d796b7e | ||
|
|
7b92a22772 | ||
|
|
5a8b0ca8fa | ||
|
|
c28ab73d73 | ||
|
|
063e10b275 | ||
|
|
8aebe0f1e7 | ||
|
|
9b6aa268a3 | ||
|
|
024972e3b9 | ||
|
|
a1bf38e075 | ||
|
|
7c9bb87edd | ||
|
|
bd20c79423 | ||
|
|
25f924abf6 | ||
|
|
f8efdc2b4b | ||
|
|
b8d4a6939e | ||
|
|
1b4103c09d | ||
|
|
83ced9124e | ||
|
|
476924ec3d | ||
|
|
ba984582db | ||
|
|
da3886de6d | ||
|
|
5027fa79d7 | ||
|
|
2c23004a1e | ||
|
|
e7a00a2566 | ||
|
|
f51b8d8820 | ||
|
|
b8941a73cc | ||
|
|
97637b2a4c | ||
|
|
4749457a49 | ||
|
|
29281dee49 | ||
|
|
c7b58e4967 | ||
|
|
3380de9774 | ||
|
|
3cd13204bb | ||
|
|
629965abe2 | ||
|
|
cc91fbe986 | ||
|
|
3363e04fb4 | ||
|
|
b963249456 | ||
|
|
a015fa83a7 | ||
|
|
1dc7d0da08 | ||
|
|
2b9d42433f | ||
|
|
99afc6dc11 | ||
|
|
d8dd4d9b02 | ||
|
|
cbdf9edebd | ||
|
|
d6692514f8 | ||
|
|
445dffa75a | ||
|
|
fec93992de | ||
|
|
b9e3f737d9 | ||
|
|
31edf4df56 | ||
|
|
94ab37f06a | ||
|
|
e6ae977082 | ||
|
|
0d3d739bf7 | ||
|
|
ba3234888d | ||
|
|
c855f44737 | ||
|
|
eb8c15b573 | ||
|
|
fd5cdf89a8 | ||
|
|
bb6d74918e | ||
|
|
f37ac6f591 | ||
|
|
135f81c5ae | ||
|
|
e1a0c90b8b | ||
|
|
d3a4af4db8 | ||
|
|
54b740a7e1 | ||
|
|
bcb39d9c6a | ||
|
|
ceecfaff5a | ||
|
|
710150ccb7 | ||
|
|
e2744f1aa3 | ||
|
|
e7a4cf8d7e | ||
|
|
9561e598a0 | ||
|
|
904c5d7ba8 | ||
|
|
2ec7b1c388 | ||
|
|
68e630b72f | ||
|
|
e617679c0b | ||
|
|
76775a3aa7 | ||
|
|
0aadbf7578 | ||
|
|
2c73ce4363 | ||
|
|
e9a95d78ef | ||
|
|
b79b13b4ef | ||
|
|
bb64106f64 | ||
|
|
f23a5fbc8e | ||
|
|
72085b0e5f | ||
|
|
b8a2b254a1 | ||
|
|
227556c6a2 | ||
|
|
8c663fd4cc | ||
|
|
2bad01e61b | ||
|
|
07ab23655a | ||
|
|
a51b50000d | ||
|
|
9cc9d32e6a | ||
|
|
f4b9b20b35 | ||
|
|
bcef0ebc2d | ||
|
|
07501dc1a2 | ||
|
|
6e3134610c | ||
|
|
168a5bb6df | ||
|
|
add0833681 | ||
|
|
67c03eac62 | ||
|
|
d012bdca03 | ||
|
|
6e32a871a4 | ||
|
|
e20fc85454 | ||
|
|
2c4f823437 | ||
|
|
ebad5178c4 | ||
|
|
eab076020d | ||
|
|
efc89368dd | ||
|
|
0863a0d6a0 | ||
|
|
184dea7033 | ||
|
|
4bd2f755ba | ||
|
|
281936b295 | ||
|
|
0ddb3d97de | ||
|
|
bccc3e2ec0 | ||
|
|
002f3ff4dc | ||
|
|
657116f12e | ||
|
|
d2a83efe5b | ||
|
|
64b11f8918 | ||
|
|
b2fbb4cc40 | ||
|
|
20e9ca5c9f | ||
|
|
5b01b0904f | ||
|
|
4f4fa32ca5 | ||
|
|
ecf057d197 | ||
|
|
2acc386270 | ||
|
|
2d77bbdf64 | ||
|
|
3478ddc1f0 | ||
|
|
c0bfc57ba8 | ||
|
|
96f77f845a | ||
|
|
e2e002d4ea | ||
|
|
1891577d04 | ||
|
|
4c6c048e3e | ||
|
|
9c4ef50146 | ||
|
|
26019d2022 | ||
|
|
4204e2cb5b | ||
|
|
710eee5555 | ||
|
|
f5b9d87fb9 | ||
|
|
29ac511b8a | ||
|
|
73b54b4a5b | ||
|
|
cd7e56e536 | ||
|
|
06cef326fd | ||
|
|
c7ee677f2f | ||
|
|
7045bd5c4a | ||
|
|
6ac7c9d0a7 | ||
|
|
ac26d0e655 | ||
|
|
79df8cf9c2 | ||
|
|
2c3f6dcdb6 | ||
|
|
dd71f1f173 | ||
|
|
3dd5f4ae4c | ||
|
|
9fc38183b7 | ||
|
|
204137693c | ||
|
|
bde0f1318a | ||
|
|
bdfe70ab34 | ||
|
|
2bc8271b29 | ||
|
|
d1c261d7f8 | ||
|
|
eed492ce84 | ||
|
|
e4a28b7b7b | ||
|
|
7d163e8a08 | ||
|
|
47e21a2c40 | ||
|
|
e964817b24 | ||
|
|
c652cc93ec | ||
|
|
40cbceaf71 | ||
|
|
332e46b3aa | ||
|
|
00293fec05 | ||
|
|
7549beb102 | ||
|
|
9aa7343ae0 | ||
|
|
5bc7e597d9 | ||
|
|
631bb27dca | ||
|
|
0265c2d961 | ||
|
|
5324416b65 | ||
|
|
74d434c091 | ||
|
|
50ac53e1b1 | ||
|
|
b52fea6f35 | ||
|
|
9487f0b4bb | ||
|
|
a4538a4ca2 | ||
|
|
1aeb2514fe | ||
|
|
67817a199c | ||
|
|
4d5a2fba16 | ||
|
|
8f0567581e | ||
|
|
f4ce5e7fb6 | ||
|
|
4bc11af193 | ||
|
|
c940aab789 | ||
|
|
1968fac697 | ||
|
|
743c4864eb | ||
|
|
bf8ed4708e | ||
|
|
49a2cd93d6 | ||
|
|
06418aca28 | ||
|
|
0f36224beb | ||
|
|
5904da9948 | ||
|
|
18f45c535b | ||
|
|
46214a23b8 | ||
|
|
87dda666c7 | ||
|
|
ef63334fa6 | ||
|
|
27b01cfcd7 | ||
|
|
657d486013 | ||
|
|
103cf4c060 | ||
|
|
4020ef8980 | ||
|
|
e46beabe8f | ||
|
|
3becd3879f | ||
|
|
2c73f61a1c | ||
|
|
8cb782bbce | ||
|
|
e00ed6bc3f | ||
|
|
70ae67b5da | ||
|
|
ce8c023910 | ||
|
|
41565a239f | ||
|
|
1e836cdd64 | ||
|
|
b66c14b0c8 | ||
|
|
60bbc78bde | ||
|
|
c2cfc242c4 | ||
|
|
fa8611c81e | ||
|
|
402b3aaf56 | ||
|
|
76866e0a2e | ||
|
|
60dcc5851f | ||
|
|
02682f4169 | ||
|
|
efbf573e9f | ||
|
|
891bd46f3d | ||
|
|
cd176e0452 | ||
|
|
aa31d7e1ef | ||
|
|
7e33b5d2fa | ||
|
|
32f11e4ee6 | ||
|
|
f477ad22c2 | ||
|
|
781be5f1d7 | ||
|
|
b34e8d2e3e | ||
|
|
8922c50ca4 | ||
|
|
6c8cef3ca4 | ||
|
|
623386d799 | ||
|
|
b68c496175 | ||
|
|
12b75e3d3e | ||
|
|
fba44be828 | ||
|
|
e15ca39708 | ||
|
|
4289696828 | ||
|
|
91bd2de85c | ||
|
|
12fdf8fb95 | ||
|
|
99ab8a83af | ||
|
|
111b385afe | ||
|
|
a689fde2bf | ||
|
|
f5bf90ef34 | ||
|
|
04db57066d | ||
|
|
40c3601947 | ||
|
|
2ab53f4b5e | ||
|
|
b78f129a4a | ||
|
|
adb116dd48 | ||
|
|
41b73e4cee | ||
|
|
c3f4cc2e40 | ||
|
|
3675b953f6 | ||
|
|
5d0094e5f9 | ||
|
|
5ae1983b33 | ||
|
|
d01ca1342c | ||
|
|
6ba93a4bae | ||
|
|
ec7ac71b52 | ||
|
|
a52258ae17 | ||
|
|
423b132a7a | ||
|
|
157ccaf507 | ||
|
|
efd3c72de3 | ||
|
|
9d9ec2a90e | ||
|
|
38eb909d06 | ||
|
|
0093980fe0 | ||
|
|
ff292d619c | ||
|
|
982c11573d | ||
|
|
d43a2f0ffb | ||
|
|
4b41959f9e | ||
|
|
8776555d7a | ||
|
|
47035ba5c9 | ||
|
|
a6a3aa5d49 | ||
|
|
9cf3e65391 | ||
|
|
0ddfafe489 | ||
|
|
ecd9d76250 | ||
|
|
9da4985bf2 | ||
|
|
8075f1f4a3 | ||
|
|
b4632d0c12 | ||
|
|
f49b27e166 | ||
|
|
e3d625bc4e | ||
|
|
ae5a09b47d | ||
|
|
a0d48e01ed | ||
|
|
8aba119f55 | ||
|
|
9872835cf3 | ||
|
|
860a5c4b01 | ||
|
|
e1acaea4f1 | ||
|
|
1beb24bd6f | ||
|
|
a0b4348abc | ||
|
|
7272e3e722 | ||
|
|
f1e37d03c1 | ||
|
|
61fb822d1a | ||
|
|
296a12efbb | ||
|
|
2531307be6 | ||
|
|
fc898ee0f9 | ||
|
|
162726241c | ||
|
|
8623562b02 | ||
|
|
c65d663aef | ||
|
|
876b474c7d | ||
|
|
07e52857b5 | ||
|
|
77c46ba516 | ||
|
|
f5c7fe9202 | ||
|
|
283f56af66 | ||
|
|
94e7549719 | ||
|
|
b5978e239e | ||
|
|
e4ee921b7e | ||
|
|
60afd3fce4 | ||
|
|
9be591bdb5 | ||
|
|
83fc53acb9 | ||
|
|
c091819f40 | ||
|
|
6809c388b5 | ||
|
|
59cf3a2404 |
No files matched your search
@@ -1819,7 +1819,7 @@ Installation
|
||||
set of HTTP headers. The headers it did return are:
|
||||
10. Windows: I've followed all the instructions, but still can't get
|
||||
PHP and IIS to work together!
|
||||
11. When running PHP as CGI with IIS, PWS, OmniHTTPD or Xitami, I get
|
||||
11. When running PHP as CGI with IIS, OmniHTTPD or Xitami, I get
|
||||
the following error: Security Alert! PHP CGI cannot be accessed
|
||||
directly..
|
||||
12. How do I know if my php.ini is being found and read? It seems like
|
||||
@@ -2007,7 +2007,7 @@ cgi error:
|
||||
And for IIS4 you need to tell it that PHP is a script engine.
|
||||
Also, you will want to read this faq.
|
||||
|
||||
When running PHP as CGI with IIS, PWS, OmniHTTPD or Xitami, I get the
|
||||
When running PHP as CGI with IIS, OmniHTTPD or Xitami, I get the
|
||||
following error: Security Alert! PHP CGI cannot be accessed
|
||||
directly..
|
||||
You must set the cgi.force_redirect directive to 0. It defaults
|
||||
|
||||
+12
-3
@@ -10,7 +10,7 @@ all: $(all_targets)
|
||||
@echo "Build complete."
|
||||
@echo "Don't forget to run 'make test'."
|
||||
@echo
|
||||
|
||||
|
||||
build-modules: $(PHP_MODULES) $(PHP_ZEND_EX)
|
||||
|
||||
build-binaries: $(PHP_BINARIES)
|
||||
@@ -115,10 +115,19 @@ clean:
|
||||
find . -name \*.la -o -name \*.a | xargs rm -f
|
||||
find . -name \*.so | xargs rm -f
|
||||
find . -name .libs -a -type d|xargs rm -rf
|
||||
rm -f libphp$(PHP_MAJOR_VERSION).la $(SAPI_CLI_PATH) $(OVERALL_TARGET) modules/* libs/*
|
||||
rm -f libphp$(PHP_MAJOR_VERSION).la $(SAPI_CLI_PATH) $(SAPI_CGI_PATH) $(SAPI_MILTER_PATH) $(SAPI_LITESPEED_PATH) $(SAPI_FPM_PATH) $(OVERALL_TARGET) modules/* libs/*
|
||||
|
||||
distclean: clean
|
||||
rm -f Makefile config.cache config.log config.status Makefile.objects Makefile.fragments libtool main/php_config.h stamp-h sapi/apache/libphp$(PHP_MAJOR_VERSION).module buildmk.stamp
|
||||
rm -f Makefile config.cache config.log config.status Makefile.objects Makefile.fragments libtool main/php_config.h main/internal_functions_cli.c main/internal_functions.c stamp-h sapi/apache/libphp$(PHP_MAJOR_VERSION).module sapi/apache_hooks/libphp$(PHP_MAJOR_VERSION).module buildmk.stamp Zend/zend_dtrace_gen.h Zend/zend_dtrace_gen.h.bak Zend/zend_config.h TSRM/tsrm_config.h
|
||||
rm -f php5.spec main/build-defs.h scripts/phpize
|
||||
rm -f ext/date/lib/timelib_config.h ext/mbstring/oniguruma/config.h ext/mbstring/libmbfl/config.h ext/mysqlnd/php_mysqlnd_config.h
|
||||
rm -f scripts/man1/phpize.1 scripts/php-config scripts/man1/php-config.1 sapi/cli/php.1 sapi/cgi/php-cgi.1 ext/phar/phar.1 ext/phar/phar.phar.1
|
||||
rm -f sapi/fpm/php-fpm.conf sapi/fpm/init.d.php-fpm sapi/fpm/php-fpm.service sapi/fpm/php-fpm.8 sapi/fpm/status.html
|
||||
rm -f ext/iconv/php_have_bsd_iconv.h ext/iconv/php_have_glibc_iconv.h ext/iconv/php_have_ibm_iconv.h ext/iconv/php_have_iconv.h ext/iconv/php_have_libiconv.h ext/iconv/php_iconv_aliased_libiconv.h ext/iconv/php_iconv_supports_errno.h ext/iconv/php_php_iconv_h_path.h ext/iconv/php_php_iconv_impl.h
|
||||
rm -f ext/phar/phar.phar ext/phar/phar.php
|
||||
if test "$(srcdir)" != "$(builddir)"; then \
|
||||
rm -f ext/phar/phar/phar.inc; \
|
||||
fi
|
||||
$(EGREP) define'.*include/php' $(top_srcdir)/configure | $(SED) 's/.*>//'|xargs rm -f
|
||||
|
||||
.PHONY: all clean install distclean test
|
||||
|
||||
@@ -1,5 +1,157 @@
|
||||
PHP NEWS
|
||||
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
||||
15 Aug 2013, PHP 5.5.2
|
||||
|
||||
- Core:
|
||||
. Fixed bug #62691 (solaris sed has no -i switch). (Chris Jones)
|
||||
. Fixed bug #61345 (CGI mode - make install don't work). (Michael Heimpold)
|
||||
. Fixed bug #61268 (--enable-dtrace leads make to clobber
|
||||
Zend/zend_dtrace.d) (Chris Jones)
|
||||
|
||||
- DOM:
|
||||
. Added flags option to DOMDocument::schemaValidate() and
|
||||
DOMDocument::schemaValidateSource(). Added LIBXML_SCHEMA_CREATE flag.
|
||||
(Chris Wright)
|
||||
|
||||
- Sessions:
|
||||
. Implemented strict sessions RFC (https://wiki.php.net/rfc/strict_sessions)
|
||||
which protects against session fixation attacks and session collisions.
|
||||
(Yasuo Ohgaki)
|
||||
. Fixed possible buffer overflow under Windows. Note: Not a security fix.
|
||||
(Yasuo)
|
||||
. Changed session.auto_start to PHP_INI_PERDIR. (Yasuo)
|
||||
|
||||
- Pgsql:
|
||||
. Fixed bug #62978 (Disallow possible SQL injections with pg_select()/pg_update()
|
||||
/pg_delete()/pg_insert()). (Yasuo)
|
||||
|
||||
?? ??? 2013, PHP 5.5.2
|
||||
|
||||
- Core:
|
||||
. Fixed bug #65372 (Segfault in gc_zval_possible_root when return reference
|
||||
fails). (Laruence)
|
||||
. Fixed value of FILTER_SANITIZE_FULL_SPECIAL_CHARS constant (previously was
|
||||
erroneously set to FILTER_SANITIZE_SPECIAL_CHARS value). (Andrey
|
||||
avp200681 gmail com).
|
||||
. Fixed bug #65304 (Use of max int in array_sum). (Laruence)
|
||||
. Fixed bug #65291 (get_defined_constants() causes PHP to crash in a very
|
||||
limited case). (Arpad)
|
||||
|
||||
- OPcache:
|
||||
. Added opcache.restrict_api configuration directive that may limit
|
||||
usage of OPcahce API functions only to patricular script(s). (Dmitry)
|
||||
. Added support for glob symbols in blacklist entries (?, *, **).
|
||||
(Terry Elison, Dmitry)
|
||||
. Fixed bug #65338 (Enabling both php_opcache and php_wincache AVs on
|
||||
shutdown). (Dmitry)
|
||||
|
||||
- Openssl:
|
||||
. Fixed handling null bytes in subjectAltName (CVE-2013-4073).
|
||||
(Christian Heimes)
|
||||
|
||||
- PDO_mysql:
|
||||
. Fixed bug #65299 (pdo mysql parsing errors). (Johannes)
|
||||
|
||||
- Phar:
|
||||
. Fixed bug #65028 (Phar::buildFromDirectory creates corrupt archives for
|
||||
some specific contents). (Stas)
|
||||
|
||||
- SOAP:
|
||||
. Fixed bug #65018 (SoapHeader problems with SoapServer). (Dmitry)
|
||||
|
||||
- SPL:
|
||||
. Fixed bug #65328 (Segfault when getting SplStack object Value). (Laruence)
|
||||
. Added RecursiveTreeIterator setPostfix and getPostifx methods. (Joshua
|
||||
Thijssen)
|
||||
. Fixed bug #61697 (spl_autoload_functions returns lambda functions
|
||||
incorrectly). (Laruence)
|
||||
|
||||
- Streams:
|
||||
. Fixed bug #65268 (select() implementation uses outdated tick API). (Anatol)
|
||||
|
||||
- Pgsql:
|
||||
. Fixed bug #65336 (pg_escape_literal/identifier() scilently returns false).
|
||||
(Yasuo)
|
||||
|
||||
18 Jul 2013, PHP 5.5.1
|
||||
|
||||
- Core:
|
||||
. Fixed bug #65254 (Exception not catchable when exception thrown in autoload
|
||||
with a namespace). (Laruence)
|
||||
. Fixed bug #65088 (Generated configure script is malformed on OpenBSD).
|
||||
(Adam)
|
||||
. Fixed bug #65108 (is_callable() triggers Fatal Error).
|
||||
(David Soria Parra, Laruence)
|
||||
. Fixed bug #65035 (yield / exit segfault). (Nikita)
|
||||
. Fixed bug #65161 (Generator + autoload + syntax error = segfault). (Nikita)
|
||||
. hex2bin() raises E_WARNING for invalid hex string. (Yasuo)
|
||||
. Fixed bug #65226 (chroot() does not get enabled). (Anatol)
|
||||
|
||||
- OPcache
|
||||
. Fixed bug #64827 (Segfault in zval_mark_grey (zend_gc.c)). (Laruence)
|
||||
. OPcache must be compatible with LiteSpeed SAPI (Dmitry)
|
||||
|
||||
- CGI:
|
||||
. Fixed Bug #65143 (Missing php-cgi man page). (Remi)
|
||||
|
||||
- CLI server:
|
||||
. Fixed bug #65066 (Cli server not responsive when responding with 422 http
|
||||
status code). (Adam)
|
||||
|
||||
- DateTime
|
||||
. Fixed fug #65184 (strftime() returns insufficient-length string under
|
||||
multibyte locales). (Anatol)
|
||||
|
||||
- GD
|
||||
. Fixed #65070 (bgcolor does not use the same format as the input image with
|
||||
imagerotate). (Pierre)
|
||||
. Fixed Bug #65060 (imagecreatefrom... crashes with user streams). (Remi)
|
||||
. Fixed Bug #65084 (imagecreatefromjpeg fails with URL). (Remi)
|
||||
. Fix gdImageCreateFromWebpCtx and use same logic to load WebP image
|
||||
that other formats. (Remi)
|
||||
|
||||
- Intl:
|
||||
. Add IntlCalendar::setMinimalDaysInFirstWeek()/
|
||||
intlcal_set_minimal_days_in_first_week().
|
||||
. Fixed trailing space in name of constant IntlCalendar::FIELD_FIELD_COUNT.
|
||||
. Fixed bug #62759 (Buggy grapheme_substr() on edge case). (Stas)
|
||||
. Fixed bug #61860 (Offsets may be wrong for grapheme_stri* functions).
|
||||
(Stas)
|
||||
|
||||
- OCI8:
|
||||
. Bump PECL package info version check to allow PECL installs with PHP 5.5+
|
||||
|
||||
- PDO:
|
||||
. Allowed PDO_OCI to compile with Oracle Database 12c client libraries.
|
||||
(Chris Jones)
|
||||
|
||||
- Pgsql
|
||||
. pg_unescape_bytea() raises E_WARNING for invalid inputs. (Yasuo)
|
||||
|
||||
- Phar:
|
||||
. Fixed Bug #65142 (Missing phar man page). (Remi)
|
||||
|
||||
- Session:
|
||||
. Added optional create_sid() argument to session_set_save_handler(),
|
||||
SessionHandler and new SessionIdInterface. (Leigh, Arpad)
|
||||
|
||||
- Sockets:
|
||||
. Implemented FR #63472 (Setting SO_BINDTODEVICE with socket_set_option).
|
||||
(Damjan Cvetko)
|
||||
. Allowed specifying paths in the abstract namespace for the functions
|
||||
socket_bind(), socket_connect() and socket_sendmsg(). (Gustavo)
|
||||
. Fixed bug #65260 (sendmsg() ancillary data construction for SCM_RIGHTS is
|
||||
faulty). (Gustavo)
|
||||
|
||||
- SPL:
|
||||
. Fixed bug #65136 (RecursiveDirectoryIterator segfault). (Laruence)
|
||||
. Fixed bug #61828 (Memleak when calling Directory(Recursive)Iterator
|
||||
/Spl(Temp)FileObject ctor twice). (Laruence)
|
||||
|
||||
- CGI/FastCGI SAPI:
|
||||
. Added PHP_FCGI_BACKLOG, overrides the default listen backlog. (Arnaud Le
|
||||
Blanc)
|
||||
|
||||
20 Jun 2013, PHP 5.5.0
|
||||
|
||||
- Core:
|
||||
|
||||
+6
-5
@@ -45,15 +45,16 @@ Currently we have the following branches in use::
|
||||
|
||||
master The active development branch.
|
||||
|
||||
PHP-5.5 Is used to release the PHP 5.5.x series. It allows for larger
|
||||
enhancements.
|
||||
|
||||
PHP-5.4 Is used to release the PHP 5.4.x series. This is current
|
||||
PHP-5.5 Is used to release the PHP 5.5.x series. This is a current
|
||||
stable version and is open for bugfixes only.
|
||||
|
||||
PHP-5.3 Is used to release the PHP 5.3.x series. This is current
|
||||
PHP-5.4 Is used to release the PHP 5.4.x series. This is a current
|
||||
stable version and is open for bugfixes only.
|
||||
|
||||
PHP-5.3 Is used to release the PHP 5.3.x series. This is currently
|
||||
in extended support and open forsecurity fixes only. Triaged
|
||||
via security@php.net
|
||||
|
||||
PHP-5.2 This branch is closed.
|
||||
|
||||
PHP-5.1 This branch is closed.
|
||||
|
||||
@@ -78,6 +78,9 @@ f.e. http://downloads.php.net/derick/
|
||||
(internals-win@lists.php.net) so that Windows binaries can be created. Once
|
||||
those are made, they should be placed into the same directory as the source snapshots.
|
||||
|
||||
12. Notify the documentation team if documentations for new features are
|
||||
not yet available but a stable release is imminent.
|
||||
|
||||
Getting the non stable release (alpha/beta/RC) announced
|
||||
--------------------------------------------------------
|
||||
|
||||
@@ -174,6 +177,9 @@ those are made, they should be committed to SVN too.
|
||||
15. When making a final release, also remind the PHP Windows development team
|
||||
(internals-win@lists.php.net) to prepare the installer packages for Win32.
|
||||
|
||||
16. Make sure proper documentation exists for all new features/changes.
|
||||
Coordinate the release with the PHP Documentation team.
|
||||
|
||||
Getting the stable release announced
|
||||
------------------------------------
|
||||
|
||||
|
||||
+5
-3
@@ -625,7 +625,7 @@ TSRM_API int shmget(int key, int size, int flags)
|
||||
shm->info = info_handle;
|
||||
shm->descriptor = MapViewOfFileEx(shm->info, FILE_MAP_ALL_ACCESS, 0, 0, 0, NULL);
|
||||
|
||||
if (created) {
|
||||
if (NULL != shm->descriptor && created) {
|
||||
shm->descriptor->shm_perm.key = key;
|
||||
shm->descriptor->shm_segsz = size;
|
||||
shm->descriptor->shm_ctime = time(NULL);
|
||||
@@ -639,8 +639,10 @@ TSRM_API int shmget(int key, int size, int flags)
|
||||
shm->descriptor->shm_perm.mode = shm->descriptor->shm_perm.seq = 0;
|
||||
}
|
||||
|
||||
if (shm->descriptor->shm_perm.key != key || size > shm->descriptor->shm_segsz ) {
|
||||
CloseHandle(shm->segment);
|
||||
if (NULL != shm->descriptor && (shm->descriptor->shm_perm.key != key || size > shm->descriptor->shm_segsz)) {
|
||||
if (NULL != shm->segment) {
|
||||
CloseHandle(shm->segment);
|
||||
}
|
||||
UnmapViewOfFile(shm->descriptor);
|
||||
CloseHandle(shm->info);
|
||||
return -1;
|
||||
|
||||
@@ -2,16 +2,16 @@ $Id$
|
||||
|
||||
PHP 5.5 UPGRADE NOTES
|
||||
|
||||
1. Backward Incompatible Changes
|
||||
2. New Features
|
||||
2. Changes in SAPI modules
|
||||
3. Deprecated Functionality
|
||||
4. Changed Functions
|
||||
5. New Functions
|
||||
6. New Classes and Interfaces
|
||||
7. Removed Extensions
|
||||
8. Other Changes to Extensions
|
||||
9. New Global Constants
|
||||
1. Backward Incompatible Changes
|
||||
2. New Features
|
||||
2. Changes in SAPI modules
|
||||
3. Deprecated Functionality
|
||||
4. Changed Functions
|
||||
5. New Functions
|
||||
6. New Classes and Interfaces
|
||||
7. Removed Extensions
|
||||
8. Other Changes to Extensions
|
||||
9. New Global Constants
|
||||
10. Changes to INI File Handling
|
||||
11. Windows Support
|
||||
12. Other Changes
|
||||
@@ -21,122 +21,170 @@ PHP 5.5 UPGRADE NOTES
|
||||
1. Backward Incompatible Changes
|
||||
========================================
|
||||
|
||||
- Drop Windows XP and 2003 support. (Pierre)
|
||||
- All internal case insensitivity handling for class, function and constant
|
||||
names is done according to ASCII rules, current locale settings are ignored.
|
||||
- Dropped Windows XP and 2003 support. (Pierre)
|
||||
|
||||
- All internal case insensitivity handling for class, function and constant
|
||||
names is done according to ASCII rules. Current locale settings are ignored.
|
||||
|
||||
- self, parent & static keywords now are always case-insensitive (see bug
|
||||
#60833).
|
||||
- php_logo_guid(), php_egg_logo_guid(), php_real_logo_guid() and
|
||||
zend_logo_guid() have been removed
|
||||
- Removal of Logo GUIDs
|
||||
|
||||
- Removed Logo GUIDs: php_logo_guid(), php_egg_logo_guid(),
|
||||
php_real_logo_guid() and zend_logo_guid()
|
||||
|
||||
========================================
|
||||
2. New Features
|
||||
========================================
|
||||
|
||||
- Support list in foreach. (Laruence)
|
||||
(wiki.php.net/rfc/foreachlist)
|
||||
- Support finally keyword. (Laruence)
|
||||
(wiki.php.net/rfc/finally)
|
||||
(http://php.net/foreach#control-structures.foreach.list,
|
||||
http://wiki.php.net/rfc/foreachlist)
|
||||
|
||||
- Support "finally" keyword. (Laruence)
|
||||
(http://php.net/exceptions, http://wiki.php.net/rfc/finally)
|
||||
|
||||
- Support constant array/string dereferencing. (Laruence)
|
||||
(https://wiki.php.net/rfc/constdereference)
|
||||
(http://php.net/manual/en/language.types.array.php,
|
||||
https://wiki.php.net/rfc/constdereference)
|
||||
|
||||
- Add support for using empty() on the result of function calls and
|
||||
other expressions. Thus it is now possible to write empty(getArray()),
|
||||
for example. (https://wiki.php.net/rfc/empty_isset_exprs)
|
||||
for example. (http://php.net/manual/en/function.empty.php,
|
||||
https://wiki.php.net/rfc/empty_isset_exprs)
|
||||
|
||||
- Added generators.
|
||||
(https://wiki.php.net/rfc/generators)
|
||||
- ClassName::class syntax returning full class name for a class as
|
||||
a string constant. (https://wiki.php.net/rfc/class_name_scalars)
|
||||
(http://php.net/generators, https://wiki.php.net/rfc/generators)
|
||||
|
||||
- ClassName::class syntax returning full class name for a class as a
|
||||
string constant. (http://php.net/oop5.basic,
|
||||
https://wiki.php.net/rfc/class_name_scalars)
|
||||
|
||||
- Added support for non-scalar Iterator keys in foreach.
|
||||
(https://wiki.php.net/rfc/foreach-non-scalar-keys).
|
||||
- Bundled Zend OPcache extension
|
||||
(https://wiki.php.net/rfc/optimizerplus)
|
||||
(http://php.net/manual/en/control-structures.foreach.php,
|
||||
https://wiki.php.net/rfc/foreach-non-scalar-keys).
|
||||
|
||||
- Bundled Zend OPcache extension to improve performance
|
||||
(http://php.net/manual/en/book.opcache.php,
|
||||
https://wiki.php.net/rfc/optimizerplus)
|
||||
|
||||
- Added a simplified password hashing API
|
||||
(http://php.net/password, https://wiki.php.net/rfc/password_hash)
|
||||
|
||||
========================================
|
||||
2. Changes in SAPI modules
|
||||
========================================
|
||||
|
||||
- Support for changing the process's title in CLI/CLI-Server SAPIs. (Keyur)
|
||||
(https://wiki.php.net/rfc/cli_process_title)
|
||||
- Support for systemd in php-fpm:
|
||||
Add --with-fpm-systemd option to report health to systemd, and
|
||||
systemd_interval option to configure this. The service can now use
|
||||
Type=notify in the systemd unit file. (Remi)
|
||||
- Support for changing the process's title in CLI/CLI-Server
|
||||
SAPIs. (Keyur)
|
||||
(http://php.net/manual/en/function.cli-set-process-title.php,
|
||||
http://php.net/manual/en/function.cli-get-process-title.php,
|
||||
https://wiki.php.net/rfc/cli_process_title)
|
||||
|
||||
- Support for systemd in php-fpm: Add --with-fpm-systemd option to
|
||||
report health to systemd, and add systemd_interval option to
|
||||
configure this. The service can now use Type=notify in the systemd
|
||||
unit file. (Remi)
|
||||
|
||||
========================================
|
||||
3. Deprecated Functionality
|
||||
========================================
|
||||
|
||||
- The original MySQL extension is now deprecated, and will generate deprecation
|
||||
warnings when connecting to a database through mysql_connect(),
|
||||
mysql_pconnect() or by establishing an implicit connection. Use MySQLi or PDO
|
||||
instead.
|
||||
- The original MySQL extension is now deprecated and will generate
|
||||
deprecation warnings when connecting to a database through
|
||||
mysql_connect(), mysql_pconnect() or by establishing an implicit
|
||||
connection. Use MySQLi or PDO instead.
|
||||
|
||||
- The preg_replace /e modifier is now deprecated. Use
|
||||
preg_replace_callback instead.
|
||||
(https://wiki.php.net/rfc/remove_preg_replace_eval_modifier)
|
||||
|
||||
- IntlDateFormatter::setTimeZoneID() and datefmt_set_timezone_id() are
|
||||
deprecated. Use IntlDateFormatter::setTimeZone() or datefmt_set_timezone()
|
||||
instead.
|
||||
deprecated. Use IntlDateFormatter::setTimeZone() or
|
||||
datefmt_set_timezone() instead.
|
||||
|
||||
- mcrypt_ecb(), mcrypt_cbc(), mcrypt_cfb() and mcrypt_ofb() now throw
|
||||
E_DEPRECATED. Their use was already previously discouraged in the docs,
|
||||
but that predated the existence of E_DEPRECATED.
|
||||
E_DEPRECATED. Their use was already previously discouraged in the
|
||||
documentation, but that predated the existence of E_DEPRECATED.
|
||||
|
||||
========================================
|
||||
4. Changed Functions
|
||||
========================================
|
||||
|
||||
- pack()/unpack() had the following changes, which bring it more in line
|
||||
with Perl's behavior:
|
||||
- Implemented format character "Z": NULL padded string, with trailing NULL
|
||||
bytes removed.
|
||||
- Changed format character "a": this no longer removes trailing NULL bytes.
|
||||
- Changed format character "A": all trailing ASCII whitespace is now removed
|
||||
(defined as spaces, tabs, \r, \n and NULL).
|
||||
- MessageFormatter::format() and related functions now accepted named arguments
|
||||
and mixed numeric/named arguments in ICU 4.8+.
|
||||
- MessageFormatter::format() and related functions now don't error out when
|
||||
an insufficient argument count is provided. Instead, the placeholders will
|
||||
remain unsubstituted.
|
||||
- MessageFormatter::parse() and MessageFormat::format() (and their static
|
||||
equivalents) now don't throw away better than second precision in the
|
||||
arguments.
|
||||
- IntlDateFormatter::__construct and datefmt_create() now accept for the
|
||||
$timezone argument time zone identifiers, IntlTimeZone objects, DateTimeZone
|
||||
objects and NULL. It used to accept only time zone identifiers and NULL.
|
||||
Invalid time zone identifiers are no longer accepted. Emptry strings are
|
||||
no longer accepted.
|
||||
- pack()/unpack() had the following changes, which bring it more in
|
||||
line with Perl's behavior: - Implemented format character "Z": NULL
|
||||
padded string, with trailing NULL bytes removed. - Changed format
|
||||
character "a": this no longer removes trailing NULL bytes. -
|
||||
Changed format character "A": all trailing ASCII whitespace is now
|
||||
removed (defined as spaces, tabs, \r, \n and NULL).
|
||||
|
||||
- MessageFormatter::format() and related functions now accepted named
|
||||
arguments and mixed numeric/named arguments in ICU 4.8+.
|
||||
|
||||
- MessageFormatter::format() and related functions now don't error out
|
||||
when an insufficient argument count is provided. Instead, the
|
||||
placeholders will remain unsubstituted.
|
||||
|
||||
- MessageFormatter::parse() and MessageFormat::format() (and their
|
||||
static equivalents) now don't throw away better than second
|
||||
precision in the arguments.
|
||||
|
||||
- IntlDateFormatter::__construct and datefmt_create() now accept for
|
||||
the $timezone argument time zone identifiers, IntlTimeZone objects,
|
||||
DateTimeZone objects and NULL. It used to accept only time zone
|
||||
identifiers and NULL. Invalid time zone identifiers are no longer
|
||||
accepted. Empty strings are no longer accepted.
|
||||
|
||||
- The default time zone used in IntlDateFormatter::__construct and
|
||||
datefmt_create() (when the corresponding argument is not passed or NULL is
|
||||
passed) is now the one given by date_default_timezone_get(), not the
|
||||
default ICU time zone.
|
||||
- The time zone passed to the IntlDateFormatter is ignored if it is NULL and if
|
||||
the calendar passed is an IntlCalendar object -- in this case, the
|
||||
IntlCalendar's time zone will be used instead. Otherwise, the time zone
|
||||
specified in the $timezone argument is used instead. This does not affect
|
||||
old code, as IntlCalendar was introduced in this version.
|
||||
- IntlDateFormatter::__construct and datefmt_create() now accept for the
|
||||
$calendar argument also IntlCalendar objects.
|
||||
- IntlDateFormatter::getCalendar() and datefmt_get_calendar() return false
|
||||
if the IntlDateFormatter was set up with an IntlCalendar instead of the
|
||||
constants IntlDateFormatter::GREGORIAN/TRADITIONAL. IntlCalendar did not
|
||||
exist before this version.
|
||||
- IntlDateFormatter::setCalendar() and datefmt_set_calendar() now also accept
|
||||
an IntlCalendar object, in which case its time zone is taken. Passing a
|
||||
constant is still allowed, and still keeps the time zone.
|
||||
datefmt_create() (when the corresponding argument is not passed or
|
||||
NULL is passed) is now the one given by date_default_timezone_get(),
|
||||
not the default ICU time zone.
|
||||
|
||||
- The time zone passed to the IntlDateFormatter is ignored if it is
|
||||
NULL and if the calendar passed is an IntlCalendar object -- in this
|
||||
case, the IntlCalendar's time zone will be used instead. Otherwise,
|
||||
the time zone specified in the $timezone argument is used
|
||||
instead. This does not affect old code, as IntlCalendar was
|
||||
introduced in this version.
|
||||
|
||||
- IntlDateFormatter::__construct and datefmt_create() now accept for
|
||||
the $calendar argument also IntlCalendar objects.
|
||||
|
||||
- IntlDateFormatter::getCalendar() and datefmt_get_calendar() return
|
||||
false if the IntlDateFormatter was set up with an IntlCalendar
|
||||
instead of the constants
|
||||
IntlDateFormatter::GREGORIAN/TRADITIONAL. IntlCalendar did not exist
|
||||
before this version.
|
||||
|
||||
- IntlDateFormatter::setCalendar() and datefmt_set_calendar() now also
|
||||
accept an IntlCalendar object, in which case its time zone is
|
||||
taken. Passing a constant is still allowed, and still keeps the time
|
||||
zone.
|
||||
|
||||
- IntlDateFormatter::format() and datefmt_format() now also accept an
|
||||
IntlCalendar object for formatting.
|
||||
- php_logo_guid(), php_egg_logo_guid(), php_real_logo_guid() and
|
||||
zend_logo_guid() have been removed
|
||||
|
||||
- set_error_handler(NULL) can now be used to reset the error handler.
|
||||
Furthermore both set_error_handler(NULL) and set_exception_handler(NULL) will
|
||||
now return the previously defined error/exception handler. Previously
|
||||
bool(true) was returned.
|
||||
- setcookie(), setrawcookie() and ext/session now send Max-Age headers alongside
|
||||
Expires headers. (see https://wiki.php.net/rfc/cookie_max-age)
|
||||
- curl_setopt now accepts new option CURLOPT_SAFE_UPLOAD and CURLFile object for
|
||||
safer file uploads (see https://wiki.php.net/rfc/curl-file-upload)
|
||||
- Functions in the socket extension now do not emit warnings when the errno is
|
||||
EAGAIN, EWOULDBLOCK or EINPROGRESS.
|
||||
Furthermore both set_error_handler(NULL) and
|
||||
set_exception_handler(NULL) will now return the previously defined
|
||||
error/exception handler. Previously bool(true) was returned.
|
||||
|
||||
- setcookie(), setrawcookie() and ext/session now send Max-Age headers
|
||||
alongside Expires headers. (see
|
||||
https://wiki.php.net/rfc/cookie_max-age)
|
||||
|
||||
- curl_setopt now accepts new option CURLOPT_SAFE_UPLOAD and CURLFile
|
||||
object for safer file uploads (see
|
||||
https://wiki.php.net/rfc/curl-file-upload)
|
||||
|
||||
- Functions in the socket extension now do not emit warnings when the
|
||||
errno is EAGAIN, EWOULDBLOCK or EINPROGRESS.
|
||||
|
||||
- Since 5.5.2, spl_autoload_functions() returns different names for
|
||||
different lambda functions registered via spl_autoload_register().
|
||||
|
||||
- Since 5.5.3, DOMDocument::schemaValidateSource() and
|
||||
DOMDocument::schemaValidate() accept flag parameter. Only flag
|
||||
available now is LIBXML_SCHEMA_CREATE. Default is 0.
|
||||
|
||||
========================================
|
||||
5. New Functions
|
||||
@@ -256,8 +304,10 @@ PHP 5.5 UPGRADE NOTES
|
||||
- SPL:
|
||||
- SplFixedArray::__wakeup()
|
||||
- SplDoublyLinkedList::add()
|
||||
- RecursiveTreeIterator::getPostfix() (5.5.2)
|
||||
- RecursiveTreeIterator::setPostfix() (5.5.2)
|
||||
|
||||
- Zend OPcache
|
||||
- Zend OPcache:
|
||||
- opcache_get_configuration()
|
||||
- opcache_get_status()
|
||||
- opcache_reset()
|
||||
@@ -282,6 +332,7 @@ PHP 5.5 UPGRADE NOTES
|
||||
7. Removed Extensions
|
||||
========================================
|
||||
|
||||
None
|
||||
|
||||
========================================
|
||||
8. Other Changes to Extensions
|
||||
@@ -304,7 +355,7 @@ PHP 5.5 UPGRADE NOTES
|
||||
- GD
|
||||
- Added constants for imageflip:
|
||||
. IMG_FLIP_HORIZONTAL
|
||||
. IMG_FLIP_VERTICAL
|
||||
. IMG_FLIP_VERTICAL
|
||||
. IMG_FLIP_BOTH
|
||||
- Added constants for imagecrop
|
||||
. IMG_CROP_DEFAULT
|
||||
@@ -348,18 +399,29 @@ PHP 5.5 UPGRADE NOTES
|
||||
========================================
|
||||
|
||||
- Core:
|
||||
- Added sys_temp_dir INI directive, for specifying temp directory.
|
||||
- Added sys_temp_dir INI directive, for specifying temporary
|
||||
directory.
|
||||
|
||||
- Intl:
|
||||
- Added intl.use_exceptions INI directive, which controls what happens when
|
||||
global errors are set together with intl.error_level.
|
||||
- Added intl.use_exceptions INI directive, which controls what
|
||||
happens when global errors are set together with intl.error_level.
|
||||
|
||||
- MSSQL:
|
||||
- mssql.compatability_mode renamed to mssql.compatibility_mode in 5.5.2,
|
||||
old directive still supported for BC reasons.
|
||||
|
||||
- mysqlnd:
|
||||
- Added mysqlnd.sha256_server_public_key INI PERDIR setting that affects all
|
||||
APIs which use(are built) for mysqlnd. This allows ext/mysqli to be used
|
||||
with the new auth protocol, although at coarser level.
|
||||
- Added mysqlnd.sha256_server_public_key INI PERDIR setting that
|
||||
affects all APIs which use(are built) for mysqlnd. This allows
|
||||
ext/mysqli to be used with the new auth protocol, although at
|
||||
coarser level.
|
||||
|
||||
- Zend OPcache (See ext/opcache/README for more details)
|
||||
- Sessions:
|
||||
- Added session.use_strict_mode in 5.5.3, which prevents session
|
||||
fixation attacks and session collisions.
|
||||
See also https://wiki.php.net/rfc/strict_sessions
|
||||
|
||||
- Zend OPcache (See http://php.net/manual/en/book.opcache.php)
|
||||
- Added the following directives:
|
||||
- opcache.enable (default "1")
|
||||
- opcache.memory_consumption (default "64")
|
||||
@@ -385,32 +447,35 @@ PHP 5.5 UPGRADE NOTES
|
||||
- opcache.preferred_memory_model (default "")
|
||||
- opcache.protect_memory (default "0")
|
||||
- opcache.mmap_base (Windows-only)
|
||||
- If APC or WinCache was used before, the user cache APIs can be replaced by:
|
||||
- APCu, all supported OSes (http://pecl.php.net/package/APCu, Windows: http://windows.php.net/downloads/pecl/releases/apcu/)
|
||||
- WinCache, windows only (http://pecl.php.net/package/WinCache), a version with the ability to use only the user
|
||||
cache will be released shortly after 5.5.0 final
|
||||
|
||||
========================================
|
||||
11. Windows Support
|
||||
========================================
|
||||
|
||||
- Apache 2.4 handler is supported as of PHP 5.5.0
|
||||
- The Apache 2.4 handler is supported as of PHP 5.5.0
|
||||
|
||||
- OPcache: Errors like 'unable to reattach to base address' could
|
||||
happen in many common setups. It is due to some technical and
|
||||
design restriction in the engine and could not be fixed easily
|
||||
before 5.5.0 was released.
|
||||
|
||||
A possible fix is to tweak the opcache.mmap_base INI setting by
|
||||
forcing the first address to be tried.
|
||||
|
||||
- OpCache
|
||||
Error like 'unable to reattach to base address' could happen in many common setups.
|
||||
It is due to some technical and design restriction in the engine and cannot be fixed
|
||||
easily before 5.5.0 final was released.
|
||||
|
||||
A possible fix is to tweak the opcache.mmap_base INI setting by forcing the 1st address
|
||||
to be tried.
|
||||
|
||||
For x86 version, the following addreses can be tried:
|
||||
. 0x20000000, 0x21000000, 0x30000000, 0x31000000, 0x50000000
|
||||
and for x64 (still expiremental):
|
||||
. 0x0000100000000000, 0x0000200000000000, 0x0000300000000000, 0x0000700000000000
|
||||
. 0x20000000, 0x21000000, 0x30000000, 0x31000000, 0x50000000
|
||||
and for x64 (still experimental):
|
||||
. 0x0000100000000000, 0x0000200000000000, 0x0000300000000000, 0x0000700000000000
|
||||
|
||||
========================================
|
||||
12. Other Changes
|
||||
========================================
|
||||
|
||||
- Logo GUIDs will no longer work
|
||||
- If the APC or WinCache user cache APIs were used before, consider
|
||||
these alternatives for PHP 5.5:
|
||||
|
||||
- APCu
|
||||
- all supported OSes: http://pecl.php.net/package/APCu
|
||||
- Windows: http://windows.php.net/downloads/pecl/releases/apcu/
|
||||
|
||||
- WinCache, Windows only: http://pecl.php.net/package/WinCache
|
||||
+1
-1
@@ -6,7 +6,7 @@ fields and using different execution methods (call threading, switch threading
|
||||
and direct threading). As a result ZE2 got more than 20% speedup on raw PHP
|
||||
code execution (with specialized executor and direct threading execution
|
||||
method). As in most PHP applications raw execution speed isn't the limiting
|
||||
factor but system calls and database callls are, your mileage with this patch
|
||||
factor but system calls and database calls are, your mileage with this patch
|
||||
will vary.
|
||||
|
||||
Most parts of the old zend_execute.c go into zend_vm_def.h. Here you can
|
||||
|
||||
+2
-2
@@ -1136,7 +1136,7 @@ Changes in the Zend Engine 1.0
|
||||
(supports breakpoints, expression evaluation, step-in/over,
|
||||
function call backtrace, and more).
|
||||
|
||||
The Zend Engine claims 100% compatability with the engine of PHP
|
||||
The Zend Engine claims 100% compatibility with the engine of PHP
|
||||
3.0, and is shamelessly lying about it. Here's why:
|
||||
|
||||
* Static variable initializers only accept scalar values
|
||||
@@ -1161,6 +1161,6 @@ Changes in the Zend Engine 1.0
|
||||
printed the letter { and the contents of the variable $somevar in
|
||||
PHP 3.0), it will result in a parse error with the Zend Engine.
|
||||
In this case, you would have to change the code to print
|
||||
"\{$somevar"; This incompatability is due to the full variable
|
||||
"\{$somevar"; This incompatibility is due to the full variable
|
||||
reference within quoted strings feature added in the Zend
|
||||
Engine.
|
||||
+10
-10
@@ -1,10 +1,10 @@
|
||||
--TEST--
|
||||
test of larger than 8kb text file being parsed by require statement
|
||||
--FILE--
|
||||
<?php
|
||||
file_put_contents('test.php',str_repeat('passed, ',1024));
|
||||
require('test.php');
|
||||
unlink('test.php');
|
||||
?>
|
||||
--EXPECT--
|
||||
passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed,Line truncated
|
||||
--TEST--
|
||||
test of larger than 8kb text file being parsed by require statement
|
||||
--FILE--
|
||||
<?php
|
||||
file_put_contents('test.php',str_repeat('passed, ',1024));
|
||||
require('./test.php');
|
||||
unlink('test.php');
|
||||
?>
|
||||
--EXPECT--
|
||||
passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed, passed,Line truncated
|
||||
@@ -0,0 +1,27 @@
|
||||
--TEST--
|
||||
Bug #65108 (is_callable() triggers Fatal Error)
|
||||
--FILE--
|
||||
<?php
|
||||
class C {
|
||||
private function f() {}
|
||||
static function __callStatic($name, $args) {}
|
||||
}
|
||||
|
||||
class B {
|
||||
public function B() {
|
||||
$isCallable = is_callable(array(new C, 'f'));
|
||||
var_dump($isCallable);
|
||||
}
|
||||
}
|
||||
|
||||
new B();
|
||||
|
||||
Class E {
|
||||
private function f() {}
|
||||
function __call($name, $args) {}
|
||||
}
|
||||
$isCallable = is_callable(array('E', 'f'));
|
||||
var_dump($isCallable);
|
||||
--EXPECT--
|
||||
bool(false)
|
||||
bool(false)
|
||||
@@ -0,0 +1,21 @@
|
||||
--TEST--
|
||||
Bug #65254 (Exception not catchable when exception thrown in autoload with a namespace)
|
||||
--FILE--
|
||||
<?php
|
||||
function __autoload($class)
|
||||
{
|
||||
eval("namespace ns_test; class test {}");
|
||||
|
||||
throw new \Exception('abcd');
|
||||
}
|
||||
|
||||
try
|
||||
{
|
||||
\ns_test\test::go();
|
||||
}
|
||||
catch (Exception $e)
|
||||
{
|
||||
echo 'caught';
|
||||
}
|
||||
--EXPECT--
|
||||
caught
|
||||
@@ -0,0 +1,25 @@
|
||||
--TEST--
|
||||
Bug #65291 - get_defined_constants() causes PHP to crash in a very limited case.
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
trait TestTrait
|
||||
{
|
||||
public static function testStaticFunction()
|
||||
{
|
||||
return __CLASS__;
|
||||
}
|
||||
}
|
||||
class Tester
|
||||
{
|
||||
use TestTrait;
|
||||
}
|
||||
|
||||
$foo = Tester::testStaticFunction();
|
||||
get_defined_constants();
|
||||
get_defined_constants(true);
|
||||
|
||||
echo $foo;
|
||||
?>
|
||||
--EXPECT--
|
||||
Tester
|
||||
@@ -0,0 +1,40 @@
|
||||
--TEST--
|
||||
Bug #65372 (Segfault in gc_zval_possible_root when return reference fails)
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
class ParentClass
|
||||
{
|
||||
private static $_OBJECTS;
|
||||
|
||||
public static function Get()
|
||||
{
|
||||
self::$_OBJECTS[1] = new ChildClass();
|
||||
return self::$_OBJECTS[1];
|
||||
}
|
||||
}
|
||||
|
||||
class ChildClass extends ParentClass
|
||||
{
|
||||
public $Manager;
|
||||
|
||||
function __construct()
|
||||
{
|
||||
$this->Manager = $this;
|
||||
}
|
||||
|
||||
public static function &GetCurrent()
|
||||
{
|
||||
return ChildClass::Get();
|
||||
}
|
||||
|
||||
public static function &Get()
|
||||
{
|
||||
return parent::Get();
|
||||
}
|
||||
}
|
||||
|
||||
$staff = ChildClass::GetCurrent();
|
||||
?>
|
||||
--EXPECTF--
|
||||
Notice: Only variable references should be returned by reference in %sbug65372.php on line 30
|
||||
@@ -3,7 +3,7 @@ Closure 044: Scope/bounding combination invariants; non static closures
|
||||
--FILE--
|
||||
<?php
|
||||
/* A non-static closure has a bound instance if it has a scope
|
||||
* and does't have an instance if it has no scope */
|
||||
* and doesn't have an instance if it has no scope */
|
||||
|
||||
$nonstaticUnscoped = function () { var_dump(isset(A::$priv)); var_dump(isset($this)); };
|
||||
|
||||
|
||||
@@ -0,0 +1,20 @@
|
||||
--TEST--
|
||||
Bug #65035: yield / exit segfault
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
function gen() {
|
||||
fn();
|
||||
yield;
|
||||
}
|
||||
|
||||
function fn() {
|
||||
exit('Done');
|
||||
}
|
||||
|
||||
$gen = gen();
|
||||
$gen->current();
|
||||
|
||||
?>
|
||||
--EXPECT--
|
||||
Done
|
||||
@@ -0,0 +1,20 @@
|
||||
--TEST--
|
||||
Bug #65161: Generator + autoload + syntax error = segfault
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
function autoload() {
|
||||
foo();
|
||||
}
|
||||
spl_autoload_register('autoload');
|
||||
|
||||
function testGenerator() {
|
||||
new SyntaxError('param');
|
||||
yield;
|
||||
}
|
||||
|
||||
foreach (testGenerator() as $i);
|
||||
|
||||
?>
|
||||
--EXPECTF--
|
||||
Fatal error: Call to undefined function foo() in %s on line %d
|
||||
@@ -1,5 +1,5 @@
|
||||
--TEST--
|
||||
Overridding Conflicting Methods should not result in a notice/warning about collisions
|
||||
Overriding Conflicting Methods should not result in a notice/warning about collisions
|
||||
--FILE--
|
||||
<?php
|
||||
error_reporting(E_ALL);
|
||||
|
||||
+1
-1
@@ -1098,7 +1098,7 @@ ZEND_API void zend_error(int type, const char *format, ...) /* {{{ */
|
||||
if(DTRACE_ERROR_ENABLED()) {
|
||||
char *dtrace_error_buffer;
|
||||
zend_vspprintf(&dtrace_error_buffer, 0, format, args);
|
||||
DTRACE_ERROR(dtrace_error_buffer, error_filename, error_lineno);
|
||||
DTRACE_ERROR(dtrace_error_buffer, (char *)error_filename, error_lineno);
|
||||
efree(dtrace_error_buffer);
|
||||
}
|
||||
#endif /* HAVE_DTRACE */
|
||||
|
||||
+1
-1
@@ -22,7 +22,7 @@
|
||||
#ifndef ZEND_H
|
||||
#define ZEND_H
|
||||
|
||||
#define ZEND_VERSION "2.5.0-dev"
|
||||
#define ZEND_VERSION "2.5.0"
|
||||
|
||||
#define ZEND_ENGINE_2
|
||||
|
||||
|
||||
+2
-2
@@ -2842,8 +2842,8 @@ static int zend_is_callable_check_func(int check_flags, zval *callable, zend_fca
|
||||
}
|
||||
if ((check_flags & IS_CALLABLE_CHECK_NO_ACCESS) == 0 &&
|
||||
(fcc->calling_scope &&
|
||||
(fcc->calling_scope->__call ||
|
||||
fcc->calling_scope->__callstatic))) {
|
||||
((fcc->object_ptr && fcc->calling_scope->__call) ||
|
||||
(!fcc->object_ptr && fcc->calling_scope->__callstatic)))) {
|
||||
if (fcc->function_handler->op_array.fn_flags & ZEND_ACC_PRIVATE) {
|
||||
if (!zend_check_private(fcc->function_handler, fcc->object_ptr ? Z_OBJCE_P(fcc->object_ptr) : EG(scope), lmname, mlen TSRMLS_CC)) {
|
||||
retval = 0;
|
||||
|
||||
+3
-3
@@ -2465,7 +2465,7 @@ static inline size_t safe_address(size_t nmemb, size_t size, size_t offset)
|
||||
size_t res = nmemb;
|
||||
unsigned long overflow = 0;
|
||||
|
||||
__asm__ ("mull %3\n\taddl %4,%0\n\tadcl %1,%1"
|
||||
__asm__ ("mull %3\n\taddl %4,%0\n\tadcl $0,%1"
|
||||
: "=&a"(res), "=&d" (overflow)
|
||||
: "%0"(res),
|
||||
"rm"(size),
|
||||
@@ -2493,7 +2493,7 @@ static inline size_t safe_address(size_t nmemb, size_t size, size_t offset)
|
||||
|
||||
__asm__ ("mul" LP_SUFF " %3\n\t"
|
||||
"add %4,%0\n\t"
|
||||
"adc %1,%1"
|
||||
"adc $0,%1"
|
||||
: "=&a"(res), "=&d" (overflow)
|
||||
: "%0"(res),
|
||||
"rm"(size),
|
||||
@@ -2535,7 +2535,7 @@ static inline size_t safe_address(size_t nmemb, size_t size, size_t offset)
|
||||
size_t res;
|
||||
unsigned long overflow;
|
||||
|
||||
__asm__ ("mul %0,%2,%3\n\tumulh %1,%2,%3\n\tadds %0,%0,%4\n\tadc %1,%1,%1"
|
||||
__asm__ ("mul %0,%2,%3\n\tumulh %1,%2,%3\n\tadds %0,%0,%4\n\tadc %1,%1,xzr"
|
||||
: "=&r"(res), "=&r"(overflow)
|
||||
: "r"(nmemb),
|
||||
"r"(size),
|
||||
|
||||
@@ -1911,6 +1911,11 @@ static int add_constant_info(zend_constant *constant, void *arg TSRMLS_DC)
|
||||
zval *name_array = (zval *)arg;
|
||||
zval *const_val;
|
||||
|
||||
if (!constant->name) {
|
||||
/* skip special constants */
|
||||
return 0;
|
||||
}
|
||||
|
||||
MAKE_STD_ZVAL(const_val);
|
||||
*const_val = constant->value;
|
||||
zval_copy_ctor(const_val);
|
||||
@@ -1978,11 +1983,16 @@ ZEND_FUNCTION(get_defined_constants)
|
||||
while (zend_hash_get_current_data_ex(EG(zend_constants), (void **) &val, &pos) != FAILURE) {
|
||||
zval *const_val;
|
||||
|
||||
if (!val->name) {
|
||||
/* skip special constants */
|
||||
goto next_constant;
|
||||
}
|
||||
|
||||
if (val->module_number == PHP_USER_CONSTANT) {
|
||||
module_number = i;
|
||||
} else if (val->module_number > i || val->module_number < 0) {
|
||||
/* should not happen */
|
||||
goto bad_module_id;
|
||||
goto next_constant;
|
||||
} else {
|
||||
module_number = val->module_number;
|
||||
}
|
||||
@@ -1999,7 +2009,7 @@ ZEND_FUNCTION(get_defined_constants)
|
||||
INIT_PZVAL(const_val);
|
||||
|
||||
add_assoc_zval_ex(modules[module_number], val->name, val->name_len, const_val);
|
||||
bad_module_id:
|
||||
next_constant:
|
||||
zend_hash_move_forward_ex(EG(zend_constants), &pos);
|
||||
}
|
||||
efree(module_names);
|
||||
@@ -2371,7 +2381,7 @@ ZEND_API void zend_fetch_debug_backtrace(zval *return_value, int skip_last, int
|
||||
MAKE_STD_ZVAL(arg_array);
|
||||
array_init(arg_array);
|
||||
|
||||
/* include_filename always points to the last filename of the last last called-fuction.
|
||||
/* include_filename always points to the last filename of the last last called-function.
|
||||
if we have called include in the frame above - this is the file we have included.
|
||||
*/
|
||||
|
||||
|
||||
+4
-4
@@ -1734,7 +1734,7 @@ void zend_do_begin_function_declaration(znode *function_token, znode *function_n
|
||||
}
|
||||
|
||||
{
|
||||
/* Push a seperator to the switch stack */
|
||||
/* Push a separator to the switch stack */
|
||||
zend_switch_entry switch_entry;
|
||||
|
||||
switch_entry.cond.op_type = IS_UNUSED;
|
||||
@@ -1828,7 +1828,7 @@ void zend_do_end_function_declaration(const znode *function_token TSRMLS_DC) /*
|
||||
CG(active_op_array) = function_token->u.op_array;
|
||||
|
||||
|
||||
/* Pop the switch and foreach seperators */
|
||||
/* Pop the switch and foreach separators */
|
||||
zend_stack_del_top(&CG(switch_cond_stack));
|
||||
zend_stack_del_top(&CG(foreach_copy_stack));
|
||||
}
|
||||
@@ -2671,7 +2671,7 @@ static int generate_free_foreach_copy(const zend_op *foreach_copy TSRMLS_DC) /*
|
||||
{
|
||||
zend_op *opline;
|
||||
|
||||
/* If we reach the seperator then stop applying the stack */
|
||||
/* If we reach the separator then stop applying the stack */
|
||||
if (foreach_copy->result_type == IS_UNUSED && foreach_copy->op1_type == IS_UNUSED) {
|
||||
return 1;
|
||||
}
|
||||
@@ -4108,7 +4108,7 @@ static void zend_traits_init_trait_structures(zend_class_entry *ce TSRMLS_DC) /*
|
||||
/** With the other traits, we are more permissive.
|
||||
We do not give errors for those. This allows to be more
|
||||
defensive in such definitions.
|
||||
However, we want to make sure that the insteadof declartion
|
||||
However, we want to make sure that the insteadof declaration
|
||||
is consistent in itself.
|
||||
*/
|
||||
j = 0;
|
||||
|
||||
+11
-11
@@ -24,7 +24,7 @@
|
||||
|
||||
#ifdef HAVE_DTRACE
|
||||
/* PHP DTrace probes {{{ */
|
||||
static inline char *dtrace_get_executed_filename(TSRMLS_D)
|
||||
static inline const char *dtrace_get_executed_filename(TSRMLS_D)
|
||||
{
|
||||
if (EG(current_execute_data) && EG(current_execute_data)->op_array) {
|
||||
return EG(current_execute_data)->op_array->filename;
|
||||
@@ -36,9 +36,9 @@ static inline char *dtrace_get_executed_filename(TSRMLS_D)
|
||||
ZEND_API zend_op_array *dtrace_compile_file(zend_file_handle *file_handle, int type TSRMLS_DC)
|
||||
{
|
||||
zend_op_array *res;
|
||||
DTRACE_COMPILE_FILE_ENTRY(file_handle->opened_path, file_handle->filename);
|
||||
DTRACE_COMPILE_FILE_ENTRY(file_handle->opened_path, (char *)file_handle->filename);
|
||||
res = compile_file(file_handle, type TSRMLS_CC);
|
||||
DTRACE_COMPILE_FILE_RETURN(file_handle->opened_path, file_handle->filename);
|
||||
DTRACE_COMPILE_FILE_RETURN(file_handle->opened_path, (char *)file_handle->filename);
|
||||
|
||||
return res;
|
||||
}
|
||||
@@ -47,7 +47,7 @@ ZEND_API zend_op_array *dtrace_compile_file(zend_file_handle *file_handle, int t
|
||||
ZEND_API void dtrace_execute_ex(zend_execute_data *execute_data TSRMLS_DC)
|
||||
{
|
||||
int lineno;
|
||||
char *scope, *filename, *funcname, *classname;
|
||||
const char *scope, *filename, *funcname, *classname;
|
||||
scope = filename = funcname = classname = NULL;
|
||||
|
||||
/* we need filename and lineno for both execute and function probes */
|
||||
@@ -65,41 +65,41 @@ ZEND_API void dtrace_execute_ex(zend_execute_data *execute_data TSRMLS_DC)
|
||||
}
|
||||
|
||||
if (DTRACE_EXECUTE_ENTRY_ENABLED()) {
|
||||
DTRACE_EXECUTE_ENTRY(filename, lineno);
|
||||
DTRACE_EXECUTE_ENTRY((char *)filename, lineno);
|
||||
}
|
||||
|
||||
if (DTRACE_FUNCTION_ENTRY_ENABLED() && funcname != NULL) {
|
||||
DTRACE_FUNCTION_ENTRY(funcname, filename, lineno, classname, scope);
|
||||
DTRACE_FUNCTION_ENTRY((char *)funcname, (char *)filename, lineno, (char *)classname, (char *)scope);
|
||||
}
|
||||
|
||||
execute_ex(execute_data TSRMLS_CC);
|
||||
|
||||
if (DTRACE_FUNCTION_RETURN_ENABLED() && funcname != NULL) {
|
||||
DTRACE_FUNCTION_RETURN(funcname, filename, lineno, classname, scope);
|
||||
DTRACE_FUNCTION_RETURN((char *)funcname, (char *)filename, lineno, (char *)classname, (char *)scope);
|
||||
}
|
||||
|
||||
if (DTRACE_EXECUTE_RETURN_ENABLED()) {
|
||||
DTRACE_EXECUTE_RETURN(filename, lineno);
|
||||
DTRACE_EXECUTE_RETURN((char *)filename, lineno);
|
||||
}
|
||||
}
|
||||
|
||||
ZEND_API void dtrace_execute_internal(zend_execute_data *execute_data_ptr, zend_fcall_info *fci, int return_value_used TSRMLS_DC)
|
||||
{
|
||||
int lineno;
|
||||
char *filename;
|
||||
const char *filename;
|
||||
if (DTRACE_EXECUTE_ENTRY_ENABLED() || DTRACE_EXECUTE_RETURN_ENABLED()) {
|
||||
filename = dtrace_get_executed_filename(TSRMLS_C);
|
||||
lineno = zend_get_executed_lineno(TSRMLS_C);
|
||||
}
|
||||
|
||||
if (DTRACE_EXECUTE_ENTRY_ENABLED()) {
|
||||
DTRACE_EXECUTE_ENTRY(filename, lineno);
|
||||
DTRACE_EXECUTE_ENTRY((char *)filename, lineno);
|
||||
}
|
||||
|
||||
execute_internal(execute_data_ptr, fci, return_value_used TSRMLS_CC);
|
||||
|
||||
if (DTRACE_EXECUTE_RETURN_ENABLED()) {
|
||||
DTRACE_EXECUTE_RETURN(filename, lineno);
|
||||
DTRACE_EXECUTE_RETURN((char *)filename, lineno);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -85,12 +85,12 @@ void zend_throw_exception_internal(zval *exception TSRMLS_DC) /* {{{ */
|
||||
{
|
||||
#ifdef HAVE_DTRACE
|
||||
if (DTRACE_EXCEPTION_THROWN_ENABLED()) {
|
||||
char *classname;
|
||||
int name_len;
|
||||
const char *classname;
|
||||
zend_uint name_len;
|
||||
|
||||
if (exception != NULL) {
|
||||
zend_get_object_classname(exception, &classname, &name_len TSRMLS_CC);
|
||||
DTRACE_EXCEPTION_THROWN(classname);
|
||||
DTRACE_EXCEPTION_THROWN((char *)classname);
|
||||
} else {
|
||||
DTRACE_EXCEPTION_THROWN(NULL);
|
||||
}
|
||||
|
||||
@@ -1054,7 +1054,7 @@ ZEND_API int zend_lookup_class_ex(const char *name, int name_length, const zend_
|
||||
}
|
||||
|
||||
/* The compiler is not-reentrant. Make sure we __autoload() only during run-time
|
||||
* (doesn't impact fuctionality of __autoload()
|
||||
* (doesn't impact functionality of __autoload()
|
||||
*/
|
||||
if (!use_autoload || zend_is_compiling(TSRMLS_C)) {
|
||||
if (!key) {
|
||||
|
||||
@@ -55,6 +55,12 @@ ZEND_API void zend_generator_close(zend_generator *generator, zend_bool finished
|
||||
zval_ptr_dtor(&execute_data->current_this);
|
||||
}
|
||||
|
||||
/* A fatal error / die occurred during the generator execution. Trying to clean
|
||||
* up the stack may not be safe in this case. */
|
||||
if (CG(unclean_shutdown)) {
|
||||
return;
|
||||
}
|
||||
|
||||
/* If the generator is closed before it can finish execution (reach
|
||||
* a return statement) we have to free loop variables manually, as
|
||||
* we don't know whether the SWITCH_FREE / FREE opcodes have run */
|
||||
|
||||
+1
-1
@@ -302,7 +302,7 @@ struct _zend_php_scanner_globals {
|
||||
unsigned char *script_filtered;
|
||||
size_t script_filtered_size;
|
||||
|
||||
/* input/ouput filters */
|
||||
/* input/output filters */
|
||||
zend_encoding_filter input_filter;
|
||||
zend_encoding_filter output_filter;
|
||||
const zend_encoding *script_encoding;
|
||||
|
||||
+2
-2
@@ -1168,7 +1168,7 @@ ZEND_API int zend_hash_get_current_key_ex(const HashTable *ht, char **str_index,
|
||||
return HASH_KEY_IS_LONG;
|
||||
}
|
||||
}
|
||||
return HASH_KEY_NON_EXISTANT;
|
||||
return HASH_KEY_NON_EXISTENT;
|
||||
}
|
||||
|
||||
ZEND_API void zend_hash_get_current_key_zval_ex(const HashTable *ht, zval *key, HashPosition *pos) {
|
||||
@@ -1205,7 +1205,7 @@ ZEND_API int zend_hash_get_current_key_type_ex(HashTable *ht, HashPosition *pos)
|
||||
return HASH_KEY_IS_LONG;
|
||||
}
|
||||
}
|
||||
return HASH_KEY_NON_EXISTANT;
|
||||
return HASH_KEY_NON_EXISTENT;
|
||||
}
|
||||
|
||||
|
||||
|
||||
+3
-2
@@ -27,7 +27,8 @@
|
||||
|
||||
#define HASH_KEY_IS_STRING 1
|
||||
#define HASH_KEY_IS_LONG 2
|
||||
#define HASH_KEY_NON_EXISTANT 3
|
||||
#define HASH_KEY_NON_EXISTENT 3
|
||||
#define HASH_KEY_NON_EXISTANT HASH_KEY_NON_EXISTENT /* Keeping old define (with typo) for backward compatibility */
|
||||
|
||||
#define HASH_UPDATE (1<<0)
|
||||
#define HASH_ADD (1<<1)
|
||||
@@ -172,7 +173,7 @@ ZEND_API ulong zend_hash_next_free_element(const HashTable *ht);
|
||||
|
||||
/* traversing */
|
||||
#define zend_hash_has_more_elements_ex(ht, pos) \
|
||||
(zend_hash_get_current_key_type_ex(ht, pos) == HASH_KEY_NON_EXISTANT ? FAILURE : SUCCESS)
|
||||
(zend_hash_get_current_key_type_ex(ht, pos) == HASH_KEY_NON_EXISTENT ? FAILURE : SUCCESS)
|
||||
ZEND_API int zend_hash_move_forward_ex(HashTable *ht, HashPosition *pos);
|
||||
ZEND_API int zend_hash_move_backwards_ex(HashTable *ht, HashPosition *pos);
|
||||
ZEND_API int zend_hash_get_current_key_ex(const HashTable *ht, char **str_index, uint *str_length, ulong *num_index, zend_bool duplicate, HashPosition *pos);
|
||||
|
||||
@@ -45,7 +45,7 @@ typedef struct _zend_lex_state {
|
||||
unsigned char *script_filtered;
|
||||
size_t script_filtered_size;
|
||||
|
||||
/* input/ouput filters */
|
||||
/* input/output filters */
|
||||
zend_encoding_filter input_filter;
|
||||
zend_encoding_filter output_filter;
|
||||
const zend_encoding *script_encoding;
|
||||
|
||||
+21
-14
@@ -2517,9 +2517,11 @@ ZEND_VM_HANDLER(113, ZEND_INIT_STATIC_METHOD_CALL, CONST|VAR, CONST|TMP|VAR|UNUS
|
||||
ce = CACHED_PTR(opline->op1.literal->cache_slot);
|
||||
} else {
|
||||
ce = zend_fetch_class_by_name(Z_STRVAL_P(opline->op1.zv), Z_STRLEN_P(opline->op1.zv), opline->op1.literal + 1, opline->extended_value TSRMLS_CC);
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
HANDLE_EXCEPTION();
|
||||
}
|
||||
if (UNEXPECTED(ce == NULL)) {
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
zend_error_noreturn(E_ERROR, "Class '%s' not found", Z_STRVAL_P(opline->op1.zv));
|
||||
}
|
||||
CACHE_PTR(opline->op1.literal->cache_slot, ce);
|
||||
}
|
||||
@@ -2918,9 +2920,12 @@ ZEND_VM_HANDLER(111, ZEND_RETURN_BY_REF, CONST|TMP|VAR|CV, ANY)
|
||||
} else if (EX_T(opline->op1.var).var.ptr_ptr == &EX_T(opline->op1.var).var.ptr) {
|
||||
zend_error(E_NOTICE, "Only variable references should be returned by reference");
|
||||
if (EG(return_value_ptr_ptr)) {
|
||||
retval_ptr = *retval_ptr_ptr;
|
||||
*EG(return_value_ptr_ptr) = retval_ptr;
|
||||
Z_ADDREF_P(retval_ptr);
|
||||
zval *ret;
|
||||
|
||||
ALLOC_ZVAL(ret);
|
||||
INIT_PZVAL_COPY(ret, *retval_ptr_ptr);
|
||||
zval_copy_ctor(ret);
|
||||
*EG(return_value_ptr_ptr) = ret;
|
||||
}
|
||||
break;
|
||||
}
|
||||
@@ -3005,7 +3010,7 @@ ZEND_VM_HANDLER(107, ZEND_CATCH, CONST, CV)
|
||||
|
||||
#ifdef HAVE_DTRACE
|
||||
if (DTRACE_EXCEPTION_CAUGHT_ENABLED()) {
|
||||
DTRACE_EXCEPTION_CAUGHT(ce->name);
|
||||
DTRACE_EXCEPTION_CAUGHT((char *)ce->name);
|
||||
}
|
||||
#endif /* HAVE_DTRACE */
|
||||
|
||||
@@ -3296,7 +3301,6 @@ ZEND_VM_HANDLER(50, ZEND_BRK, ANY, CONST)
|
||||
SAVE_OPLINE();
|
||||
el = zend_brk_cont(Z_LVAL_P(opline->op2.zv), opline->op1.opline_num,
|
||||
EX(op_array), execute_data TSRMLS_CC);
|
||||
FREE_OP2();
|
||||
ZEND_VM_JMP(EX(op_array)->opcodes + el->brk);
|
||||
}
|
||||
|
||||
@@ -3308,7 +3312,6 @@ ZEND_VM_HANDLER(51, ZEND_CONT, ANY, CONST)
|
||||
SAVE_OPLINE();
|
||||
el = zend_brk_cont(Z_LVAL_P(opline->op2.zv), opline->op1.opline_num,
|
||||
EX(op_array), execute_data TSRMLS_CC);
|
||||
FREE_OP2();
|
||||
ZEND_VM_JMP(EX(op_array)->opcodes + el->cont);
|
||||
}
|
||||
|
||||
@@ -3534,9 +3537,11 @@ ZEND_VM_HANDLER(99, ZEND_FETCH_CONSTANT, VAR|CONST|UNUSED, CONST)
|
||||
ce = CACHED_PTR(opline->op1.literal->cache_slot);
|
||||
} else {
|
||||
ce = zend_fetch_class_by_name(Z_STRVAL_P(opline->op1.zv), Z_STRLEN_P(opline->op1.zv), opline->op1.literal + 1, opline->extended_value TSRMLS_CC);
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
HANDLE_EXCEPTION();
|
||||
}
|
||||
if (UNEXPECTED(ce == NULL)) {
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
zend_error_noreturn(E_ERROR, "Class '%s' not found", Z_STRVAL_P(opline->op1.zv));
|
||||
}
|
||||
CACHE_PTR(opline->op1.literal->cache_slot, ce);
|
||||
}
|
||||
@@ -3914,15 +3919,17 @@ ZEND_VM_HANDLER(74, ZEND_UNSET_VAR, CONST|TMP|VAR|CV, UNUSED|CONST|VAR)
|
||||
ce = CACHED_PTR(opline->op2.literal->cache_slot);
|
||||
} else {
|
||||
ce = zend_fetch_class_by_name(Z_STRVAL_P(opline->op2.zv), Z_STRLEN_P(opline->op2.zv), opline->op2.literal + 1, 0 TSRMLS_CC);
|
||||
if (UNEXPECTED(ce == NULL)) {
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
if (OP1_TYPE != IS_CONST && varname == &tmp) {
|
||||
zval_dtor(&tmp);
|
||||
} else if (OP1_TYPE == IS_VAR || OP1_TYPE == IS_CV) {
|
||||
zval_ptr_dtor(&varname);
|
||||
}
|
||||
FREE_OP1();
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
HANDLE_EXCEPTION();
|
||||
}
|
||||
if (UNEXPECTED(ce == NULL)) {
|
||||
zend_error_noreturn(E_ERROR, "Class '%s' not found", Z_STRVAL_P(opline->op2.zv));
|
||||
}
|
||||
CACHE_PTR(opline->op2.literal->cache_slot, ce);
|
||||
}
|
||||
@@ -4207,7 +4214,7 @@ ZEND_VM_HANDLER(77, ZEND_FE_RESET, CONST|TMP|VAR|CV, ANY)
|
||||
zend_uchar key_type;
|
||||
|
||||
key_type = zend_hash_get_current_key_ex(fe_ht, &str_key, &str_key_len, &int_key, 0, NULL);
|
||||
if (key_type != HASH_KEY_NON_EXISTANT &&
|
||||
if (key_type != HASH_KEY_NON_EXISTENT &&
|
||||
(key_type == HASH_KEY_IS_LONG ||
|
||||
zend_check_property_access(zobj, str_key, str_key_len-1 TSRMLS_CC) == SUCCESS)) {
|
||||
break;
|
||||
|
||||
+141
-81
@@ -1423,7 +1423,6 @@ static int ZEND_FASTCALL ZEND_BRK_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
SAVE_OPLINE();
|
||||
el = zend_brk_cont(Z_LVAL_P(opline->op2.zv), opline->op1.opline_num,
|
||||
EX(op_array), execute_data TSRMLS_CC);
|
||||
|
||||
ZEND_VM_JMP(EX(op_array)->opcodes + el->brk);
|
||||
}
|
||||
|
||||
@@ -1435,7 +1434,6 @@ static int ZEND_FASTCALL ZEND_CONT_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
|
||||
SAVE_OPLINE();
|
||||
el = zend_brk_cont(Z_LVAL_P(opline->op2.zv), opline->op1.opline_num,
|
||||
EX(op_array), execute_data TSRMLS_CC);
|
||||
|
||||
ZEND_VM_JMP(EX(op_array)->opcodes + el->cont);
|
||||
}
|
||||
|
||||
@@ -2412,9 +2410,12 @@ static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_CONST_HANDLER(ZEND_OPCODE_HAND
|
||||
} else if (EX_T(opline->op1.var).var.ptr_ptr == &EX_T(opline->op1.var).var.ptr) {
|
||||
zend_error(E_NOTICE, "Only variable references should be returned by reference");
|
||||
if (EG(return_value_ptr_ptr)) {
|
||||
retval_ptr = *retval_ptr_ptr;
|
||||
*EG(return_value_ptr_ptr) = retval_ptr;
|
||||
Z_ADDREF_P(retval_ptr);
|
||||
zval *ret;
|
||||
|
||||
ALLOC_ZVAL(ret);
|
||||
INIT_PZVAL_COPY(ret, *retval_ptr_ptr);
|
||||
zval_copy_ctor(ret);
|
||||
*EG(return_value_ptr_ptr) = ret;
|
||||
}
|
||||
break;
|
||||
}
|
||||
@@ -2882,7 +2883,7 @@ static int ZEND_FASTCALL ZEND_FE_RESET_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_A
|
||||
zend_uchar key_type;
|
||||
|
||||
key_type = zend_hash_get_current_key_ex(fe_ht, &str_key, &str_key_len, &int_key, 0, NULL);
|
||||
if (key_type != HASH_KEY_NON_EXISTANT &&
|
||||
if (key_type != HASH_KEY_NON_EXISTENT &&
|
||||
(key_type == HASH_KEY_IS_LONG ||
|
||||
zend_check_property_access(zobj, str_key, str_key_len-1 TSRMLS_CC) == SUCCESS)) {
|
||||
break;
|
||||
@@ -3540,9 +3541,11 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_CONST_HANDLER(
|
||||
ce = CACHED_PTR(opline->op1.literal->cache_slot);
|
||||
} else {
|
||||
ce = zend_fetch_class_by_name(Z_STRVAL_P(opline->op1.zv), Z_STRLEN_P(opline->op1.zv), opline->op1.literal + 1, opline->extended_value TSRMLS_CC);
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
HANDLE_EXCEPTION();
|
||||
}
|
||||
if (UNEXPECTED(ce == NULL)) {
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
zend_error_noreturn(E_ERROR, "Class '%s' not found", Z_STRVAL_P(opline->op1.zv));
|
||||
}
|
||||
CACHE_PTR(opline->op1.literal->cache_slot, ce);
|
||||
}
|
||||
@@ -3714,9 +3717,11 @@ static int ZEND_FASTCALL ZEND_FETCH_CONSTANT_SPEC_CONST_CONST_HANDLER(ZEND_OPCO
|
||||
ce = CACHED_PTR(opline->op1.literal->cache_slot);
|
||||
} else {
|
||||
ce = zend_fetch_class_by_name(Z_STRVAL_P(opline->op1.zv), Z_STRLEN_P(opline->op1.zv), opline->op1.literal + 1, opline->extended_value TSRMLS_CC);
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
HANDLE_EXCEPTION();
|
||||
}
|
||||
if (UNEXPECTED(ce == NULL)) {
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
zend_error_noreturn(E_ERROR, "Class '%s' not found", Z_STRVAL_P(opline->op1.zv));
|
||||
}
|
||||
CACHE_PTR(opline->op1.literal->cache_slot, ce);
|
||||
}
|
||||
@@ -3901,15 +3906,17 @@ static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HA
|
||||
ce = CACHED_PTR(opline->op2.literal->cache_slot);
|
||||
} else {
|
||||
ce = zend_fetch_class_by_name(Z_STRVAL_P(opline->op2.zv), Z_STRLEN_P(opline->op2.zv), opline->op2.literal + 1, 0 TSRMLS_CC);
|
||||
if (UNEXPECTED(ce == NULL)) {
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
if (IS_CONST != IS_CONST && varname == &tmp) {
|
||||
zval_dtor(&tmp);
|
||||
} else if (IS_CONST == IS_VAR || IS_CONST == IS_CV) {
|
||||
zval_ptr_dtor(&varname);
|
||||
}
|
||||
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
HANDLE_EXCEPTION();
|
||||
}
|
||||
if (UNEXPECTED(ce == NULL)) {
|
||||
zend_error_noreturn(E_ERROR, "Class '%s' not found", Z_STRVAL_P(opline->op2.zv));
|
||||
}
|
||||
CACHE_PTR(opline->op2.literal->cache_slot, ce);
|
||||
}
|
||||
@@ -4533,9 +4540,11 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_TMP_HANDLER(ZE
|
||||
ce = CACHED_PTR(opline->op1.literal->cache_slot);
|
||||
} else {
|
||||
ce = zend_fetch_class_by_name(Z_STRVAL_P(opline->op1.zv), Z_STRLEN_P(opline->op1.zv), opline->op1.literal + 1, opline->extended_value TSRMLS_CC);
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
HANDLE_EXCEPTION();
|
||||
}
|
||||
if (UNEXPECTED(ce == NULL)) {
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
zend_error_noreturn(E_ERROR, "Class '%s' not found", Z_STRVAL_P(opline->op1.zv));
|
||||
}
|
||||
CACHE_PTR(opline->op1.literal->cache_slot, ce);
|
||||
}
|
||||
@@ -5395,9 +5404,11 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_VAR_HANDLER(ZE
|
||||
ce = CACHED_PTR(opline->op1.literal->cache_slot);
|
||||
} else {
|
||||
ce = zend_fetch_class_by_name(Z_STRVAL_P(opline->op1.zv), Z_STRLEN_P(opline->op1.zv), opline->op1.literal + 1, opline->extended_value TSRMLS_CC);
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
HANDLE_EXCEPTION();
|
||||
}
|
||||
if (UNEXPECTED(ce == NULL)) {
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
zend_error_noreturn(E_ERROR, "Class '%s' not found", Z_STRVAL_P(opline->op1.zv));
|
||||
}
|
||||
CACHE_PTR(opline->op1.literal->cache_slot, ce);
|
||||
}
|
||||
@@ -5662,15 +5673,17 @@ static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HAND
|
||||
ce = CACHED_PTR(opline->op2.literal->cache_slot);
|
||||
} else {
|
||||
ce = zend_fetch_class_by_name(Z_STRVAL_P(opline->op2.zv), Z_STRLEN_P(opline->op2.zv), opline->op2.literal + 1, 0 TSRMLS_CC);
|
||||
if (UNEXPECTED(ce == NULL)) {
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
if (IS_CONST != IS_CONST && varname == &tmp) {
|
||||
zval_dtor(&tmp);
|
||||
} else if (IS_CONST == IS_VAR || IS_CONST == IS_CV) {
|
||||
zval_ptr_dtor(&varname);
|
||||
}
|
||||
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
HANDLE_EXCEPTION();
|
||||
}
|
||||
if (UNEXPECTED(ce == NULL)) {
|
||||
zend_error_noreturn(E_ERROR, "Class '%s' not found", Z_STRVAL_P(opline->op2.zv));
|
||||
}
|
||||
CACHE_PTR(opline->op2.literal->cache_slot, ce);
|
||||
}
|
||||
@@ -6113,9 +6126,11 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_UNUSED_HANDLER
|
||||
ce = CACHED_PTR(opline->op1.literal->cache_slot);
|
||||
} else {
|
||||
ce = zend_fetch_class_by_name(Z_STRVAL_P(opline->op1.zv), Z_STRLEN_P(opline->op1.zv), opline->op1.literal + 1, opline->extended_value TSRMLS_CC);
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
HANDLE_EXCEPTION();
|
||||
}
|
||||
if (UNEXPECTED(ce == NULL)) {
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
zend_error_noreturn(E_ERROR, "Class '%s' not found", Z_STRVAL_P(opline->op1.zv));
|
||||
}
|
||||
CACHE_PTR(opline->op1.literal->cache_slot, ce);
|
||||
}
|
||||
@@ -6362,15 +6377,17 @@ static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_CONST_UNUSED_HANDLER(ZEND_OPCODE_H
|
||||
ce = CACHED_PTR(opline->op2.literal->cache_slot);
|
||||
} else {
|
||||
ce = zend_fetch_class_by_name(Z_STRVAL_P(opline->op2.zv), Z_STRLEN_P(opline->op2.zv), opline->op2.literal + 1, 0 TSRMLS_CC);
|
||||
if (UNEXPECTED(ce == NULL)) {
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
if (IS_CONST != IS_CONST && varname == &tmp) {
|
||||
zval_dtor(&tmp);
|
||||
} else if (IS_CONST == IS_VAR || IS_CONST == IS_CV) {
|
||||
zval_ptr_dtor(&varname);
|
||||
}
|
||||
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
HANDLE_EXCEPTION();
|
||||
}
|
||||
if (UNEXPECTED(ce == NULL)) {
|
||||
zend_error_noreturn(E_ERROR, "Class '%s' not found", Z_STRVAL_P(opline->op2.zv));
|
||||
}
|
||||
CACHE_PTR(opline->op2.literal->cache_slot, ce);
|
||||
}
|
||||
@@ -6972,9 +6989,11 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_CV_HANDLER(ZEN
|
||||
ce = CACHED_PTR(opline->op1.literal->cache_slot);
|
||||
} else {
|
||||
ce = zend_fetch_class_by_name(Z_STRVAL_P(opline->op1.zv), Z_STRLEN_P(opline->op1.zv), opline->op1.literal + 1, opline->extended_value TSRMLS_CC);
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
HANDLE_EXCEPTION();
|
||||
}
|
||||
if (UNEXPECTED(ce == NULL)) {
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
zend_error_noreturn(E_ERROR, "Class '%s' not found", Z_STRVAL_P(opline->op1.zv));
|
||||
}
|
||||
CACHE_PTR(opline->op1.literal->cache_slot, ce);
|
||||
}
|
||||
@@ -7102,7 +7121,7 @@ static int ZEND_FASTCALL ZEND_CATCH_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_A
|
||||
|
||||
#ifdef HAVE_DTRACE
|
||||
if (DTRACE_EXCEPTION_CAUGHT_ENABLED()) {
|
||||
DTRACE_EXCEPTION_CAUGHT(ce->name);
|
||||
DTRACE_EXCEPTION_CAUGHT((char *)ce->name);
|
||||
}
|
||||
#endif /* HAVE_DTRACE */
|
||||
|
||||
@@ -7719,9 +7738,12 @@ static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLE
|
||||
} else if (EX_T(opline->op1.var).var.ptr_ptr == &EX_T(opline->op1.var).var.ptr) {
|
||||
zend_error(E_NOTICE, "Only variable references should be returned by reference");
|
||||
if (EG(return_value_ptr_ptr)) {
|
||||
retval_ptr = *retval_ptr_ptr;
|
||||
*EG(return_value_ptr_ptr) = retval_ptr;
|
||||
Z_ADDREF_P(retval_ptr);
|
||||
zval *ret;
|
||||
|
||||
ALLOC_ZVAL(ret);
|
||||
INIT_PZVAL_COPY(ret, *retval_ptr_ptr);
|
||||
zval_copy_ctor(ret);
|
||||
*EG(return_value_ptr_ptr) = ret;
|
||||
}
|
||||
break;
|
||||
}
|
||||
@@ -8190,7 +8212,7 @@ static int ZEND_FASTCALL ZEND_FE_RESET_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARG
|
||||
zend_uchar key_type;
|
||||
|
||||
key_type = zend_hash_get_current_key_ex(fe_ht, &str_key, &str_key_len, &int_key, 0, NULL);
|
||||
if (key_type != HASH_KEY_NON_EXISTANT &&
|
||||
if (key_type != HASH_KEY_NON_EXISTENT &&
|
||||
(key_type == HASH_KEY_IS_LONG ||
|
||||
zend_check_property_access(zobj, str_key, str_key_len-1 TSRMLS_CC) == SUCCESS)) {
|
||||
break;
|
||||
@@ -9170,15 +9192,17 @@ static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HAND
|
||||
ce = CACHED_PTR(opline->op2.literal->cache_slot);
|
||||
} else {
|
||||
ce = zend_fetch_class_by_name(Z_STRVAL_P(opline->op2.zv), Z_STRLEN_P(opline->op2.zv), opline->op2.literal + 1, 0 TSRMLS_CC);
|
||||
if (UNEXPECTED(ce == NULL)) {
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
if (IS_TMP_VAR != IS_CONST && varname == &tmp) {
|
||||
zval_dtor(&tmp);
|
||||
} else if (IS_TMP_VAR == IS_VAR || IS_TMP_VAR == IS_CV) {
|
||||
zval_ptr_dtor(&varname);
|
||||
}
|
||||
zval_dtor(free_op1.var);
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
HANDLE_EXCEPTION();
|
||||
}
|
||||
if (UNEXPECTED(ce == NULL)) {
|
||||
zend_error_noreturn(E_ERROR, "Class '%s' not found", Z_STRVAL_P(opline->op2.zv));
|
||||
}
|
||||
CACHE_PTR(opline->op2.literal->cache_slot, ce);
|
||||
}
|
||||
@@ -10899,15 +10923,17 @@ static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLE
|
||||
ce = CACHED_PTR(opline->op2.literal->cache_slot);
|
||||
} else {
|
||||
ce = zend_fetch_class_by_name(Z_STRVAL_P(opline->op2.zv), Z_STRLEN_P(opline->op2.zv), opline->op2.literal + 1, 0 TSRMLS_CC);
|
||||
if (UNEXPECTED(ce == NULL)) {
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
if (IS_TMP_VAR != IS_CONST && varname == &tmp) {
|
||||
zval_dtor(&tmp);
|
||||
} else if (IS_TMP_VAR == IS_VAR || IS_TMP_VAR == IS_CV) {
|
||||
zval_ptr_dtor(&varname);
|
||||
}
|
||||
zval_dtor(free_op1.var);
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
HANDLE_EXCEPTION();
|
||||
}
|
||||
if (UNEXPECTED(ce == NULL)) {
|
||||
zend_error_noreturn(E_ERROR, "Class '%s' not found", Z_STRVAL_P(opline->op2.zv));
|
||||
}
|
||||
CACHE_PTR(opline->op2.literal->cache_slot, ce);
|
||||
}
|
||||
@@ -11478,15 +11504,17 @@ static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_TMP_UNUSED_HANDLER(ZEND_OPCODE_HAN
|
||||
ce = CACHED_PTR(opline->op2.literal->cache_slot);
|
||||
} else {
|
||||
ce = zend_fetch_class_by_name(Z_STRVAL_P(opline->op2.zv), Z_STRLEN_P(opline->op2.zv), opline->op2.literal + 1, 0 TSRMLS_CC);
|
||||
if (UNEXPECTED(ce == NULL)) {
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
if (IS_TMP_VAR != IS_CONST && varname == &tmp) {
|
||||
zval_dtor(&tmp);
|
||||
} else if (IS_TMP_VAR == IS_VAR || IS_TMP_VAR == IS_CV) {
|
||||
zval_ptr_dtor(&varname);
|
||||
}
|
||||
zval_dtor(free_op1.var);
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
HANDLE_EXCEPTION();
|
||||
}
|
||||
if (UNEXPECTED(ce == NULL)) {
|
||||
zend_error_noreturn(E_ERROR, "Class '%s' not found", Z_STRVAL_P(opline->op2.zv));
|
||||
}
|
||||
CACHE_PTR(opline->op2.literal->cache_slot, ce);
|
||||
}
|
||||
@@ -12939,9 +12967,12 @@ static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLE
|
||||
} else if (EX_T(opline->op1.var).var.ptr_ptr == &EX_T(opline->op1.var).var.ptr) {
|
||||
zend_error(E_NOTICE, "Only variable references should be returned by reference");
|
||||
if (EG(return_value_ptr_ptr)) {
|
||||
retval_ptr = *retval_ptr_ptr;
|
||||
*EG(return_value_ptr_ptr) = retval_ptr;
|
||||
Z_ADDREF_P(retval_ptr);
|
||||
zval *ret;
|
||||
|
||||
ALLOC_ZVAL(ret);
|
||||
INIT_PZVAL_COPY(ret, *retval_ptr_ptr);
|
||||
zval_copy_ctor(ret);
|
||||
*EG(return_value_ptr_ptr) = ret;
|
||||
}
|
||||
break;
|
||||
}
|
||||
@@ -13522,7 +13553,7 @@ static int ZEND_FASTCALL ZEND_FE_RESET_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG
|
||||
zend_uchar key_type;
|
||||
|
||||
key_type = zend_hash_get_current_key_ex(fe_ht, &str_key, &str_key_len, &int_key, 0, NULL);
|
||||
if (key_type != HASH_KEY_NON_EXISTANT &&
|
||||
if (key_type != HASH_KEY_NON_EXISTENT &&
|
||||
(key_type == HASH_KEY_IS_LONG ||
|
||||
zend_check_property_access(zobj, str_key, str_key_len-1 TSRMLS_CC) == SUCCESS)) {
|
||||
break;
|
||||
@@ -15411,9 +15442,11 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_CONST_HANDLER(ZE
|
||||
ce = CACHED_PTR(opline->op1.literal->cache_slot);
|
||||
} else {
|
||||
ce = zend_fetch_class_by_name(Z_STRVAL_P(opline->op1.zv), Z_STRLEN_P(opline->op1.zv), opline->op1.literal + 1, opline->extended_value TSRMLS_CC);
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
HANDLE_EXCEPTION();
|
||||
}
|
||||
if (UNEXPECTED(ce == NULL)) {
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
zend_error_noreturn(E_ERROR, "Class '%s' not found", Z_STRVAL_P(opline->op1.zv));
|
||||
}
|
||||
CACHE_PTR(opline->op1.literal->cache_slot, ce);
|
||||
}
|
||||
@@ -15585,9 +15618,11 @@ static int ZEND_FASTCALL ZEND_FETCH_CONSTANT_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE
|
||||
ce = CACHED_PTR(opline->op1.literal->cache_slot);
|
||||
} else {
|
||||
ce = zend_fetch_class_by_name(Z_STRVAL_P(opline->op1.zv), Z_STRLEN_P(opline->op1.zv), opline->op1.literal + 1, opline->extended_value TSRMLS_CC);
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
HANDLE_EXCEPTION();
|
||||
}
|
||||
if (UNEXPECTED(ce == NULL)) {
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
zend_error_noreturn(E_ERROR, "Class '%s' not found", Z_STRVAL_P(opline->op1.zv));
|
||||
}
|
||||
CACHE_PTR(opline->op1.literal->cache_slot, ce);
|
||||
}
|
||||
@@ -15772,15 +15807,17 @@ static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HAND
|
||||
ce = CACHED_PTR(opline->op2.literal->cache_slot);
|
||||
} else {
|
||||
ce = zend_fetch_class_by_name(Z_STRVAL_P(opline->op2.zv), Z_STRLEN_P(opline->op2.zv), opline->op2.literal + 1, 0 TSRMLS_CC);
|
||||
if (UNEXPECTED(ce == NULL)) {
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
if (IS_VAR != IS_CONST && varname == &tmp) {
|
||||
zval_dtor(&tmp);
|
||||
} else if (IS_VAR == IS_VAR || IS_VAR == IS_CV) {
|
||||
zval_ptr_dtor(&varname);
|
||||
}
|
||||
if (free_op1.var) {zval_ptr_dtor(&free_op1.var);};
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
HANDLE_EXCEPTION();
|
||||
}
|
||||
if (UNEXPECTED(ce == NULL)) {
|
||||
zend_error_noreturn(E_ERROR, "Class '%s' not found", Z_STRVAL_P(opline->op2.zv));
|
||||
}
|
||||
CACHE_PTR(opline->op2.literal->cache_slot, ce);
|
||||
}
|
||||
@@ -17763,9 +17800,11 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_TMP_HANDLER(ZEND
|
||||
ce = CACHED_PTR(opline->op1.literal->cache_slot);
|
||||
} else {
|
||||
ce = zend_fetch_class_by_name(Z_STRVAL_P(opline->op1.zv), Z_STRLEN_P(opline->op1.zv), opline->op1.literal + 1, opline->extended_value TSRMLS_CC);
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
HANDLE_EXCEPTION();
|
||||
}
|
||||
if (UNEXPECTED(ce == NULL)) {
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
zend_error_noreturn(E_ERROR, "Class '%s' not found", Z_STRVAL_P(opline->op1.zv));
|
||||
}
|
||||
CACHE_PTR(opline->op1.literal->cache_slot, ce);
|
||||
}
|
||||
@@ -20079,9 +20118,11 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_VAR_HANDLER(ZEND
|
||||
ce = CACHED_PTR(opline->op1.literal->cache_slot);
|
||||
} else {
|
||||
ce = zend_fetch_class_by_name(Z_STRVAL_P(opline->op1.zv), Z_STRLEN_P(opline->op1.zv), opline->op1.literal + 1, opline->extended_value TSRMLS_CC);
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
HANDLE_EXCEPTION();
|
||||
}
|
||||
if (UNEXPECTED(ce == NULL)) {
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
zend_error_noreturn(E_ERROR, "Class '%s' not found", Z_STRVAL_P(opline->op1.zv));
|
||||
}
|
||||
CACHE_PTR(opline->op1.literal->cache_slot, ce);
|
||||
}
|
||||
@@ -20346,15 +20387,17 @@ static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLE
|
||||
ce = CACHED_PTR(opline->op2.literal->cache_slot);
|
||||
} else {
|
||||
ce = zend_fetch_class_by_name(Z_STRVAL_P(opline->op2.zv), Z_STRLEN_P(opline->op2.zv), opline->op2.literal + 1, 0 TSRMLS_CC);
|
||||
if (UNEXPECTED(ce == NULL)) {
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
if (IS_VAR != IS_CONST && varname == &tmp) {
|
||||
zval_dtor(&tmp);
|
||||
} else if (IS_VAR == IS_VAR || IS_VAR == IS_CV) {
|
||||
zval_ptr_dtor(&varname);
|
||||
}
|
||||
if (free_op1.var) {zval_ptr_dtor(&free_op1.var);};
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
HANDLE_EXCEPTION();
|
||||
}
|
||||
if (UNEXPECTED(ce == NULL)) {
|
||||
zend_error_noreturn(E_ERROR, "Class '%s' not found", Z_STRVAL_P(opline->op2.zv));
|
||||
}
|
||||
CACHE_PTR(opline->op2.literal->cache_slot, ce);
|
||||
}
|
||||
@@ -21516,9 +21559,11 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_UNUSED_HANDLER(Z
|
||||
ce = CACHED_PTR(opline->op1.literal->cache_slot);
|
||||
} else {
|
||||
ce = zend_fetch_class_by_name(Z_STRVAL_P(opline->op1.zv), Z_STRLEN_P(opline->op1.zv), opline->op1.literal + 1, opline->extended_value TSRMLS_CC);
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
HANDLE_EXCEPTION();
|
||||
}
|
||||
if (UNEXPECTED(ce == NULL)) {
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
zend_error_noreturn(E_ERROR, "Class '%s' not found", Z_STRVAL_P(opline->op1.zv));
|
||||
}
|
||||
CACHE_PTR(opline->op1.literal->cache_slot, ce);
|
||||
}
|
||||
@@ -21765,15 +21810,17 @@ static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HAN
|
||||
ce = CACHED_PTR(opline->op2.literal->cache_slot);
|
||||
} else {
|
||||
ce = zend_fetch_class_by_name(Z_STRVAL_P(opline->op2.zv), Z_STRLEN_P(opline->op2.zv), opline->op2.literal + 1, 0 TSRMLS_CC);
|
||||
if (UNEXPECTED(ce == NULL)) {
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
if (IS_VAR != IS_CONST && varname == &tmp) {
|
||||
zval_dtor(&tmp);
|
||||
} else if (IS_VAR == IS_VAR || IS_VAR == IS_CV) {
|
||||
zval_ptr_dtor(&varname);
|
||||
}
|
||||
if (free_op1.var) {zval_ptr_dtor(&free_op1.var);};
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
HANDLE_EXCEPTION();
|
||||
}
|
||||
if (UNEXPECTED(ce == NULL)) {
|
||||
zend_error_noreturn(E_ERROR, "Class '%s' not found", Z_STRVAL_P(opline->op2.zv));
|
||||
}
|
||||
CACHE_PTR(opline->op2.literal->cache_slot, ce);
|
||||
}
|
||||
@@ -23532,9 +23579,11 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_CV_HANDLER(ZEND_
|
||||
ce = CACHED_PTR(opline->op1.literal->cache_slot);
|
||||
} else {
|
||||
ce = zend_fetch_class_by_name(Z_STRVAL_P(opline->op1.zv), Z_STRLEN_P(opline->op1.zv), opline->op1.literal + 1, opline->extended_value TSRMLS_CC);
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
HANDLE_EXCEPTION();
|
||||
}
|
||||
if (UNEXPECTED(ce == NULL)) {
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
zend_error_noreturn(E_ERROR, "Class '%s' not found", Z_STRVAL_P(opline->op1.zv));
|
||||
}
|
||||
CACHE_PTR(opline->op1.literal->cache_slot, ce);
|
||||
}
|
||||
@@ -25206,9 +25255,11 @@ static int ZEND_FASTCALL ZEND_FETCH_CONSTANT_SPEC_UNUSED_CONST_HANDLER(ZEND_OPC
|
||||
ce = CACHED_PTR(opline->op1.literal->cache_slot);
|
||||
} else {
|
||||
ce = zend_fetch_class_by_name(Z_STRVAL_P(opline->op1.zv), Z_STRLEN_P(opline->op1.zv), opline->op1.literal + 1, opline->extended_value TSRMLS_CC);
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
HANDLE_EXCEPTION();
|
||||
}
|
||||
if (UNEXPECTED(ce == NULL)) {
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
zend_error_noreturn(E_ERROR, "Class '%s' not found", Z_STRVAL_P(opline->op1.zv));
|
||||
}
|
||||
CACHE_PTR(opline->op1.literal->cache_slot, ce);
|
||||
}
|
||||
@@ -30563,9 +30614,12 @@ static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER
|
||||
} else if (EX_T(opline->op1.var).var.ptr_ptr == &EX_T(opline->op1.var).var.ptr) {
|
||||
zend_error(E_NOTICE, "Only variable references should be returned by reference");
|
||||
if (EG(return_value_ptr_ptr)) {
|
||||
retval_ptr = *retval_ptr_ptr;
|
||||
*EG(return_value_ptr_ptr) = retval_ptr;
|
||||
Z_ADDREF_P(retval_ptr);
|
||||
zval *ret;
|
||||
|
||||
ALLOC_ZVAL(ret);
|
||||
INIT_PZVAL_COPY(ret, *retval_ptr_ptr);
|
||||
zval_copy_ctor(ret);
|
||||
*EG(return_value_ptr_ptr) = ret;
|
||||
}
|
||||
break;
|
||||
}
|
||||
@@ -31133,7 +31187,7 @@ static int ZEND_FASTCALL ZEND_FE_RESET_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS
|
||||
zend_uchar key_type;
|
||||
|
||||
key_type = zend_hash_get_current_key_ex(fe_ht, &str_key, &str_key_len, &int_key, 0, NULL);
|
||||
if (key_type != HASH_KEY_NON_EXISTANT &&
|
||||
if (key_type != HASH_KEY_NON_EXISTENT &&
|
||||
(key_type == HASH_KEY_IS_LONG ||
|
||||
zend_check_property_access(zobj, str_key, str_key_len-1 TSRMLS_CC) == SUCCESS)) {
|
||||
break;
|
||||
@@ -33023,15 +33077,17 @@ static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDL
|
||||
ce = CACHED_PTR(opline->op2.literal->cache_slot);
|
||||
} else {
|
||||
ce = zend_fetch_class_by_name(Z_STRVAL_P(opline->op2.zv), Z_STRLEN_P(opline->op2.zv), opline->op2.literal + 1, 0 TSRMLS_CC);
|
||||
if (UNEXPECTED(ce == NULL)) {
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
if (IS_CV != IS_CONST && varname == &tmp) {
|
||||
zval_dtor(&tmp);
|
||||
} else if (IS_CV == IS_VAR || IS_CV == IS_CV) {
|
||||
zval_ptr_dtor(&varname);
|
||||
}
|
||||
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
HANDLE_EXCEPTION();
|
||||
}
|
||||
if (UNEXPECTED(ce == NULL)) {
|
||||
zend_error_noreturn(E_ERROR, "Class '%s' not found", Z_STRVAL_P(opline->op2.zv));
|
||||
}
|
||||
CACHE_PTR(opline->op2.literal->cache_slot, ce);
|
||||
}
|
||||
@@ -37324,15 +37380,17 @@ static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER
|
||||
ce = CACHED_PTR(opline->op2.literal->cache_slot);
|
||||
} else {
|
||||
ce = zend_fetch_class_by_name(Z_STRVAL_P(opline->op2.zv), Z_STRLEN_P(opline->op2.zv), opline->op2.literal + 1, 0 TSRMLS_CC);
|
||||
if (UNEXPECTED(ce == NULL)) {
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
if (IS_CV != IS_CONST && varname == &tmp) {
|
||||
zval_dtor(&tmp);
|
||||
} else if (IS_CV == IS_VAR || IS_CV == IS_CV) {
|
||||
zval_ptr_dtor(&varname);
|
||||
}
|
||||
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
HANDLE_EXCEPTION();
|
||||
}
|
||||
if (UNEXPECTED(ce == NULL)) {
|
||||
zend_error_noreturn(E_ERROR, "Class '%s' not found", Z_STRVAL_P(opline->op2.zv));
|
||||
}
|
||||
CACHE_PTR(opline->op2.literal->cache_slot, ce);
|
||||
}
|
||||
@@ -38614,15 +38672,17 @@ static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HAND
|
||||
ce = CACHED_PTR(opline->op2.literal->cache_slot);
|
||||
} else {
|
||||
ce = zend_fetch_class_by_name(Z_STRVAL_P(opline->op2.zv), Z_STRLEN_P(opline->op2.zv), opline->op2.literal + 1, 0 TSRMLS_CC);
|
||||
if (UNEXPECTED(ce == NULL)) {
|
||||
if (UNEXPECTED(EG(exception) != NULL)) {
|
||||
if (IS_CV != IS_CONST && varname == &tmp) {
|
||||
zval_dtor(&tmp);
|
||||
} else if (IS_CV == IS_VAR || IS_CV == IS_CV) {
|
||||
zval_ptr_dtor(&varname);
|
||||
}
|
||||
|
||||
CHECK_EXCEPTION();
|
||||
ZEND_VM_NEXT_OPCODE();
|
||||
HANDLE_EXCEPTION();
|
||||
}
|
||||
if (UNEXPECTED(ce == NULL)) {
|
||||
zend_error_noreturn(E_ERROR, "Class '%s' not found", Z_STRVAL_P(opline->op2.zv));
|
||||
}
|
||||
CACHE_PTR(opline->op2.literal->cache_slot, ce);
|
||||
}
|
||||
|
||||
@@ -1381,7 +1381,7 @@ for ($i = 1; $i < $argc; $i++) {
|
||||
// Disabling code for old-style executor
|
||||
define("ZEND_VM_OLD_EXECUTOR", 1);
|
||||
} else if ($argv[$i] == "--with-lines") {
|
||||
// Enabling debuging using original zend_vm_def.h
|
||||
// Enabling debugging using original zend_vm_def.h
|
||||
define("ZEND_VM_LINES", 1);
|
||||
} else if ($argv[$i] == "--help") {
|
||||
usage();
|
||||
|
||||
+8
-4
@@ -66,10 +66,10 @@ AC_DEFUN([PHP_EXPAND_PATH],[
|
||||
$2=$1
|
||||
else
|
||||
changequote({,})
|
||||
ep_dir="`echo $1|$SED 's%/*[^/][^/]*/*$%%'`"
|
||||
ep_dir=`echo $1|$SED 's%/*[^/][^/]*/*$%%'`
|
||||
changequote([,])
|
||||
ep_realdir="`(cd \"$ep_dir\" && pwd)`"
|
||||
$2="$ep_realdir/`basename \"$1\"`"
|
||||
ep_realdir=`(cd "$ep_dir" && pwd)`
|
||||
$2="$ep_realdir"/`basename "$1"`
|
||||
fi
|
||||
])
|
||||
|
||||
@@ -2962,10 +2962,14 @@ dnl DTrace objects
|
||||
esac
|
||||
|
||||
dnl Generate Makefile.objects entries
|
||||
dnl The empty $ac_provsrc command stops an implicit circular dependency
|
||||
dnl in GNU Make which causes the .d file to be overwritten (Bug 61268)
|
||||
cat>>Makefile.objects<<EOF
|
||||
|
||||
$abs_srcdir/$ac_provsrc:;
|
||||
|
||||
$ac_bdir[$]ac_hdrobj: $abs_srcdir/$ac_provsrc
|
||||
CFLAGS="\$(CFLAGS_CLEAN)" dtrace -h -C -s $ac_srcdir[$]ac_provsrc -o \$[]@ && \$(SED) -ibak 's,PHP_,DTRACE_,g' \$[]@
|
||||
CFLAGS="\$(CFLAGS_CLEAN)" dtrace -h -C -s $ac_srcdir[$]ac_provsrc -o \$[]@.bak && \$(SED) 's,PHP_,DTRACE_,g' \$[]@.bak > \$[]@
|
||||
|
||||
\$(PHP_DTRACE_OBJS): $ac_bdir[$]ac_hdrobj
|
||||
|
||||
|
||||
Vendored
+9
-8
@@ -193,11 +193,11 @@ AC_PROVIDE_IFELSE([AC_LIBTOOL_WIN32_DLL],
|
||||
enable_win32_dll=yes, enable_win32_dll=no)
|
||||
|
||||
AC_ARG_ENABLE([libtool-lock],
|
||||
[ --disable-libtool-lock avoid locking (might break parallel builds)])
|
||||
[ --disable-libtool-lock Avoid locking (might break parallel builds)])
|
||||
test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
|
||||
|
||||
AC_ARG_WITH([pic],
|
||||
[ --with-pic try to use only PIC/non-PIC objects [default=use both]],
|
||||
[ --with-pic Try to use only PIC/non-PIC objects [default=use both]],
|
||||
[pic_mode="$withval"],
|
||||
[pic_mode=default])
|
||||
test -z "$pic_mode" && pic_mode=default
|
||||
@@ -1230,7 +1230,7 @@ if test -n "$_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)" || \
|
||||
test -n "$_LT_AC_TAGVAR(runpath_var, $1)" || \
|
||||
test "X$_LT_AC_TAGVAR(hardcode_automatic, $1)" = "Xyes" ; then
|
||||
|
||||
# We can hardcode non-existant directories.
|
||||
# We can hardcode non-existent directories.
|
||||
if test "$_LT_AC_TAGVAR(hardcode_direct, $1)" != no &&
|
||||
# If the only mechanism to avoid hardcoding is shlibpath_var, we
|
||||
# have to relink, otherwise we might link with an installed library
|
||||
@@ -1919,7 +1919,7 @@ fi
|
||||
AC_DEFUN([_LT_AC_TAGCONFIG],
|
||||
[AC_REQUIRE([LT_AC_PROG_SED])dnl
|
||||
AC_ARG_WITH([tags],
|
||||
[ --with-tags[=TAGS] include additional configurations [automatic]
|
||||
[ --with-tags[=TAGS] Include additional configurations [automatic]
|
||||
],
|
||||
[tagnames="$withval"])
|
||||
|
||||
@@ -2023,7 +2023,7 @@ AC_DEFUN([AC_ENABLE_SHARED],
|
||||
[define([AC_ENABLE_SHARED_DEFAULT], ifelse($1, no, no, yes))dnl
|
||||
AC_ARG_ENABLE([shared],
|
||||
changequote(<<, >>)dnl
|
||||
<< --enable-shared[=PKGS] build shared libraries [default=>>AC_ENABLE_SHARED_DEFAULT],
|
||||
<< --enable-shared[=PKGS] Build shared libraries [default=>>AC_ENABLE_SHARED_DEFAULT],
|
||||
changequote([, ])dnl
|
||||
[p=${PACKAGE-default}
|
||||
case $enableval in
|
||||
@@ -2063,7 +2063,7 @@ AC_DEFUN([AC_ENABLE_STATIC],
|
||||
[define([AC_ENABLE_STATIC_DEFAULT], ifelse($1, no, no, yes))dnl
|
||||
AC_ARG_ENABLE([static],
|
||||
changequote(<<, >>)dnl
|
||||
<< --enable-static[=PKGS] build static libraries [default=>>AC_ENABLE_STATIC_DEFAULT],
|
||||
<< --enable-static[=PKGS] Build static libraries [default=>>AC_ENABLE_STATIC_DEFAULT],
|
||||
changequote([, ])dnl
|
||||
[p=${PACKAGE-default}
|
||||
case $enableval in
|
||||
@@ -2103,7 +2103,8 @@ AC_DEFUN([AC_ENABLE_FAST_INSTALL],
|
||||
[define([AC_ENABLE_FAST_INSTALL_DEFAULT], ifelse($1, no, no, yes))dnl
|
||||
AC_ARG_ENABLE([fast-install],
|
||||
changequote(<<, >>)dnl
|
||||
<< --enable-fast-install[=PKGS] optimize for fast installation [default=>>AC_ENABLE_FAST_INSTALL_DEFAULT],
|
||||
<< --enable-fast-install[=PKGS]
|
||||
Optimize for fast installation [default=>>AC_ENABLE_FAST_INSTALL_DEFAULT],
|
||||
changequote([, ])dnl
|
||||
[p=${PACKAGE-default}
|
||||
case $enableval in
|
||||
@@ -2241,7 +2242,7 @@ fi
|
||||
# find the pathname to the GNU or non-GNU linker
|
||||
AC_DEFUN([AC_PROG_LD],
|
||||
[AC_ARG_WITH([gnu-ld],
|
||||
[ --with-gnu-ld assume the C compiler uses GNU ld [default=no]],
|
||||
[ --with-gnu-ld Assume the C compiler uses GNU ld [default=no]],
|
||||
[test "$withval" = no || with_gnu_ld=yes],
|
||||
[with_gnu_ld=no])
|
||||
AC_REQUIRE([LT_AC_PROG_SED])dnl
|
||||
|
||||
Vendored
+1
-1
@@ -1080,7 +1080,7 @@ EOF
|
||||
# uname -m prints for DJGPP always 'pc', but it prints nothing about
|
||||
# the processor, so we play safe by assuming i586.
|
||||
# Note: whatever this is, it MUST be the same as what config.sub
|
||||
# prints for the "djgpp" host, or else GDB configury will decide that
|
||||
# prints for the "djgpp" host, or else GDB configure will decide that
|
||||
# this is a cross-build.
|
||||
echo i586-pc-msdosdjgpp
|
||||
exit ;;
|
||||
|
||||
+4
-4
@@ -119,8 +119,8 @@ int zend_sprintf(char *buffer, const char *format, ...);
|
||||
|
||||
PHP_MAJOR_VERSION=5
|
||||
PHP_MINOR_VERSION=5
|
||||
PHP_RELEASE_VERSION=0
|
||||
PHP_EXTRA_VERSION="-dev"
|
||||
PHP_RELEASE_VERSION=2
|
||||
PHP_EXTRA_VERSION=""
|
||||
PHP_VERSION="$PHP_MAJOR_VERSION.$PHP_MINOR_VERSION.$PHP_RELEASE_VERSION$PHP_EXTRA_VERSION"
|
||||
PHP_VERSION_ID=`expr [$]PHP_MAJOR_VERSION \* 10000 + [$]PHP_MINOR_VERSION \* 100 + [$]PHP_RELEASE_VERSION`
|
||||
|
||||
@@ -1006,7 +1006,7 @@ dnl Check if all enabled by default extensions should be disabled
|
||||
dnl
|
||||
|
||||
AC_ARG_ENABLE(all,
|
||||
[ --disable-all Disable all extensions which are enabled by default
|
||||
[ --disable-all Disable all extensions which are enabled by default
|
||||
], [
|
||||
PHP_ENABLE_ALL=$enableval
|
||||
])
|
||||
@@ -1582,7 +1582,7 @@ cat <<X
|
||||
| see the file debug.log for error messages. |
|
||||
| |
|
||||
| If you are unable to fix this, send the file debug.log to the |
|
||||
| php-install@lists.php.net mailing list and include appropiate |
|
||||
| php-install@lists.php.net mailing list and include appropriate |
|
||||
| information about your setup. |
|
||||
X
|
||||
fi
|
||||
|
||||
+1
-1
@@ -3,7 +3,7 @@ dnl $Id$
|
||||
dnl
|
||||
|
||||
PHP_ARG_WITH(bz2, for BZip2 support,
|
||||
[ --with-bz2[=DIR] Include BZip2 support])
|
||||
[ --with-bz2[=DIR] Include BZip2 support])
|
||||
|
||||
if test "$PHP_BZ2" != "no"; then
|
||||
if test -r $PHP_BZ2/include/bzlib.h; then
|
||||
|
||||
@@ -53,7 +53,7 @@ static void safe_array_from_zval(VARIANT *v, zval *z, int codepage TSRMLS_DC)
|
||||
|
||||
if (HASH_KEY_IS_STRING == keytype) {
|
||||
goto bogus;
|
||||
} else if (HASH_KEY_NON_EXISTANT == keytype) {
|
||||
} else if (HASH_KEY_NON_EXISTENT == keytype) {
|
||||
break;
|
||||
}
|
||||
if (intindex > max_index) {
|
||||
@@ -102,8 +102,9 @@ PHP_COM_DOTNET_API void php_com_variant_from_zval(VARIANT *v, zval *z, int codep
|
||||
{
|
||||
OLECHAR *olestring;
|
||||
php_com_dotnet_object *obj;
|
||||
zend_uchar ztype = (z == NULL ? IS_NULL : Z_TYPE_P(z));
|
||||
|
||||
switch (Z_TYPE_P(z)) {
|
||||
switch (ztype) {
|
||||
case IS_NULL:
|
||||
V_VT(v) = VT_NULL;
|
||||
break;
|
||||
|
||||
@@ -467,7 +467,7 @@ static void generate_dispids(php_dispatchex *disp TSRMLS_DC)
|
||||
/* properties */
|
||||
if (Z_OBJPROP_P(disp->object)) {
|
||||
zend_hash_internal_pointer_reset_ex(Z_OBJPROP_P(disp->object), &pos);
|
||||
while (HASH_KEY_NON_EXISTANT != (keytype =
|
||||
while (HASH_KEY_NON_EXISTENT != (keytype =
|
||||
zend_hash_get_current_key_ex(Z_OBJPROP_P(disp->object), &name,
|
||||
&namelen, &pid, 0, &pos))) {
|
||||
char namebuf[32];
|
||||
@@ -498,7 +498,7 @@ static void generate_dispids(php_dispatchex *disp TSRMLS_DC)
|
||||
/* functions */
|
||||
if (Z_OBJCE_P(disp->object)) {
|
||||
zend_hash_internal_pointer_reset_ex(&Z_OBJCE_P(disp->object)->function_table, &pos);
|
||||
while (HASH_KEY_NON_EXISTANT != (keytype =
|
||||
while (HASH_KEY_NON_EXISTENT != (keytype =
|
||||
zend_hash_get_current_key_ex(&Z_OBJCE_P(disp->object)->function_table,
|
||||
&name, &namelen, &pid, 0, &pos))) {
|
||||
|
||||
@@ -598,7 +598,7 @@ PHP_COM_DOTNET_API IDispatch *php_com_wrapper_export_as_sink(zval *val, GUID *si
|
||||
zend_hash_init(disp->name_to_dispid, 0, NULL, ZVAL_PTR_DTOR, 0);
|
||||
|
||||
zend_hash_internal_pointer_reset_ex(id_to_name, &pos);
|
||||
while (HASH_KEY_NON_EXISTANT != (keytype =
|
||||
while (HASH_KEY_NON_EXISTENT != (keytype =
|
||||
zend_hash_get_current_key_ex(id_to_name, &name, &namelen, &pid, 0, &pos))) {
|
||||
|
||||
if (keytype == HASH_KEY_IS_LONG) {
|
||||
|
||||
+1
-1
@@ -3,7 +3,7 @@ dnl $Id$
|
||||
dnl
|
||||
|
||||
PHP_ARG_WITH(curl, for cURL support,
|
||||
[ --with-curl[=DIR] Include cURL support])
|
||||
[ --with-curl[=DIR] Include cURL support])
|
||||
|
||||
if test "$PHP_CURL" != "no"; then
|
||||
if test -r $PHP_CURL/include/curl/easy.h; then
|
||||
|
||||
@@ -958,7 +958,7 @@ PHP_MINIT_FUNCTION(curl)
|
||||
REGISTER_CURL_CONSTANT(CURLFTPMETHOD_SINGLECWD);
|
||||
#endif
|
||||
|
||||
#if LIBCURL_VERSION_NUM >- 0x070f04 /* Available since 7.15.4 */
|
||||
#if LIBCURL_VERSION_NUM >= 0x070f04 /* Available since 7.15.4 */
|
||||
REGISTER_CURL_CONSTANT(CURLINFO_FTP_ENTRY_PATH);
|
||||
#endif
|
||||
|
||||
|
||||
+44
-44
@@ -766,8 +766,8 @@ const unsigned char timelib_timezone_db_data_builtin[261525] = {
|
||||
0x1A, 0xB7, 0xA6, 0x00, 0x1E, 0x18, 0x6F, 0xF0, 0x48, 0x41, 0xE6, 0x80, 0x48, 0xBB, 0x22, 0x70,
|
||||
0x4A, 0x23, 0x1A, 0x00, 0x4A, 0x8D, 0xD5, 0x70, 0x4B, 0xDC, 0xC0, 0x80, 0x4C, 0x5D, 0xE5, 0x70,
|
||||
0x4D, 0x97, 0xB8, 0x80, 0x4E, 0x34, 0x8C, 0xF0, 0x4F, 0x9C, 0xA0, 0xA0, 0x50, 0x08, 0xBB, 0xA0,
|
||||
0x50, 0x31, 0x9A, 0x20, 0x50, 0x67, 0xA7, 0xA0, 0x51, 0x7C, 0x82, 0xA0, 0x51, 0xDB, 0x6E, 0xA0,
|
||||
0x52, 0x02, 0xFB, 0xA0, 0x52, 0x47, 0x89, 0xA0, 0x53, 0x5C, 0x64, 0xA0, 0x53, 0xAF, 0x73, 0x20,
|
||||
0x50, 0x31, 0x9A, 0x20, 0x50, 0x67, 0xA7, 0xA0, 0x51, 0x7C, 0x82, 0xA0, 0x51, 0xD8, 0xCB, 0xA0,
|
||||
0x52, 0x05, 0x9E, 0xA0, 0x52, 0x47, 0x89, 0xA0, 0x53, 0x5C, 0x64, 0xA0, 0x53, 0xAF, 0x73, 0x20,
|
||||
0x53, 0xD7, 0x00, 0x20, 0x54, 0x27, 0x6B, 0xA0, 0x55, 0x3C, 0x46, 0xA0, 0x55, 0x82, 0x26, 0x20,
|
||||
0x55, 0xA9, 0xB3, 0x20, 0x56, 0x07, 0x4D, 0xA0, 0x57, 0x1C, 0x28, 0xA0, 0x57, 0x56, 0x2A, 0xA0,
|
||||
0x57, 0x7D, 0xB7, 0xA0, 0x57, 0xE7, 0x2F, 0xA0, 0x59, 0x05, 0x45, 0x20, 0x59, 0x28, 0xDD, 0xA0,
|
||||
@@ -7248,7 +7248,7 @@ const unsigned char timelib_timezone_db_data_builtin[261525] = {
|
||||
0x8C, 0xA0, 0x00, 0x00, 0x00, 0x00, 0x9A, 0xB0, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04,
|
||||
0x00, 0x00, 0x9A, 0xB0, 0x01, 0x00, 0x00, 0x00, 0x8C, 0xA0, 0x00, 0x00, 0x00, 0x00, 0x9A, 0xB0,
|
||||
0x00, 0x08, 0x45, 0x53, 0x54, 0x00, 0x7A, 0x7A, 0x7A, 0x00, 0x4D, 0x49, 0x53, 0x54, 0x00, 0x00,
|
||||
0x00, 0x00, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x36, 0x2B, 0x30, 0x02,
|
||||
0x00, 0x01, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x36, 0x2B, 0x30, 0x02,
|
||||
0x05, 0x32, 0x58, 0x00, 0x00, 0x00, 0x10, 0x4D, 0x61, 0x63, 0x71, 0x75, 0x61, 0x72, 0x69, 0x65,
|
||||
0x20, 0x49, 0x73, 0x6C, 0x61, 0x6E, 0x64,
|
||||
|
||||
@@ -8441,19 +8441,19 @@ const unsigned char timelib_timezone_db_data_builtin[261525] = {
|
||||
0x46, 0xEC, 0x63, 0xF0, 0x47, 0xEC, 0x35, 0x00, 0x48, 0xE7, 0xF5, 0x70, 0x49, 0xCC, 0x17, 0x00,
|
||||
0x4A, 0xBE, 0x9C, 0xF0, 0x4B, 0xAB, 0xF9, 0x00, 0x4C, 0x8C, 0x09, 0xF0, 0x4D, 0x95, 0x15, 0x80,
|
||||
0x4E, 0x87, 0x9B, 0x70, 0x4F, 0x74, 0xF7, 0x80, 0x50, 0x5E, 0x42, 0xF0, 0x51, 0x54, 0xD9, 0x80,
|
||||
0x52, 0x50, 0x99, 0xF0, 0x53, 0x34, 0xBB, 0x80, 0x54, 0x30, 0x7B, 0xF0, 0x55, 0x14, 0x9D, 0x80,
|
||||
0x56, 0x10, 0x5D, 0xF0, 0x56, 0xF4, 0x7F, 0x80, 0x57, 0xF0, 0x3F, 0xF0, 0x58, 0xD4, 0x61, 0x80,
|
||||
0x59, 0xD9, 0x5C, 0x70, 0x5A, 0xB4, 0x43, 0x80, 0x5B, 0xB9, 0x3E, 0x70, 0x5C, 0x9D, 0x60, 0x00,
|
||||
0x5D, 0x99, 0x20, 0x70, 0x5E, 0x7D, 0x42, 0x00, 0x5F, 0x79, 0x02, 0x70, 0x60, 0x5D, 0x24, 0x00,
|
||||
0x61, 0x58, 0xE4, 0x70, 0x62, 0x3D, 0x06, 0x00, 0x63, 0x38, 0xC6, 0x70, 0x64, 0x1C, 0xE8, 0x00,
|
||||
0x65, 0x21, 0xE2, 0xF0, 0x66, 0x06, 0x04, 0x80, 0x67, 0x01, 0xC4, 0xF0, 0x67, 0xE5, 0xE6, 0x80,
|
||||
0x68, 0xE1, 0xA6, 0xF0, 0x69, 0xC5, 0xC8, 0x80, 0x6A, 0xC1, 0x88, 0xF0, 0x6B, 0xA5, 0xAA, 0x80,
|
||||
0x6C, 0xA2, 0xBC, 0x70, 0x6D, 0x85, 0x8C, 0x80, 0x6E, 0x8A, 0x87, 0x70, 0x6F, 0x65, 0x6E, 0x80,
|
||||
0x70, 0x6A, 0x69, 0x70, 0x71, 0x4E, 0x8B, 0x00, 0x72, 0x4A, 0x4B, 0x70, 0x73, 0x2E, 0x6D, 0x00,
|
||||
0x74, 0x2A, 0x2D, 0x70, 0x75, 0x0E, 0x4F, 0x00, 0x76, 0x0A, 0x0F, 0x70, 0x76, 0xEE, 0x31, 0x00,
|
||||
0x77, 0xE9, 0xF1, 0x70, 0x78, 0xCE, 0x13, 0x00, 0x79, 0xD3, 0x0D, 0xF0, 0x7A, 0xAD, 0xF5, 0x00,
|
||||
0x7B, 0xB2, 0xEF, 0xF0, 0x7C, 0x97, 0x11, 0x80, 0x7D, 0x92, 0xD1, 0xF0, 0x7E, 0x76, 0xF3, 0x80,
|
||||
0x7F, 0x72, 0xB3, 0xF0, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x03,
|
||||
0x52, 0x6C, 0x49, 0x70, 0x53, 0x34, 0xBB, 0x80, 0x54, 0x4C, 0x2B, 0x70, 0x55, 0x14, 0x9D, 0x80,
|
||||
0x56, 0x2C, 0x0D, 0x70, 0x56, 0xF4, 0x7F, 0x80, 0x58, 0x15, 0x29, 0xF0, 0x58, 0xD4, 0x61, 0x80,
|
||||
0x59, 0xF5, 0x0B, 0xF0, 0x5A, 0xB4, 0x43, 0x80, 0x5B, 0xD4, 0xED, 0xF0, 0x5C, 0x9D, 0x60, 0x00,
|
||||
0x5D, 0xB4, 0xCF, 0xF0, 0x5E, 0x7D, 0x42, 0x00, 0x5F, 0x94, 0xB1, 0xF0, 0x60, 0x5D, 0x24, 0x00,
|
||||
0x61, 0x7D, 0xCE, 0x70, 0x62, 0x3D, 0x06, 0x00, 0x63, 0x5D, 0xB0, 0x70, 0x64, 0x1C, 0xE8, 0x00,
|
||||
0x65, 0x3D, 0x92, 0x70, 0x66, 0x06, 0x04, 0x80, 0x67, 0x1D, 0x74, 0x70, 0x67, 0xE5, 0xE6, 0x80,
|
||||
0x68, 0xFD, 0x56, 0x70, 0x69, 0xC5, 0xC8, 0x80, 0x6A, 0xDD, 0x38, 0x70, 0x6B, 0xA5, 0xAA, 0x80,
|
||||
0x6C, 0xC6, 0x54, 0xF0, 0x6D, 0x85, 0x8C, 0x80, 0x6E, 0xA6, 0x36, 0xF0, 0x6F, 0x65, 0x6E, 0x80,
|
||||
0x70, 0x86, 0x18, 0xF0, 0x71, 0x4E, 0x8B, 0x00, 0x72, 0x65, 0xFA, 0xF0, 0x73, 0x2E, 0x6D, 0x00,
|
||||
0x74, 0x45, 0xDC, 0xF0, 0x75, 0x0E, 0x4F, 0x00, 0x76, 0x2E, 0xF9, 0x70, 0x76, 0xEE, 0x31, 0x00,
|
||||
0x78, 0x0E, 0xDB, 0x70, 0x78, 0xCE, 0x13, 0x00, 0x79, 0xEE, 0xBD, 0x70, 0x7A, 0xAD, 0xF5, 0x00,
|
||||
0x7B, 0xCE, 0x9F, 0x70, 0x7C, 0x97, 0x11, 0x80, 0x7D, 0xAE, 0x81, 0x70, 0x7E, 0x76, 0xF3, 0x80,
|
||||
0x7F, 0x8E, 0x63, 0x70, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x03,
|
||||
0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02,
|
||||
0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02,
|
||||
0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02,
|
||||
@@ -8465,7 +8465,7 @@ const unsigned char timelib_timezone_db_data_builtin[261525] = {
|
||||
0x01, 0x02, 0x00, 0x00, 0x20, 0xF8, 0x00, 0x00, 0x00, 0x00, 0x2A, 0x30, 0x01, 0x04, 0x00, 0x00,
|
||||
0x1C, 0x20, 0x00, 0x08, 0x00, 0x00, 0x38, 0x40, 0x01, 0x0C, 0x4A, 0x4D, 0x54, 0x00, 0x49, 0x44,
|
||||
0x54, 0x00, 0x49, 0x53, 0x54, 0x00, 0x49, 0x44, 0x44, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0xB9, 0xCD, 0x1A, 0x01, 0x48, 0x6B, 0x85, 0x00, 0x00, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0xB9, 0xD2, 0x87, 0x01, 0x48, 0x67, 0xD4, 0x00, 0x00, 0x00, 0x00,
|
||||
|
||||
/* Asia/Kabul */
|
||||
0x50, 0x48, 0x50, 0x31, 0x01, 0x41, 0x46, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
@@ -9310,19 +9310,19 @@ const unsigned char timelib_timezone_db_data_builtin[261525] = {
|
||||
0x46, 0xEC, 0x63, 0xF0, 0x47, 0xEC, 0x35, 0x00, 0x48, 0xE7, 0xF5, 0x70, 0x49, 0xCC, 0x17, 0x00,
|
||||
0x4A, 0xBE, 0x9C, 0xF0, 0x4B, 0xAB, 0xF9, 0x00, 0x4C, 0x8C, 0x09, 0xF0, 0x4D, 0x95, 0x15, 0x80,
|
||||
0x4E, 0x87, 0x9B, 0x70, 0x4F, 0x74, 0xF7, 0x80, 0x50, 0x5E, 0x42, 0xF0, 0x51, 0x54, 0xD9, 0x80,
|
||||
0x52, 0x50, 0x99, 0xF0, 0x53, 0x34, 0xBB, 0x80, 0x54, 0x30, 0x7B, 0xF0, 0x55, 0x14, 0x9D, 0x80,
|
||||
0x56, 0x10, 0x5D, 0xF0, 0x56, 0xF4, 0x7F, 0x80, 0x57, 0xF0, 0x3F, 0xF0, 0x58, 0xD4, 0x61, 0x80,
|
||||
0x59, 0xD9, 0x5C, 0x70, 0x5A, 0xB4, 0x43, 0x80, 0x5B, 0xB9, 0x3E, 0x70, 0x5C, 0x9D, 0x60, 0x00,
|
||||
0x5D, 0x99, 0x20, 0x70, 0x5E, 0x7D, 0x42, 0x00, 0x5F, 0x79, 0x02, 0x70, 0x60, 0x5D, 0x24, 0x00,
|
||||
0x61, 0x58, 0xE4, 0x70, 0x62, 0x3D, 0x06, 0x00, 0x63, 0x38, 0xC6, 0x70, 0x64, 0x1C, 0xE8, 0x00,
|
||||
0x65, 0x21, 0xE2, 0xF0, 0x66, 0x06, 0x04, 0x80, 0x67, 0x01, 0xC4, 0xF0, 0x67, 0xE5, 0xE6, 0x80,
|
||||
0x68, 0xE1, 0xA6, 0xF0, 0x69, 0xC5, 0xC8, 0x80, 0x6A, 0xC1, 0x88, 0xF0, 0x6B, 0xA5, 0xAA, 0x80,
|
||||
0x6C, 0xA2, 0xBC, 0x70, 0x6D, 0x85, 0x8C, 0x80, 0x6E, 0x8A, 0x87, 0x70, 0x6F, 0x65, 0x6E, 0x80,
|
||||
0x70, 0x6A, 0x69, 0x70, 0x71, 0x4E, 0x8B, 0x00, 0x72, 0x4A, 0x4B, 0x70, 0x73, 0x2E, 0x6D, 0x00,
|
||||
0x74, 0x2A, 0x2D, 0x70, 0x75, 0x0E, 0x4F, 0x00, 0x76, 0x0A, 0x0F, 0x70, 0x76, 0xEE, 0x31, 0x00,
|
||||
0x77, 0xE9, 0xF1, 0x70, 0x78, 0xCE, 0x13, 0x00, 0x79, 0xD3, 0x0D, 0xF0, 0x7A, 0xAD, 0xF5, 0x00,
|
||||
0x7B, 0xB2, 0xEF, 0xF0, 0x7C, 0x97, 0x11, 0x80, 0x7D, 0x92, 0xD1, 0xF0, 0x7E, 0x76, 0xF3, 0x80,
|
||||
0x7F, 0x72, 0xB3, 0xF0, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x03,
|
||||
0x52, 0x6C, 0x49, 0x70, 0x53, 0x34, 0xBB, 0x80, 0x54, 0x4C, 0x2B, 0x70, 0x55, 0x14, 0x9D, 0x80,
|
||||
0x56, 0x2C, 0x0D, 0x70, 0x56, 0xF4, 0x7F, 0x80, 0x58, 0x15, 0x29, 0xF0, 0x58, 0xD4, 0x61, 0x80,
|
||||
0x59, 0xF5, 0x0B, 0xF0, 0x5A, 0xB4, 0x43, 0x80, 0x5B, 0xD4, 0xED, 0xF0, 0x5C, 0x9D, 0x60, 0x00,
|
||||
0x5D, 0xB4, 0xCF, 0xF0, 0x5E, 0x7D, 0x42, 0x00, 0x5F, 0x94, 0xB1, 0xF0, 0x60, 0x5D, 0x24, 0x00,
|
||||
0x61, 0x7D, 0xCE, 0x70, 0x62, 0x3D, 0x06, 0x00, 0x63, 0x5D, 0xB0, 0x70, 0x64, 0x1C, 0xE8, 0x00,
|
||||
0x65, 0x3D, 0x92, 0x70, 0x66, 0x06, 0x04, 0x80, 0x67, 0x1D, 0x74, 0x70, 0x67, 0xE5, 0xE6, 0x80,
|
||||
0x68, 0xFD, 0x56, 0x70, 0x69, 0xC5, 0xC8, 0x80, 0x6A, 0xDD, 0x38, 0x70, 0x6B, 0xA5, 0xAA, 0x80,
|
||||
0x6C, 0xC6, 0x54, 0xF0, 0x6D, 0x85, 0x8C, 0x80, 0x6E, 0xA6, 0x36, 0xF0, 0x6F, 0x65, 0x6E, 0x80,
|
||||
0x70, 0x86, 0x18, 0xF0, 0x71, 0x4E, 0x8B, 0x00, 0x72, 0x65, 0xFA, 0xF0, 0x73, 0x2E, 0x6D, 0x00,
|
||||
0x74, 0x45, 0xDC, 0xF0, 0x75, 0x0E, 0x4F, 0x00, 0x76, 0x2E, 0xF9, 0x70, 0x76, 0xEE, 0x31, 0x00,
|
||||
0x78, 0x0E, 0xDB, 0x70, 0x78, 0xCE, 0x13, 0x00, 0x79, 0xEE, 0xBD, 0x70, 0x7A, 0xAD, 0xF5, 0x00,
|
||||
0x7B, 0xCE, 0x9F, 0x70, 0x7C, 0x97, 0x11, 0x80, 0x7D, 0xAE, 0x81, 0x70, 0x7E, 0x76, 0xF3, 0x80,
|
||||
0x7F, 0x8E, 0x63, 0x70, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x03,
|
||||
0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02,
|
||||
0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02,
|
||||
0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02,
|
||||
@@ -16249,19 +16249,19 @@ const unsigned char timelib_timezone_db_data_builtin[261525] = {
|
||||
0x46, 0xEC, 0x63, 0xF0, 0x47, 0xEC, 0x35, 0x00, 0x48, 0xE7, 0xF5, 0x70, 0x49, 0xCC, 0x17, 0x00,
|
||||
0x4A, 0xBE, 0x9C, 0xF0, 0x4B, 0xAB, 0xF9, 0x00, 0x4C, 0x8C, 0x09, 0xF0, 0x4D, 0x95, 0x15, 0x80,
|
||||
0x4E, 0x87, 0x9B, 0x70, 0x4F, 0x74, 0xF7, 0x80, 0x50, 0x5E, 0x42, 0xF0, 0x51, 0x54, 0xD9, 0x80,
|
||||
0x52, 0x50, 0x99, 0xF0, 0x53, 0x34, 0xBB, 0x80, 0x54, 0x30, 0x7B, 0xF0, 0x55, 0x14, 0x9D, 0x80,
|
||||
0x56, 0x10, 0x5D, 0xF0, 0x56, 0xF4, 0x7F, 0x80, 0x57, 0xF0, 0x3F, 0xF0, 0x58, 0xD4, 0x61, 0x80,
|
||||
0x59, 0xD9, 0x5C, 0x70, 0x5A, 0xB4, 0x43, 0x80, 0x5B, 0xB9, 0x3E, 0x70, 0x5C, 0x9D, 0x60, 0x00,
|
||||
0x5D, 0x99, 0x20, 0x70, 0x5E, 0x7D, 0x42, 0x00, 0x5F, 0x79, 0x02, 0x70, 0x60, 0x5D, 0x24, 0x00,
|
||||
0x61, 0x58, 0xE4, 0x70, 0x62, 0x3D, 0x06, 0x00, 0x63, 0x38, 0xC6, 0x70, 0x64, 0x1C, 0xE8, 0x00,
|
||||
0x65, 0x21, 0xE2, 0xF0, 0x66, 0x06, 0x04, 0x80, 0x67, 0x01, 0xC4, 0xF0, 0x67, 0xE5, 0xE6, 0x80,
|
||||
0x68, 0xE1, 0xA6, 0xF0, 0x69, 0xC5, 0xC8, 0x80, 0x6A, 0xC1, 0x88, 0xF0, 0x6B, 0xA5, 0xAA, 0x80,
|
||||
0x6C, 0xA2, 0xBC, 0x70, 0x6D, 0x85, 0x8C, 0x80, 0x6E, 0x8A, 0x87, 0x70, 0x6F, 0x65, 0x6E, 0x80,
|
||||
0x70, 0x6A, 0x69, 0x70, 0x71, 0x4E, 0x8B, 0x00, 0x72, 0x4A, 0x4B, 0x70, 0x73, 0x2E, 0x6D, 0x00,
|
||||
0x74, 0x2A, 0x2D, 0x70, 0x75, 0x0E, 0x4F, 0x00, 0x76, 0x0A, 0x0F, 0x70, 0x76, 0xEE, 0x31, 0x00,
|
||||
0x77, 0xE9, 0xF1, 0x70, 0x78, 0xCE, 0x13, 0x00, 0x79, 0xD3, 0x0D, 0xF0, 0x7A, 0xAD, 0xF5, 0x00,
|
||||
0x7B, 0xB2, 0xEF, 0xF0, 0x7C, 0x97, 0x11, 0x80, 0x7D, 0x92, 0xD1, 0xF0, 0x7E, 0x76, 0xF3, 0x80,
|
||||
0x7F, 0x72, 0xB3, 0xF0, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x03,
|
||||
0x52, 0x6C, 0x49, 0x70, 0x53, 0x34, 0xBB, 0x80, 0x54, 0x4C, 0x2B, 0x70, 0x55, 0x14, 0x9D, 0x80,
|
||||
0x56, 0x2C, 0x0D, 0x70, 0x56, 0xF4, 0x7F, 0x80, 0x58, 0x15, 0x29, 0xF0, 0x58, 0xD4, 0x61, 0x80,
|
||||
0x59, 0xF5, 0x0B, 0xF0, 0x5A, 0xB4, 0x43, 0x80, 0x5B, 0xD4, 0xED, 0xF0, 0x5C, 0x9D, 0x60, 0x00,
|
||||
0x5D, 0xB4, 0xCF, 0xF0, 0x5E, 0x7D, 0x42, 0x00, 0x5F, 0x94, 0xB1, 0xF0, 0x60, 0x5D, 0x24, 0x00,
|
||||
0x61, 0x7D, 0xCE, 0x70, 0x62, 0x3D, 0x06, 0x00, 0x63, 0x5D, 0xB0, 0x70, 0x64, 0x1C, 0xE8, 0x00,
|
||||
0x65, 0x3D, 0x92, 0x70, 0x66, 0x06, 0x04, 0x80, 0x67, 0x1D, 0x74, 0x70, 0x67, 0xE5, 0xE6, 0x80,
|
||||
0x68, 0xFD, 0x56, 0x70, 0x69, 0xC5, 0xC8, 0x80, 0x6A, 0xDD, 0x38, 0x70, 0x6B, 0xA5, 0xAA, 0x80,
|
||||
0x6C, 0xC6, 0x54, 0xF0, 0x6D, 0x85, 0x8C, 0x80, 0x6E, 0xA6, 0x36, 0xF0, 0x6F, 0x65, 0x6E, 0x80,
|
||||
0x70, 0x86, 0x18, 0xF0, 0x71, 0x4E, 0x8B, 0x00, 0x72, 0x65, 0xFA, 0xF0, 0x73, 0x2E, 0x6D, 0x00,
|
||||
0x74, 0x45, 0xDC, 0xF0, 0x75, 0x0E, 0x4F, 0x00, 0x76, 0x2E, 0xF9, 0x70, 0x76, 0xEE, 0x31, 0x00,
|
||||
0x78, 0x0E, 0xDB, 0x70, 0x78, 0xCE, 0x13, 0x00, 0x79, 0xEE, 0xBD, 0x70, 0x7A, 0xAD, 0xF5, 0x00,
|
||||
0x7B, 0xCE, 0x9F, 0x70, 0x7C, 0x97, 0x11, 0x80, 0x7D, 0xAE, 0x81, 0x70, 0x7E, 0x76, 0xF3, 0x80,
|
||||
0x7F, 0x8E, 0x63, 0x70, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x03,
|
||||
0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02,
|
||||
0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02,
|
||||
0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02,
|
||||
@@ -18410,4 +18410,4 @@ const unsigned char timelib_timezone_db_data_builtin[261525] = {
|
||||
0x00, 0x00, 0x55, 0x54, 0x43, 0x00, 0x00, 0x00, 0x00, 0x89, 0x54, 0x40, 0x01, 0x12, 0xA8, 0x80,
|
||||
0x00, 0x00, 0x00, 0x00, };
|
||||
|
||||
const timelib_tzdb timezonedb_builtin = { "2013.3", 579, timezonedb_idx_builtin, timelib_timezone_db_data_builtin };
|
||||
const timelib_tzdb timezonedb_builtin = { "2013.4", 579, timezonedb_idx_builtin, timelib_timezone_db_data_builtin };
|
||||
+11
-4
@@ -1041,7 +1041,7 @@ char *php_date_short_day_name(timelib_sll y, timelib_sll m, timelib_sll d)
|
||||
static char *date_format(char *format, int format_len, timelib_time *t, int localtime)
|
||||
{
|
||||
smart_str string = {0};
|
||||
int i, length;
|
||||
int i, length = 0;
|
||||
char buffer[97];
|
||||
timelib_time_offset *offset = NULL;
|
||||
timelib_sll isoweek, isoyear;
|
||||
@@ -1396,7 +1396,7 @@ PHPAPI void php_date_set_tzdb(timelib_tzdb *tzdb)
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
/* {{{ php_parse_date: Backwards compability function */
|
||||
/* {{{ php_parse_date: Backwards compatibility function */
|
||||
PHPAPI signed long php_parse_date(char *string, signed long *now)
|
||||
{
|
||||
timelib_time *parsed_time;
|
||||
@@ -1678,6 +1678,13 @@ PHPAPI void php_strftime(INTERNAL_FUNCTION_PARAMETERS, int gmt)
|
||||
break;
|
||||
}
|
||||
}
|
||||
#if defined(PHP_WIN32) && _MSC_VER >= 1700
|
||||
/* VS2012 strftime() returns number of characters, not bytes.
|
||||
See VC++11 bug id 766205. */
|
||||
if (real_len > 0) {
|
||||
real_len = strlen(buf);
|
||||
}
|
||||
#endif
|
||||
|
||||
timelib_time_dtor(ts);
|
||||
if (!gmt) {
|
||||
@@ -2531,8 +2538,8 @@ PHPAPI int php_date_initialize(php_date_obj *dateobj, /*const*/ char *time_str,
|
||||
timelib_time *now;
|
||||
timelib_tzinfo *tzi = NULL;
|
||||
timelib_error_container *err = NULL;
|
||||
int type = TIMELIB_ZONETYPE_ID, new_dst;
|
||||
char *new_abbr;
|
||||
int type = TIMELIB_ZONETYPE_ID, new_dst = 0;
|
||||
char *new_abbr = NULL;
|
||||
timelib_sll new_offset;
|
||||
|
||||
if (dateobj->time) {
|
||||
|
||||
+1
-1
@@ -182,7 +182,7 @@ ZEND_END_MODULE_GLOBALS(date)
|
||||
#define DATEG(v) (date_globals.v)
|
||||
#endif
|
||||
|
||||
/* Backwards compability wrapper */
|
||||
/* Backwards compatibility wrapper */
|
||||
PHPAPI signed long php_parse_date(char *string, signed long *now);
|
||||
PHPAPI void php_mktime(INTERNAL_FUNCTION_PARAMETERS, int gmt);
|
||||
PHPAPI int php_idate(char format, time_t ts, int localtime TSRMLS_DC);
|
||||
|
||||
@@ -4,8 +4,6 @@ Bug #52062 (large timestamps with DateTime::getTimestamp and DateTime::setTimest
|
||||
<?php
|
||||
if (PHP_INT_SIZE == 8) die('skip 32-bit only');
|
||||
?>
|
||||
--XFAIL--
|
||||
Waiting for resolution of the 32-bit case.
|
||||
--INI--
|
||||
date.timezone=UTC
|
||||
--FILE--
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
--TEST--
|
||||
Bug #55397 (comparsion of incomplete DateTime causes SIGSEGV)
|
||||
Bug #55397 (comparison of incomplete DateTime causes SIGSEGV)
|
||||
--INI--
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
@@ -0,0 +1,26 @@
|
||||
--TEST--
|
||||
Test bug #65184 strftime() returns insufficient-length string under multibyte locales
|
||||
--SKIPIF--
|
||||
<?php
|
||||
if (strtoupper(substr(PHP_OS, 0, 3)) != 'WIN') {
|
||||
die("skip Test is valid for Windows");
|
||||
}
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
setlocale(LC_ALL, 'Japanese_Japan.932');
|
||||
/* timestamp has to be some wednesday */
|
||||
$s = strftime('%A', 1372884126);
|
||||
|
||||
for ($i = 0; $i < strlen($s); $i++) {
|
||||
printf("%x ", ord($s[$i]));
|
||||
}
|
||||
echo "\n";
|
||||
|
||||
echo strlen(strftime('%A')), "\n";
|
||||
?>
|
||||
===DONE===
|
||||
--EXPECT--
|
||||
90 85 97 6a 93 fa
|
||||
6
|
||||
===DONE===
|
||||
+2
-2
@@ -557,10 +557,10 @@ PHP_ARG_WITH(cdb,,
|
||||
[ --without-cdb[=DIR] DBA: CDB support (bundled)], $php_dba_enable, no)
|
||||
|
||||
PHP_ARG_ENABLE(inifile,,
|
||||
[ --disable-inifile DBA: INI support (bundled)], $php_dba_enable, no)
|
||||
[ --disable-inifile DBA: INI support (bundled)], $php_dba_enable, no)
|
||||
|
||||
PHP_ARG_ENABLE(flatfile,,
|
||||
[ --disable-flatfile DBA: FlatFile support (bundled)], $php_dba_enable, no)
|
||||
[ --disable-flatfile DBA: FlatFile support (bundled)], $php_dba_enable, no)
|
||||
|
||||
# CDB
|
||||
if test "$PHP_CDB" = "yes"; then
|
||||
|
||||
+1
-1
@@ -888,7 +888,7 @@ static void php_dba_open(INTERNAL_FUNCTION_PARAMETERS, int persistent)
|
||||
RETURN_FALSE;
|
||||
}
|
||||
if (hptr->flags & (DBA_NO_APPEND|DBA_CAST_AS_FD)) {
|
||||
/* Needed becasue some systems do not allow to write to the original
|
||||
/* Needed because some systems do not allow to write to the original
|
||||
* file contents with O_APPEND being set.
|
||||
*/
|
||||
if (SUCCESS != php_stream_cast(info->fp, PHP_STREAM_AS_FD, (void*)&info->fd, 1)) {
|
||||
|
||||
@@ -8,10 +8,18 @@ Bug #38698 (Bug #38698 for some keys cdbmake creates corrupted db and cdb can't
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
function isLittleEndian() {
|
||||
return 0x00FF === current(unpack('v', pack('S',0x00FF)));
|
||||
}
|
||||
|
||||
$db_file = dirname(__FILE__) .'/129php.cdb';
|
||||
|
||||
if (($db_make=dba_open($db_file, "n", 'cdb_make'))!==FALSE) {
|
||||
dba_insert(pack('i',129), "Booo!", $db_make);
|
||||
if (isLittleEndian() === FALSE) {
|
||||
dba_insert(pack('V',129), "Booo!", $db_make);
|
||||
} else{
|
||||
dba_insert(pack('i',129), "Booo!", $db_make);
|
||||
}
|
||||
dba_close($db_make);
|
||||
// write md5 checksum of generated database file
|
||||
var_dump(md5_file($db_file));
|
||||
|
||||
@@ -12,7 +12,7 @@ DBA GDBM handler test
|
||||
$lock_flag = ''; // lock in library
|
||||
require_once dirname(__FILE__) .'/dba_handler.inc';
|
||||
|
||||
// Read during write is system dependant. Important is that there is no deadlock
|
||||
// Read during write is system dependent. Important is that there is no deadlock
|
||||
?>
|
||||
===DONE===
|
||||
--EXPECTF--
|
||||
|
||||
+12
-4
@@ -1973,14 +1973,15 @@ static void _dom_document_schema_validate(INTERNAL_FUNCTION_PARAMETERS, int type
|
||||
xmlDoc *docp;
|
||||
dom_object *intern;
|
||||
char *source = NULL, *valid_file = NULL;
|
||||
int source_len = 0;
|
||||
int source_len = 0, valid_opts = 0;
|
||||
long flags = 0;
|
||||
xmlSchemaParserCtxtPtr parser;
|
||||
xmlSchemaPtr sptr;
|
||||
xmlSchemaValidCtxtPtr vptr;
|
||||
int is_valid;
|
||||
char resolved_path[MAXPATHLEN + 1];
|
||||
|
||||
if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Op", &id, dom_document_class_entry, &source, &source_len) == FAILURE) {
|
||||
if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Op|l", &id, dom_document_class_entry, &source, &source_len, &flags) == FAILURE) {
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -2029,6 +2030,13 @@ static void _dom_document_schema_validate(INTERNAL_FUNCTION_PARAMETERS, int type
|
||||
RETURN_FALSE;
|
||||
}
|
||||
|
||||
#if LIBXML_VERSION >= 20614
|
||||
if (flags & XML_SCHEMA_VAL_VC_I_CREATE) {
|
||||
valid_opts |= XML_SCHEMA_VAL_VC_I_CREATE;
|
||||
}
|
||||
#endif
|
||||
|
||||
xmlSchemaSetValidOptions(vptr, valid_opts);
|
||||
xmlSchemaSetValidErrors(vptr, php_libxml_error_handler, php_libxml_error_handler, vptr);
|
||||
is_valid = xmlSchemaValidateDoc(vptr, docp);
|
||||
xmlSchemaFree(sptr);
|
||||
@@ -2042,14 +2050,14 @@ static void _dom_document_schema_validate(INTERNAL_FUNCTION_PARAMETERS, int type
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
/* {{{ proto boolean dom_document_schema_validate_file(string filename); */
|
||||
/* {{{ proto boolean dom_document_schema_validate_file(string filename, int flags); */
|
||||
PHP_FUNCTION(dom_document_schema_validate_file)
|
||||
{
|
||||
_dom_document_schema_validate(INTERNAL_FUNCTION_PARAM_PASSTHRU, DOM_LOAD_FILE);
|
||||
}
|
||||
/* }}} end dom_document_schema_validate_file */
|
||||
|
||||
/* {{{ proto boolean dom_document_schema_validate(string source); */
|
||||
/* {{{ proto boolean dom_document_schema_validate(string source, int flags); */
|
||||
PHP_FUNCTION(dom_document_schema_validate_xml)
|
||||
{
|
||||
_dom_document_schema_validate(INTERNAL_FUNCTION_PARAM_PASSTHRU, DOM_LOAD_STRING);
|
||||
|
||||
@@ -0,0 +1,21 @@
|
||||
--TEST--
|
||||
Test DOMDocument::loadXML() basic behavior
|
||||
--DESCRIPTION--
|
||||
This test verifies the basic behaviour of the method
|
||||
Environment variables used in the test:
|
||||
- XML_FILE: the xml file to load
|
||||
- LOAD_OPTIONS: the second parameter to pass to the method
|
||||
- EXPECTED_RESULT: the expected result
|
||||
--CREDITS--
|
||||
Antonio Diaz Ruiz <dejalatele@gmail.com>
|
||||
--INI--
|
||||
assert.bail=true
|
||||
--SKIPIF--
|
||||
<?php include('skipif.inc'); ?>
|
||||
--ENV--
|
||||
XML_FILE=/book.xml
|
||||
LOAD_OPTIONS=0
|
||||
EXPECTED_RESULT=1
|
||||
--FILE_EXTERNAL--
|
||||
domdocumentloadxml_test_method.php
|
||||
--EXPECT--
|
||||
@@ -0,0 +1,26 @@
|
||||
--TEST--
|
||||
Test DOMDocument::loadXML() detects not-well formed XML
|
||||
--DESCRIPTION--
|
||||
This test verifies the method detects an opening and ending tag mismatch
|
||||
Environment variables used in the test:
|
||||
- XML_FILE: the xml file to load
|
||||
- LOAD_OPTIONS: the second parameter to pass to the method
|
||||
- EXPECTED_RESULT: the expected result
|
||||
--CREDITS--
|
||||
Antonio Diaz Ruiz <dejalatele@gmail.com>
|
||||
--INI--
|
||||
assert.bail=true
|
||||
--SKIPIF--
|
||||
<?php include('skipif.inc'); ?>
|
||||
--ENV--
|
||||
XML_FILE=/not_well_formed.xml
|
||||
LOAD_OPTIONS=0
|
||||
EXPECTED_RESULT=0
|
||||
--FILE_EXTERNAL--
|
||||
domdocumentloadxml_test_method.php
|
||||
--EXPECTF--
|
||||
Warning: DOMDocument::load%r(XML){0,1}%r(): Opening and ending tag mismatch: title line 5 and book %s
|
||||
|
||||
Warning: DOMDocument::load%r(XML){0,1}%r(): expected '>' %s
|
||||
|
||||
Warning: DOMDocument::load%r(XML){0,1}%r(): Premature end of data in tag books %s
|
||||
@@ -0,0 +1,30 @@
|
||||
--TEST--
|
||||
Test DOMDocument::loadXML() detects not-well formed XML
|
||||
--DESCRIPTION--
|
||||
This test verifies the method detects attributes values not closed between " or '
|
||||
Environment variables used in the test:
|
||||
- XML_FILE: the xml file to load
|
||||
- LOAD_OPTIONS: the second parameter to pass to the method
|
||||
- EXPECTED_RESULT: the expected result
|
||||
--CREDITS--
|
||||
Antonio Diaz Ruiz <dejalatele@gmail.com>
|
||||
--INI--
|
||||
assert.bail=true
|
||||
--SKIPIF--
|
||||
<?php include('skipif.inc'); ?>
|
||||
--ENV--
|
||||
XML_FILE=/not_well_formed2.xml
|
||||
LOAD_OPTIONS=0
|
||||
EXPECTED_RESULT=0
|
||||
--FILE_EXTERNAL--
|
||||
domdocumentloadxml_test_method.php
|
||||
--EXPECTF--
|
||||
Warning: DOMDocument::load%r(XML){0,1}%r(): AttValue: " or ' expected %s
|
||||
|
||||
Warning: DOMDocument::load%r(XML){0,1}%r(): attributes construct error %s
|
||||
|
||||
Warning: DOMDocument::load%r(XML){0,1}%r(): Couldn't find end of Start Tag book %s
|
||||
|
||||
Warning: DOMDocument::load%r(XML){0,1}%r(): Opening and ending tag mismatch: books %s
|
||||
|
||||
Warning: DOMDocument::load%r(XML){0,1}%r(): Extra content at the end of the document %s
|
||||
@@ -0,0 +1,22 @@
|
||||
--TEST--
|
||||
Test DOMDocument::loadXML() detects not-well formed XML
|
||||
--DESCRIPTION--
|
||||
This test verifies the method detects a typo in tag names
|
||||
Environment variables used in the test:
|
||||
- XML_FILE: the xml file to load
|
||||
- LOAD_OPTIONS: the second parameter to pass to the method
|
||||
- EXPECTED_RESULT: the expected result
|
||||
--CREDITS--
|
||||
Antonio Diaz Ruiz <dejalatele@gmail.com>
|
||||
--INI--
|
||||
assert.bail=true
|
||||
--SKIPIF--
|
||||
<?php include('skipif.inc'); ?>
|
||||
--ENV--
|
||||
XML_FILE=/not_well_formed3.xml
|
||||
LOAD_OPTIONS=0
|
||||
EXPECTED_RESULT=0
|
||||
--FILE_EXTERNAL--
|
||||
domdocumentloadxml_test_method.php
|
||||
--EXPECTF--
|
||||
Warning: DOMDocument::load%r(XML){0,1}%r(): Opening and ending tag mismatch: boOk line 8 and book %s
|
||||
@@ -0,0 +1,22 @@
|
||||
--TEST--
|
||||
Test DOMDocument::loadXML() detects not-well formed XML
|
||||
--DESCRIPTION--
|
||||
This test verifies the method detects an unsupported xml version
|
||||
Environment variables used in the test:
|
||||
- XML_FILE: the xml file to load
|
||||
- LOAD_OPTIONS: the second parameter to pass to the method
|
||||
- EXPECTED_RESULT: the expected result
|
||||
--CREDITS--
|
||||
Antonio Diaz Ruiz <dejalatele@gmail.com>
|
||||
--INI--
|
||||
assert.bail=true
|
||||
--SKIPIF--
|
||||
<?php include('skipif.inc'); ?>
|
||||
--ENV--
|
||||
XML_FILE=/not_well_formed4.xml
|
||||
LOAD_OPTIONS=0
|
||||
EXPECTED_RESULT=0
|
||||
--FILE_EXTERNAL--
|
||||
domdocumentloadxml_test_method.php
|
||||
--EXPECTF--
|
||||
Warning: DOMDocument::load%r(XML){0,1}%r(): Unsupported version '3.1' %s
|
||||
@@ -0,0 +1,22 @@
|
||||
--TEST--
|
||||
Test DOMDocument::loadXML() detects not-well formed XML
|
||||
--DESCRIPTION--
|
||||
This test verifies the method detects extra content at the end of the document
|
||||
Environment variables used in the test:
|
||||
- XML_FILE: the xml file to load
|
||||
- LOAD_OPTIONS: the second parameter to pass to the method
|
||||
- EXPECTED_RESULT: the expected result
|
||||
--CREDITS--
|
||||
Antonio Diaz Ruiz <dejalatele@gmail.com>
|
||||
--INI--
|
||||
assert.bail=true
|
||||
--SKIPIF--
|
||||
<?php include('skipif.inc'); ?>
|
||||
--ENV--
|
||||
XML_FILE=/not_well_formed5.xml
|
||||
LOAD_OPTIONS=0
|
||||
EXPECTED_RESULT=0
|
||||
--FILE_EXTERNAL--
|
||||
domdocumentloadxml_test_method.php
|
||||
--EXPECTF--
|
||||
Warning: DOMDocument::load%r(XML){0,1}%r(): Extra content at the end of the document %s
|
||||
@@ -0,0 +1,21 @@
|
||||
--TEST--
|
||||
Test DOMDocument::loadXML() with LIBXML_DTDLOAD option
|
||||
--DESCRIPTION--
|
||||
This test verifies the right behaviour of the LIBXML_DTDLOAD constant
|
||||
Environment variables used in the test:
|
||||
- XML_FILE: the xml file to load
|
||||
- LOAD_OPTIONS: the second parameter to pass to the method
|
||||
- EXPECTED_RESULT: the expected result
|
||||
--CREDITS--
|
||||
Antonio Diaz Ruiz <dejalatele@gmail.com>
|
||||
--INI--
|
||||
assert.bail=true
|
||||
--SKIPIF--
|
||||
<?php include('skipif.inc'); ?>
|
||||
--ENV--
|
||||
XML_FILE=/book_with_dtd2.xml
|
||||
LOAD_OPTIONS=LIBXML_DTDLOAD
|
||||
EXPECTED_RESULT=1
|
||||
--FILE_EXTERNAL--
|
||||
domdocumentloadxml_test_method.php
|
||||
--EXPECT--
|
||||
@@ -0,0 +1,22 @@
|
||||
--TEST--
|
||||
Test DOMDocument::loadXML() with LIBXML_DTDVALID option
|
||||
--DESCRIPTION--
|
||||
This test verifies the right behaviour of the LIBXML_DTDVALID constant
|
||||
Environment variables used in the test:
|
||||
- XML_FILE: the xml file to load
|
||||
- LOAD_OPTIONS: the second parameter to pass to the method
|
||||
- EXPECTED_RESULT: the expected result
|
||||
--CREDITS--
|
||||
Antonio Diaz Ruiz <dejalatele@gmail.com>
|
||||
--INI--
|
||||
assert.bail=true
|
||||
--SKIPIF--
|
||||
<?php include('skipif.inc'); ?>
|
||||
--ENV--
|
||||
XML_FILE=/wrong_book_with_dtd2.xml
|
||||
LOAD_OPTIONS=LIBXML_DTDVALID
|
||||
EXPECTED_RESULT=1
|
||||
--FILE_EXTERNAL--
|
||||
domdocumentloadxml_test_method.php
|
||||
--EXPECTF--
|
||||
Warning: DOMDocument::load%r(XML){0,1}%r(): Element book content does not follow the DTD, expecting (title , author), got (title author author ) %s
|
||||
@@ -0,0 +1,22 @@
|
||||
--TEST--
|
||||
Test DOMDocument::loadXML() with LIBXML_DTDVALID and LIBXML_NOERROR options
|
||||
--DESCRIPTION--
|
||||
This test vrifies the right behaviour of the LIBXML_NOERROR constant
|
||||
which avoids the display of the warning message
|
||||
Environment variables used in the test:
|
||||
- XML_FILE: the xml file to load
|
||||
- LOAD_OPTIONS: the second parameter to pass to the method
|
||||
- EXPECTED_RESULT: the expected result
|
||||
--CREDITS--
|
||||
Antonio Diaz Ruiz <dejalatele@gmail.com>
|
||||
--INI--
|
||||
assert.bail=true
|
||||
--SKIPIF--
|
||||
<?php include('skipif.inc'); ?>
|
||||
--ENV--
|
||||
XML_FILE=/wrong_book_with_dtd.xml
|
||||
LOAD_OPTIONS=LIBXML_DTDVALID | LIBXML_NOERROR
|
||||
EXPECTED_RESULT=1
|
||||
--FILE_EXTERNAL--
|
||||
domdocumentloadxml_test_method.php
|
||||
--EXPECT--
|
||||
@@ -0,0 +1,32 @@
|
||||
--TEST--
|
||||
Test DOMDocument::loadXML() with LIBXML_DTDATTR, LIBXML_NOCDATA, LIBXML_NOENT, LIBXML_NOBLANKS
|
||||
--DESCRIPTION--
|
||||
This test verifies the right behaviour of the following constants:
|
||||
LIBXML_DTDATTR, LIBXML_NOCDATA, LIBXML_NOENT and LIBXML_NOBLANKS
|
||||
Environment variables used in the test:
|
||||
- XML_FILE: the xml file to load
|
||||
- LOAD_OPTIONS: the second parameter to pass to the method
|
||||
- EXPECTED_RESULT: the expected result
|
||||
--CREDITS--
|
||||
Antonio Diaz Ruiz <dejalatele@gmail.com>
|
||||
--INI--
|
||||
assert.bail=true
|
||||
--SKIPIF--
|
||||
<?php include('skipif.inc'); ?>
|
||||
--ENV--
|
||||
XML_FILE=/book_with_dtd2.xml
|
||||
LOAD_OPTIONS=LIBXML_DTDATTR|LIBXML_NOCDATA|LIBXML_NOENT|LIBXML_NOBLANKS
|
||||
EXPECTED_RESULT=1
|
||||
--FILE_EXTERNAL--
|
||||
domdocumentloadxml_test_method_savexml.php
|
||||
--EXPECT--
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE books [
|
||||
<!ENTITY entitest "entity is only for test purposes">
|
||||
<!ATTLIST title default CDATA "default title">
|
||||
<!ELEMENT books (book)*>
|
||||
<!ELEMENT book (title , author)>
|
||||
<!ELEMENT title (#PCDATA)>
|
||||
<!ELEMENT author (#PCDATA)>
|
||||
]>
|
||||
<books><book><title default="default title">The Grapes of Wrath</title><author>John Steinbeck</author></book><book><title default="default title">The Pearl</title><author>John Steinbeck</author></book><book><title default="default title">entity is only for test purposes</title><author>data for test</author></book></books>
|
||||
@@ -0,0 +1,21 @@
|
||||
--TEST--
|
||||
Test DOMDocument::load() basic behavior
|
||||
--DESCRIPTION--
|
||||
This test verifies the basic behaviour of the method
|
||||
Environment variables used in the test:
|
||||
- XML_FILE: the xml file to load
|
||||
- LOAD_OPTIONS: the second parameter to pass to the method
|
||||
- EXPECTED_RESULT: the expected result
|
||||
--CREDITS--
|
||||
Antonio Diaz Ruiz <dejalatele@gmail.com>
|
||||
--INI--
|
||||
assert.bail=true
|
||||
--SKIPIF--
|
||||
<?php include('skipif.inc'); ?>
|
||||
--ENV--
|
||||
XML_FILE=/book.xml
|
||||
LOAD_OPTIONS=0
|
||||
EXPECTED_RESULT=1
|
||||
--FILE_EXTERNAL--
|
||||
domdocumentload_test_method.php
|
||||
--EXPECT--
|
||||
@@ -0,0 +1,26 @@
|
||||
--TEST--
|
||||
Test DOMDocument::load() detects not-well formed XML
|
||||
--DESCRIPTION--
|
||||
This test verifies the method detects an opening and ending tag mismatch
|
||||
Environment variables used in the test:
|
||||
- XML_FILE: the xml file to load
|
||||
- LOAD_OPTIONS: the second parameter to pass to the method
|
||||
- EXPECTED_RESULT: the expected result
|
||||
--CREDITS--
|
||||
Antonio Diaz Ruiz <dejalatele@gmail.com>
|
||||
--INI--
|
||||
assert.bail=true
|
||||
--SKIPIF--
|
||||
<?php include('skipif.inc'); ?>
|
||||
--ENV--
|
||||
XML_FILE=/not_well_formed.xml
|
||||
LOAD_OPTIONS=0
|
||||
EXPECTED_RESULT=0
|
||||
--FILE_EXTERNAL--
|
||||
domdocumentload_test_method.php
|
||||
--EXPECTF--
|
||||
Warning: DOMDocument::load%r(XML){0,1}%r(): Opening and ending tag mismatch: title line 5 and book %s
|
||||
|
||||
Warning: DOMDocument::load%r(XML){0,1}%r(): expected '>' %s
|
||||
|
||||
Warning: DOMDocument::load%r(XML){0,1}%r(): Premature end of data in tag books %s
|
||||
@@ -0,0 +1,30 @@
|
||||
--TEST--
|
||||
Test DOMDocument::load() detects not-well formed XML
|
||||
--DESCRIPTION--
|
||||
This test verifies the method detects attributes values not closed between " or '
|
||||
Environment variables used in the test:
|
||||
- XML_FILE: the xml file to load
|
||||
- LOAD_OPTIONS: the second parameter to pass to the method
|
||||
- EXPECTED_RESULT: the expected result
|
||||
--CREDITS--
|
||||
Antonio Diaz Ruiz <dejalatele@gmail.com>
|
||||
--INI--
|
||||
assert.bail=true
|
||||
--SKIPIF--
|
||||
<?php include('skipif.inc'); ?>
|
||||
--ENV--
|
||||
XML_FILE=/not_well_formed2.xml
|
||||
LOAD_OPTIONS=0
|
||||
EXPECTED_RESULT=0
|
||||
--FILE_EXTERNAL--
|
||||
domdocumentload_test_method.php
|
||||
--EXPECTF--
|
||||
Warning: DOMDocument::load%r(XML){0,1}%r(): AttValue: " or ' expected %s
|
||||
|
||||
Warning: DOMDocument::load%r(XML){0,1}%r(): attributes construct error %s
|
||||
|
||||
Warning: DOMDocument::load%r(XML){0,1}%r(): Couldn't find end of Start Tag book %s
|
||||
|
||||
Warning: DOMDocument::load%r(XML){0,1}%r(): Opening and ending tag mismatch: books %s
|
||||
|
||||
Warning: DOMDocument::load%r(XML){0,1}%r(): Extra content at the end of the document %s
|
||||
@@ -0,0 +1,22 @@
|
||||
--TEST--
|
||||
Test DOMDocument::load() detects not-well formed XML
|
||||
--DESCRIPTION--
|
||||
This test verifies the method detects and opening and ending tag mismatch
|
||||
Environment variables used in the test:
|
||||
- XML_FILE: the xml file to load
|
||||
- LOAD_OPTIONS: the second parameter to pass to the method
|
||||
- EXPECTED_RESULT: the expected result
|
||||
--CREDITS--
|
||||
Antonio Diaz Ruiz <dejalatele@gmail.com>
|
||||
--INI--
|
||||
assert.bail=true
|
||||
--SKIPIF--
|
||||
<?php include('skipif.inc'); ?>
|
||||
--ENV--
|
||||
XML_FILE=/not_well_formed3.xml
|
||||
LOAD_OPTIONS=0
|
||||
EXPECTED_RESULT=0
|
||||
--FILE_EXTERNAL--
|
||||
domdocumentload_test_method.php
|
||||
--EXPECTF--
|
||||
Warning: DOMDocument::load%r(XML){0,1}%r(): Opening and ending tag mismatch: boOk line 8 and book %s
|
||||
@@ -0,0 +1,22 @@
|
||||
--TEST--
|
||||
Test DOMDocument::load() detects not-well formed XML
|
||||
--DESCRIPTION--
|
||||
This test verifies the method detects an unsupported xml version
|
||||
Environment variables used in the test:
|
||||
- XML_FILE: the xml file to load
|
||||
- LOAD_OPTIONS: the second parameter to pass to the method
|
||||
- EXPECTED_RESULT: the expected result
|
||||
--CREDITS--
|
||||
Antonio Diaz Ruiz <dejalatele@gmail.com>
|
||||
--INI--
|
||||
assert.bail=true
|
||||
--SKIPIF--
|
||||
<?php include('skipif.inc'); ?>
|
||||
--ENV--
|
||||
XML_FILE=/not_well_formed4.xml
|
||||
LOAD_OPTIONS=0
|
||||
EXPECTED_RESULT=0
|
||||
--FILE_EXTERNAL--
|
||||
domdocumentload_test_method.php
|
||||
--EXPECTF--
|
||||
Warning: DOMDocument::load%r(XML){0,1}%r(): Unsupported version '3.1' %s
|
||||
@@ -0,0 +1,22 @@
|
||||
--TEST--
|
||||
Test DOMDocument::load() detects not-well formed XML
|
||||
--DESCRIPTION--
|
||||
This test verifies the method detects extra content at the end of the document
|
||||
Environment variables used in the test:
|
||||
- XML_FILE: the xml file to load
|
||||
- LOAD_OPTIONS: the second parameter to pass to the method
|
||||
- EXPECTED_RESULT: the expected result
|
||||
--CREDITS--
|
||||
Antonio Diaz Ruiz <dejalatele@gmail.com>
|
||||
--INI--
|
||||
assert.bail=true
|
||||
--SKIPIF--
|
||||
<?php include('skipif.inc'); ?>
|
||||
--ENV--
|
||||
XML_FILE=/not_well_formed5.xml
|
||||
LOAD_OPTIONS=0
|
||||
EXPECTED_RESULT=0
|
||||
--FILE_EXTERNAL--
|
||||
domdocumentload_test_method.php
|
||||
--EXPECTF--
|
||||
Warning: DOMDocument::load%r(XML){0,1}%r(): Extra content at the end of the document %s
|
||||
@@ -0,0 +1,21 @@
|
||||
--TEST--
|
||||
Test DOMDocument::load() with LIBXML_DTDLOAD option
|
||||
--DESCRIPTION--
|
||||
This test verifies the right behaviour of the LIBXML_DTDLOAD constant
|
||||
Environment variables used in the test:
|
||||
- XML_FILE: the xml file to load
|
||||
- LOAD_OPTIONS: the second parameter to pass to the method
|
||||
- EXPECTED_RESULT: the expected result
|
||||
--CREDITS--
|
||||
Antonio Diaz Ruiz <dejalatele@gmail.com>
|
||||
--INI--
|
||||
assert.bail=true
|
||||
--SKIPIF--
|
||||
<?php include('skipif.inc'); ?>
|
||||
--ENV--
|
||||
XML_FILE=/book_with_dtd.xml
|
||||
LOAD_OPTIONS=LIBXML_DTDLOAD
|
||||
EXPECTED_RESULT=1
|
||||
--FILE_EXTERNAL--
|
||||
domdocumentload_test_method.php
|
||||
--EXPECT--
|
||||
@@ -0,0 +1,22 @@
|
||||
--TEST--
|
||||
Test DOMDocument::load() with LIBXML_DTDVALID option
|
||||
--DESCRIPTION--
|
||||
This test verifies the right behaviour of the LIBXML_DTDVALID constant
|
||||
Environment variables used in the test:
|
||||
- XML_FILE: the xml file to load
|
||||
- LOAD_OPTIONS: the second parameter to pass to the method
|
||||
- EXPECTED_RESULT: the expected result
|
||||
--CREDITS--
|
||||
Antonio Diaz Ruiz <dejalatele@gmail.com>
|
||||
--INI--
|
||||
assert.bail=true
|
||||
--SKIPIF--
|
||||
<?php include('skipif.inc'); ?>
|
||||
--ENV--
|
||||
XML_FILE=/wrong_book_with_dtd.xml
|
||||
LOAD_OPTIONS=LIBXML_DTDVALID
|
||||
EXPECTED_RESULT=1
|
||||
--FILE_EXTERNAL--
|
||||
domdocumentload_test_method.php
|
||||
--EXPECTF--
|
||||
Warning: DOMDocument::load%r(XML){0,1}%r(): Element book content does not follow the DTD, expecting (title , author), got (title author author ) %s
|
||||
@@ -0,0 +1,22 @@
|
||||
--TEST--
|
||||
Test DOMDocument::load() with LIBXML_DTDVALID and LIBXML_NOERROR options
|
||||
--DESCRIPTION--
|
||||
This test vrifies the right behaviour of the LIBXML_NOERROR constant
|
||||
which avoids the display of the warning message
|
||||
Environment variables used in the test:
|
||||
- XML_FILE: the xml file to load
|
||||
- LOAD_OPTIONS: the second parameter to pass to the method
|
||||
- EXPECTED_RESULT: the expected result
|
||||
--CREDITS--
|
||||
Antonio Diaz Ruiz <dejalatele@gmail.com>
|
||||
--INI--
|
||||
assert.bail=true
|
||||
--SKIPIF--
|
||||
<?php include('skipif.inc'); ?>
|
||||
--ENV--
|
||||
XML_FILE=/wrong_book_with_dtd.xml
|
||||
LOAD_OPTIONS=LIBXML_DTDVALID | LIBXML_NOERROR
|
||||
EXPECTED_RESULT=1
|
||||
--FILE_EXTERNAL--
|
||||
domdocumentload_test_method.php
|
||||
--EXPECT--
|
||||
@@ -0,0 +1,25 @@
|
||||
--TEST--
|
||||
Test DOMDocument::load() with LIBXML_DTDATTR, LIBXML_NOCDATA, LIBXML_NOENT, LIBXML_NOBLANKS
|
||||
--DESCRIPTION--
|
||||
This test verifies the right behaviour of the following constants:
|
||||
LIBXML_DTDATTR, LIBXML_NOCDATA, LIBXML_NOENT and LIBXML_NOBLANKS
|
||||
Environment variables used in the test:
|
||||
- XML_FILE: the xml file to load
|
||||
- LOAD_OPTIONS: the second parameter to pass to the method
|
||||
- EXPECTED_RESULT: the expected result
|
||||
--CREDITS--
|
||||
Antonio Diaz Ruiz <dejalatele@gmail.com>
|
||||
--INI--
|
||||
assert.bail=true
|
||||
--SKIPIF--
|
||||
<?php include('skipif.inc'); ?>
|
||||
--ENV--
|
||||
XML_FILE=/book_with_dtd.xml
|
||||
LOAD_OPTIONS=LIBXML_DTDATTR|LIBXML_NOCDATA|LIBXML_NOENT|LIBXML_NOBLANKS
|
||||
EXPECTED_RESULT=1
|
||||
--FILE_EXTERNAL--
|
||||
domdocumentload_test_method_savexml.php
|
||||
--EXPECT--
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE books SYSTEM "books.dtd">
|
||||
<books><book><title default="default title">The Grapes of Wrath</title><author>John Steinbeck</author></book><book><title default="default title">The Pearl</title><author>John Steinbeck</author></book><book><title default="default title">entity is only for test purposes</title><author>data for test</author></book></books>
|
||||
@@ -0,0 +1,25 @@
|
||||
--TEST--
|
||||
DomDocument::schemaValidateSource() - Add missing attribute default values from schema
|
||||
--CREDITS--
|
||||
Chris Wright <info@daverandom.com>
|
||||
--SKIPIF--
|
||||
<?php require_once('skipif.inc'); ?>
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
$doc = new DOMDocument;
|
||||
|
||||
$doc->load(dirname(__FILE__)."/book-attr.xml");
|
||||
|
||||
$xsd = file_get_contents(dirname(__FILE__)."/book.xsd");
|
||||
|
||||
$doc->schemaValidateSource($xsd, LIBXML_SCHEMA_CREATE);
|
||||
|
||||
foreach ($doc->getElementsByTagName('book') as $book) {
|
||||
var_dump($book->getAttribute('is-hardback'));
|
||||
}
|
||||
|
||||
?>
|
||||
--EXPECT--
|
||||
string(5) "false"
|
||||
string(4) "true"
|
||||
@@ -17,5 +17,5 @@ var_dump($result);
|
||||
|
||||
?>
|
||||
--EXPECTF--
|
||||
Warning: DOMDocument::schemaValidateSource() expects exactly 1 parameter, 0 given in %s.php on line %d
|
||||
Warning: DOMDocument::schemaValidateSource() expects at least 1 parameter, 0 given in %s.php on line %d
|
||||
NULL
|
||||
@@ -0,0 +1,25 @@
|
||||
--TEST--
|
||||
DomDocument::schemaValidateSource() - Don't add missing attribute default values from schema
|
||||
--CREDITS--
|
||||
Chris Wright <info@daverandom.com>
|
||||
--SKIPIF--
|
||||
<?php require_once('skipif.inc'); ?>
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
$doc = new DOMDocument;
|
||||
|
||||
$doc->load(dirname(__FILE__)."/book-attr.xml");
|
||||
|
||||
$xsd = file_get_contents(dirname(__FILE__)."/book.xsd");
|
||||
|
||||
$doc->schemaValidateSource($xsd);
|
||||
|
||||
foreach ($doc->getElementsByTagName('book') as $book) {
|
||||
var_dump($book->getAttribute('is-hardback'));
|
||||
}
|
||||
|
||||
?>
|
||||
--EXPECT--
|
||||
string(0) ""
|
||||
string(4) "true"
|
||||
@@ -0,0 +1,23 @@
|
||||
--TEST--
|
||||
DomDocument::schemaValidate() - Add missing attribute default values from schema
|
||||
--CREDITS--
|
||||
Chris Wright <info@daverandom.com>
|
||||
--SKIPIF--
|
||||
<?php require_once('skipif.inc'); ?>
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
$doc = new DOMDocument;
|
||||
|
||||
$doc->load(dirname(__FILE__)."/book-attr.xml");
|
||||
|
||||
$doc->schemaValidate(dirname(__FILE__)."/book.xsd", LIBXML_SCHEMA_CREATE);
|
||||
|
||||
foreach ($doc->getElementsByTagName('book') as $book) {
|
||||
var_dump($book->getAttribute('is-hardback'));
|
||||
}
|
||||
|
||||
?>
|
||||
--EXPECT--
|
||||
string(5) "false"
|
||||
string(4) "true"
|
||||
@@ -17,5 +17,5 @@ var_dump($result);
|
||||
|
||||
?>
|
||||
--EXPECTF--
|
||||
Warning: DOMDocument::schemaValidate() expects exactly 1 parameter, 0 given in %s.php on line %d
|
||||
Warning: DOMDocument::schemaValidate() expects at least 1 parameter, 0 given in %s.php on line %d
|
||||
NULL
|
||||
@@ -1,5 +1,5 @@
|
||||
--TEST--
|
||||
DomDocument::schemaValidate() - non-existant schema file
|
||||
DomDocument::schemaValidate() - non-existent schema file
|
||||
--CREDITS--
|
||||
Daniel Convissor <danielc@php.net>
|
||||
# TestFest 2009 NYPHP
|
||||
@@ -12,14 +12,14 @@ $doc = new DOMDocument;
|
||||
|
||||
$doc->load(dirname(__FILE__)."/book.xml");
|
||||
|
||||
$result = $doc->schemaValidate(dirname(__FILE__)."/non-existant-file");
|
||||
$result = $doc->schemaValidate(dirname(__FILE__)."/non-existent-file");
|
||||
var_dump($result);
|
||||
|
||||
?>
|
||||
--EXPECTF--
|
||||
Warning: DOMDocument::schemaValidate(): I/O warning : failed to load external entity "%snon-existant-file" in %s.php on line %d
|
||||
Warning: DOMDocument::schemaValidate(): I/O warning : failed to load external entity "%snon-existent-file" in %s.php on line %d
|
||||
|
||||
Warning: DOMDocument::schemaValidate(): Failed to locate the main schema resource at '%s/non-existant-file'. in %s.php on line %d
|
||||
Warning: DOMDocument::schemaValidate(): Failed to locate the main schema resource at '%s/non-existent-file'. in %s.php on line %d
|
||||
|
||||
Warning: DOMDocument::schemaValidate(): Invalid Schema in %s.php on line %d
|
||||
bool(false)
|
||||
@@ -0,0 +1,23 @@
|
||||
--TEST--
|
||||
DomDocument::schemaValidate() - Don't add missing attribute default values from schema
|
||||
--CREDITS--
|
||||
Chris Wright <info@daverandom.com>
|
||||
--SKIPIF--
|
||||
<?php require_once('skipif.inc'); ?>
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
$doc = new DOMDocument;
|
||||
|
||||
$doc->load(dirname(__FILE__)."/book-attr.xml");
|
||||
|
||||
$doc->schemaValidate(dirname(__FILE__)."/book.xsd");
|
||||
|
||||
foreach ($doc->getElementsByTagName('book') as $book) {
|
||||
var_dump($book->getAttribute('is-hardback'));
|
||||
}
|
||||
|
||||
?>
|
||||
--EXPECT--
|
||||
string(0) ""
|
||||
string(4) "true"
|
||||
@@ -0,0 +1,11 @@
|
||||
<?xml version="1.0" ?>
|
||||
<books>
|
||||
<book>
|
||||
<title>The Grapes of Wrath</title>
|
||||
<author>John Steinbeck</author>
|
||||
</book>
|
||||
<book is-hardback="true">
|
||||
<title>The Pearl</title>
|
||||
<author>John Steinbeck</author>
|
||||
</book>
|
||||
</books>
|
||||
@@ -9,6 +9,7 @@
|
||||
<xs:element name="title" type="xs:string"/>
|
||||
<xs:element name="author" type="xs:string"/>
|
||||
</xs:sequence>
|
||||
<xs:attribute name="is-hardback" type="xs:boolean" default="false" use="optional" />
|
||||
</xs:complexType>
|
||||
</xs:element>
|
||||
</xs:sequence>
|
||||
|
||||
@@ -0,0 +1,16 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE books SYSTEM "books.dtd">
|
||||
<books>
|
||||
<book>
|
||||
<title>The Grapes of Wrath</title>
|
||||
<author>John Steinbeck</author>
|
||||
</book>
|
||||
<book>
|
||||
<title>The Pearl</title>
|
||||
<author>John Steinbeck</author>
|
||||
</book>
|
||||
<book>
|
||||
<title>&entitest;</title>
|
||||
<author><![CDATA[data for test]]></author>
|
||||
</book>
|
||||
</books>
|
||||
@@ -0,0 +1,23 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE books [
|
||||
<!ENTITY entitest "entity is only for test purposes">
|
||||
<!ATTLIST title default CDATA "default title">
|
||||
<!ELEMENT books (book*)>
|
||||
<!ELEMENT book (title, author)>
|
||||
<!ELEMENT title (#PCDATA)>
|
||||
<!ELEMENT author (#PCDATA)>
|
||||
]>
|
||||
<books>
|
||||
<book>
|
||||
<title>The Grapes of Wrath</title>
|
||||
<author>John Steinbeck</author>
|
||||
</book>
|
||||
<book>
|
||||
<title>The Pearl</title>
|
||||
<author>John Steinbeck</author>
|
||||
</book>
|
||||
<book>
|
||||
<title>&entitest;</title>
|
||||
<author><![CDATA[data for test]]></author>
|
||||
</book>
|
||||
</books>
|
||||
@@ -0,0 +1,7 @@
|
||||
<!ENTITY entitest "entity is only for test purposes">
|
||||
<!ATTLIST title
|
||||
default CDATA "default title">
|
||||
<!ELEMENT books (book*)>
|
||||
<!ELEMENT book (title, author)>
|
||||
<!ELEMENT title (#PCDATA)>
|
||||
<!ELEMENT author (#PCDATA)>
|
||||
@@ -1,5 +1,5 @@
|
||||
--TEST--
|
||||
Bug #44648 (Attribute names not checked for wellformedness)
|
||||
Bug #44648 (Attribute names not checked for well formedness)
|
||||
--SKIPIF--
|
||||
<?php require_once('skipif.inc'); ?>
|
||||
--FILE--
|
||||
|
||||
@@ -0,0 +1,12 @@
|
||||
<?php
|
||||
include(dirname(__FILE__) . '/domdocumentload_utilities.php');
|
||||
|
||||
$doc = new DOMDocument();
|
||||
|
||||
$libxml_options = libxml_options_to_int(getenv('LOAD_OPTIONS'));
|
||||
|
||||
$result = $doc->load(dirname(__FILE__) . getenv('XML_FILE'), $libxml_options);
|
||||
|
||||
$expectedResult = (bool) getenv('EXPECTED_RESULT');
|
||||
assert('$result === $expectedResult');
|
||||
?>
|
||||
@@ -0,0 +1,14 @@
|
||||
<?php
|
||||
include(dirname(__FILE__) . '/domdocumentload_utilities.php');
|
||||
|
||||
$doc = new DOMDocument();
|
||||
|
||||
$libxml_options = libxml_options_to_int(getenv('LOAD_OPTIONS'));
|
||||
|
||||
$result = $doc->load(dirname(__FILE__) . getenv('XML_FILE'), $libxml_options);
|
||||
|
||||
$expectedResult = (bool) getenv('EXPECTED_RESULT');
|
||||
assert('$result === $expectedResult');
|
||||
|
||||
echo $doc->saveXML();
|
||||
?>
|
||||
@@ -0,0 +1,16 @@
|
||||
<?php
|
||||
|
||||
function libxml_options_to_int($libxmlOptions) {
|
||||
|
||||
$defined_constants = get_defined_constants(true);
|
||||
$env_array = explode('|', $libxmlOptions);
|
||||
$libxml_constants = array_intersect_key($defined_constants['libxml'], array_flip($env_array));
|
||||
|
||||
$sum = 0;
|
||||
foreach($libxml_constants as $value) {
|
||||
$sum = $sum|$value;
|
||||
}
|
||||
|
||||
return $sum;
|
||||
}
|
||||
?>
|
||||
@@ -0,0 +1,12 @@
|
||||
<?php
|
||||
include(dirname(__FILE__) . '/domdocumentload_utilities.php');
|
||||
|
||||
$doc = new DOMDocument();
|
||||
|
||||
$libxml_options = libxml_options_to_int(getenv('LOAD_OPTIONS'));
|
||||
$result = $doc->loadXML(file_get_contents(dirname(__FILE__) . getenv('XML_FILE')),
|
||||
$libxml_options);
|
||||
|
||||
$expectedResult = (bool) getenv('EXPECTED_RESULT');
|
||||
assert('$result === $expectedResult');
|
||||
?>
|
||||
@@ -0,0 +1,14 @@
|
||||
<?php
|
||||
include(dirname(__FILE__) . '/domdocumentload_utilities.php');
|
||||
|
||||
$doc = new DOMDocument();
|
||||
|
||||
$libxml_options = libxml_options_to_int(getenv('LOAD_OPTIONS'));
|
||||
$result = $doc->loadXML(file_get_contents(dirname(__FILE__) . getenv('XML_FILE')),
|
||||
$libxml_options);
|
||||
|
||||
$expectedResult = (bool) getenv('EXPECTED_RESULT');
|
||||
assert('$result === $expectedResult');
|
||||
|
||||
echo $doc->saveXML();
|
||||
?>
|
||||
@@ -0,0 +1,12 @@
|
||||
<?xml version="1.0" ?>
|
||||
<!-- Opening and ending tag mismatch -->
|
||||
<books>
|
||||
<book>
|
||||
<title>The Grapes of Wrath
|
||||
<author>John Steinbeck</author>
|
||||
</book>
|
||||
<book>
|
||||
<title>The Pearl</title>
|
||||
<author>John Steinbeck</author>
|
||||
</book>
|
||||
</books>
|
||||
@@ -0,0 +1,12 @@
|
||||
<?xml version="1.0" ?>
|
||||
<!-- AttValue: " or ' expected -->
|
||||
<books>
|
||||
<book number=nine>
|
||||
<title>The Grapes of Wrath</title>
|
||||
<author>John Steinbeck</author>
|
||||
</book>
|
||||
<book>
|
||||
<title>The Pearl</title>
|
||||
<author>John Steinbeck</author>
|
||||
</book>
|
||||
</books>
|
||||
@@ -0,0 +1,12 @@
|
||||
<?xml version="1.0" ?>
|
||||
<!-- Opening and ending tag mismatch -->
|
||||
<books>
|
||||
<book>
|
||||
<title>The Grapes of Wrath</title>
|
||||
<author>John Steinbeck</author>
|
||||
</book>
|
||||
<boOk>
|
||||
<title>The Pearl</title>
|
||||
<author>John Steinbeck</author>
|
||||
</book>
|
||||
</books>
|
||||
@@ -0,0 +1,12 @@
|
||||
<?xml version="3.1" ?>
|
||||
<!-- Unsupported version '3.1' -->
|
||||
<books>
|
||||
<book>
|
||||
<title>The Grapes of Wrath</title>
|
||||
<author>John Steinbeck</author>
|
||||
</book>
|
||||
<book>
|
||||
<title>The Pearl</title>
|
||||
<author>John Steinbeck</author>
|
||||
</book>
|
||||
</books>
|
||||
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" ?>
|
||||
<!-- Extra content at the end of the document -->
|
||||
<book>
|
||||
<title>The Grapes of Wrath</title>
|
||||
<author>John Steinbeck</author>
|
||||
</book>
|
||||
<book>
|
||||
<title>The Pearl</title>
|
||||
<author>John Steinbeck</author>
|
||||
</book>
|
||||
@@ -0,0 +1,13 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE books SYSTEM "books.dtd">
|
||||
<books>
|
||||
<book>
|
||||
<title>The Grapes of Wrath</title>
|
||||
<author>John Steinbeck</author>
|
||||
<author>John Steinbeck</author>
|
||||
</book>
|
||||
<book>
|
||||
<title>The Pearl</title>
|
||||
<author>John Steinbeck</author>
|
||||
</book>
|
||||
</books>
|
||||
@@ -0,0 +1,20 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE books [
|
||||
<!ENTITY entitest "entity is only for test purposes">
|
||||
<!ATTLIST title default CDATA "default title">
|
||||
<!ELEMENT books (book)*>
|
||||
<!ELEMENT book (title , author)>
|
||||
<!ELEMENT title (#PCDATA)>
|
||||
<!ELEMENT author (#PCDATA)>
|
||||
]>
|
||||
<books>
|
||||
<book>
|
||||
<title>The Grapes of Wrath</title>
|
||||
<author>John Steinbeck</author>
|
||||
<author>John Steinbeck</author>
|
||||
</book>
|
||||
<book>
|
||||
<title>The Pearl</title>
|
||||
<author>John Steinbeck</author>
|
||||
</book>
|
||||
</books>
|
||||
Loaded 100 of 504 files, more files were not shown because too many files have changed in this diff.
Show more
Reference in new issue
Block a user