mirror of
https://github.com/bdnugget/php-src.git
synced 2026-11-09 02:00:49 +00:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
0c213226c8 | ||
|
|
74eb820c34 | ||
|
|
1e392f8815 | ||
|
|
a0fb889d93 | ||
|
|
72fd82a63c | ||
|
|
b5a9e753ec | ||
|
|
407caf3a0c | ||
|
|
f2b7465c69 | ||
|
|
47d3d7eafe | ||
|
|
54ad6e3c7c | ||
|
|
46cc83975a | ||
|
|
d1e841841b | ||
|
|
5a51cc577d | ||
|
|
91b6eb5f5c | ||
|
|
944e948c96 | ||
|
|
dea7cce627 | ||
|
|
c3b1d9e9ef | ||
|
|
bcef2d4a33 | ||
|
|
4ab6f61081 | ||
|
|
1016df1c1a | ||
|
|
fc45bcc239 | ||
|
|
6234066f36 | ||
|
|
c137269b04 | ||
|
|
3752f6424c | ||
|
|
40fb483022 | ||
|
|
cc5a4bff59 | ||
|
|
7d7ccbb6d8 | ||
|
|
a4d0130763 | ||
|
|
a060c0ad46 | ||
|
|
dbd78f182e | ||
|
|
c0f745779e | ||
|
|
8baeb7013c | ||
|
|
4632301400 | ||
|
|
5613ec2d41 | ||
|
|
6cfc62dfeb | ||
|
|
32e7fae918 | ||
|
|
9345a6b7a8 | ||
|
|
6795e93c19 | ||
|
|
3afcea9cbe | ||
|
|
a91df0f95f | ||
|
|
1b237976ad | ||
|
|
75a67bc590 | ||
|
|
4516e20a39 | ||
|
|
3067c75e5e | ||
|
|
e77288df80 | ||
|
|
406336dad2 | ||
|
|
62dc6b9431 | ||
|
|
8c3fd03129 | ||
|
|
2ca6bfcba0 | ||
|
|
9f683780a2 | ||
|
|
a23e5be9d8 | ||
|
|
8aaa59b611 | ||
|
|
0e56ce2bba | ||
|
|
d34d160d5f | ||
|
|
bd5f7d692b | ||
|
|
a77d359259 | ||
|
|
568f2d8f8e | ||
|
|
276f60a5a7 | ||
|
|
7f5a1a0902 | ||
|
|
414f6860f1 | ||
|
|
20f49684a2 | ||
|
|
c885a401e3 | ||
|
|
1ee3f58d52 | ||
|
|
6b840ef5c5 | ||
|
|
99943ed129 | ||
|
|
4b27a9374a | ||
|
|
10cce6a972 | ||
|
|
7daabd7df8 | ||
|
|
6676502c48 | ||
|
|
f711029044 | ||
|
|
afc6a2461b | ||
|
|
73a4d2e69c | ||
|
|
55f0daf65d | ||
|
|
78d11cbc70 | ||
|
|
b096a5de17 | ||
|
|
25de341259 | ||
|
|
ef0d7e3f58 | ||
|
|
7e6beb9f28 | ||
|
|
5649f24524 | ||
|
|
87583528c6 | ||
|
|
3c831fef01 | ||
|
|
91999f1175 | ||
|
|
3a7aee2472 | ||
|
|
1192667679 | ||
|
|
9e4283227d | ||
|
|
24f0701867 | ||
|
|
43db0fce03 | ||
|
|
f03fe1c09d | ||
|
|
c10762e967 | ||
|
|
fd2726641b | ||
|
|
0c6f5f5810 | ||
|
|
79fd560e5e | ||
|
|
efad37874b | ||
|
|
dbf2a5c65c | ||
|
|
ed33d232e0 | ||
|
|
f57c75112d | ||
|
|
a34755e9cf | ||
|
|
7941dcf544 | ||
|
|
ab5a8b2ae3 | ||
|
|
e95addcbfa | ||
|
|
8d1cc50067 | ||
|
|
30f98ae77b | ||
|
|
7614368f8a | ||
|
|
c1555236c9 | ||
|
|
6f1a0f67ff | ||
|
|
299fe2554f | ||
|
|
8f87235107 | ||
|
|
f3a123a9db | ||
|
|
ea2037a2d3 | ||
|
|
07e11dcc4d | ||
|
|
aa5dbc8c92 | ||
|
|
fa94d911df | ||
|
|
6ba807db50 | ||
|
|
ff452441e2 | ||
|
|
522ce80071 | ||
|
|
e0beb7fc71 | ||
|
|
0c54f6f72b | ||
|
|
3566fe4afd | ||
|
|
fc4614d1d2 | ||
|
|
ca2efe468d | ||
|
|
7775550245 | ||
|
|
bbda630ed9 | ||
|
|
af11e1d592 | ||
|
|
d18cd00657 | ||
|
|
0a38d6bd8c | ||
|
|
896a5216d7 | ||
|
|
b1de3647cf | ||
|
|
90b3dadc4e | ||
|
|
1c02dff74a | ||
|
|
5b973c86ee | ||
|
|
c86e96db11 | ||
|
|
033c07972f | ||
|
|
a1bbdf831c | ||
|
|
b81e20f8e8 | ||
|
|
658b22ad6e | ||
|
|
2765fdfa46 | ||
|
|
ea53739d30 | ||
|
|
8663f1644d | ||
|
|
64de59d9a7 | ||
|
|
ee103a7c39 | ||
|
|
32872b157e | ||
|
|
50e1a51e5c | ||
|
|
f7a6327728 | ||
|
|
bdef85af21 | ||
|
|
09dec62672 | ||
|
|
227ca46fb7 | ||
|
|
974dc0f5b4 | ||
|
|
68906dbe62 | ||
|
|
9ea8d8dbf6 | ||
|
|
7315288591 | ||
|
|
1c0d8a536a | ||
|
|
349bcd7443 | ||
|
|
d19c105819 | ||
|
|
73e4913cca | ||
|
|
101d925baa | ||
|
|
76419e13aa | ||
|
|
5fd0994495 | ||
|
|
92da3229d4 | ||
|
|
3ef88178e8 | ||
|
|
cfaf6406d7 | ||
|
|
7330c32329 | ||
|
|
74672b86b4 | ||
|
|
79d8f014da | ||
|
|
29254a477d | ||
|
|
f233299f96 | ||
|
|
522a5e128f | ||
|
|
011266f7e1 | ||
|
|
7c42ddb8e0 | ||
|
|
874a22101f | ||
|
|
67abcb58c3 | ||
|
|
af429910ef | ||
|
|
65fcbcbdc0 | ||
|
|
f897cff480 | ||
|
|
851801a795 | ||
|
|
46e0ede425 | ||
|
|
9047558fe3 | ||
|
|
5751903b1b | ||
|
|
2d2f1cf0c6 | ||
|
|
2e461783d0 | ||
|
|
a6e4f11cb1 | ||
|
|
195271dd23 | ||
|
|
bac1fda336 | ||
|
|
d23c1d763b | ||
|
|
f23d01ad4d | ||
|
|
6e762e648c | ||
|
|
6a4faee367 | ||
|
|
47cb31b7df | ||
|
|
4043f77e36 | ||
|
|
4bab5226b2 | ||
|
|
45b64e7a99 | ||
|
|
6ea747d8e4 | ||
|
|
6c89fd2d63 | ||
|
|
8bbf3a00dc | ||
|
|
3438469b84 | ||
|
|
07d7750487 | ||
|
|
fabd954200 | ||
|
|
64e7be9b5a | ||
|
|
12346d64eb | ||
|
|
276171f871 | ||
|
|
22a8c3113b | ||
|
|
8cd558757f | ||
|
|
c261351a97 | ||
|
|
3110d15a00 | ||
|
|
5241090585 | ||
|
|
06ef71fe3d | ||
|
|
1e33c4cc85 | ||
|
|
8afc859b55 | ||
|
|
f83cfb77bf | ||
|
|
b9f85f37cc | ||
|
|
687e6ffc58 | ||
|
|
bb5f3aa012 | ||
|
|
0f4137fbd9 | ||
|
|
9e5655387a | ||
|
|
e8270edf9d | ||
|
|
5151efc2aa | ||
|
|
3511649498 | ||
|
|
e9d452b9a9 | ||
|
|
79b3d79a95 | ||
|
|
670ed5d93f | ||
|
|
8c40d605e4 | ||
|
|
ead7652457 | ||
|
|
6624682dff | ||
|
|
8625b42162 | ||
|
|
4033bfbda0 | ||
|
|
3d7abc2931 | ||
|
|
d288f66c7c | ||
|
|
ad7768ee63 | ||
|
|
8f7319a49f | ||
|
|
40e25b5ad7 | ||
|
|
52296072e0 | ||
|
|
783dd9f0ff | ||
|
|
7522fb7272 | ||
|
|
569ce842f1 | ||
|
|
c0592d17e9 | ||
|
|
793d0ab719 | ||
|
|
0944a47107 | ||
|
|
e25a1dccac | ||
|
|
f0cf877a81 | ||
|
|
c58e1fa5be | ||
|
|
5ccfa591b7 | ||
|
|
0f510a6a95 | ||
|
|
3edb5a8b6d | ||
|
|
bace0def1e | ||
|
|
b97b088800 | ||
|
|
46ba651680 | ||
|
|
f8e6ffee30 | ||
|
|
9a59df13cc | ||
|
|
8ccdceb4db | ||
|
|
ea9487249b | ||
|
|
193ae05edd | ||
|
|
0fab5aacce | ||
|
|
7fbb54f55c | ||
|
|
b6c9363f73 | ||
|
|
14aef92b2f | ||
|
|
7385433f34 | ||
|
|
0e07f0b117 | ||
|
|
4aece8077c | ||
|
|
867f89e575 | ||
|
|
62ce6717ad | ||
|
|
ad746130ad | ||
|
|
59b8592c8c | ||
|
|
697c652001 | ||
|
|
eab2f690fd | ||
|
|
1fa58ec003 | ||
|
|
08e6fded56 | ||
|
|
cfbcb43d63 | ||
|
|
6387d83a05 | ||
|
|
77acc692fd | ||
|
|
ea22696fb9 | ||
|
|
6dc42ef117 | ||
|
|
cdbe8b4fd8 | ||
|
|
4ca3df56d3 | ||
|
|
a93bd9d493 | ||
|
|
c5df14364b | ||
|
|
fb7d5bd780 | ||
|
|
2030a7a2ed | ||
|
|
cde55c9223 | ||
|
|
0dded18b33 | ||
|
|
82376269fd | ||
|
|
0b02327267 | ||
|
|
dfd5b4fbf4 | ||
|
|
a33d64e7b6 | ||
|
|
a824bcf41d | ||
|
|
7b70ca475f | ||
|
|
bf4ae10c36 | ||
|
|
d085b37f66 | ||
|
|
65d704cb7c | ||
|
|
bf3a7e12e1 | ||
|
|
f8183e2e97 | ||
|
|
b3a437fcc4 | ||
|
|
9e26f6c213 | ||
|
|
ed43fd9b3b | ||
|
|
fe1c2cfc0f | ||
|
|
1ad4dd8795 | ||
|
|
3b1cb0e500 | ||
|
|
5f80bcaf26 | ||
|
|
e40df39518 | ||
|
|
041e7470b1 | ||
|
|
1440bb5c7b | ||
|
|
4b4d61952f | ||
|
|
660956b514 | ||
|
|
87ae2460d1 | ||
|
|
dbe881d9c2 | ||
|
|
cb3a53db83 | ||
|
|
0c1b4f45eb | ||
|
|
c4db88563f | ||
|
|
1ce8546cd1 | ||
|
|
09fcf3162c | ||
|
|
f7ce1d6260 | ||
|
|
32f611097f | ||
|
|
8a58105f42 | ||
|
|
6c101d6400 | ||
|
|
7b7717d196 | ||
|
|
f9835c3786 | ||
|
|
d76e149f0e | ||
|
|
7019b978a0 | ||
|
|
1122f647d2 | ||
|
|
bafba669ad | ||
|
|
658ac96cfa | ||
|
|
e8d320dd77 | ||
|
|
8d012d041f | ||
|
|
85019bf450 | ||
|
|
fa3173bec3 | ||
|
|
6912dab9eb | ||
|
|
79e7432c97 | ||
|
|
b2bbaca8e8 | ||
|
|
f789f0e384 | ||
|
|
3309d14af2 | ||
|
|
edbfb9c2c7 | ||
|
|
6aaf510bf0 | ||
|
|
608c3207a6 | ||
|
|
b5001f5383 | ||
|
|
afd781a09a | ||
|
|
110021f4c7 | ||
|
|
d355704998 | ||
|
|
ef1f36e2c1 | ||
|
|
90d7fbe798 | ||
|
|
4651f79ed5 | ||
|
|
4ccd89d147 | ||
|
|
5a49926c38 | ||
|
|
cf01cff2e5 | ||
|
|
23b8ce3876 | ||
|
|
91f4b380d6 | ||
|
|
5c7c11c41d | ||
|
|
4e75cd5548 | ||
|
|
fa922fb51c | ||
|
|
2ea6d46e4f | ||
|
|
aaec067578 | ||
|
|
7731dc9421 | ||
|
|
63b3f5c041 | ||
|
|
652d77eca4 | ||
|
|
76a7240d70 | ||
|
|
55159796b0 | ||
|
|
d82462485e | ||
|
|
c31c984365 | ||
|
|
6fd71dbbe9 | ||
|
|
7c14d86dc3 | ||
|
|
eacb27d2da | ||
|
|
92ba7cccad | ||
|
|
79983ce0ce | ||
|
|
6f76b17079 | ||
|
|
7865dfb5b8 | ||
|
|
056bea6de7 | ||
|
|
c6b8c26cdf | ||
|
|
829642a0b7 | ||
|
|
98bacb0e21 | ||
|
|
ef3d879315 | ||
|
|
0a076b11df | ||
|
|
9d6e4964a1 | ||
|
|
161ae714ae | ||
|
|
a8dbb0ded6 | ||
|
|
0bcd459300 | ||
|
|
a371a8c153 | ||
|
|
01479757e3 | ||
|
|
80ea07d30c | ||
|
|
c69f100d0e | ||
|
|
ad10a538ee | ||
|
|
d21669fc80 | ||
|
|
9e90d5b3c0 | ||
|
|
0add197ec8 | ||
|
|
1c340d515d | ||
|
|
e7f6a3fab2 | ||
|
|
e16bba12b1 | ||
|
|
2e3ae2f5c2 | ||
|
|
06d235fbf1 | ||
|
|
941d86a204 | ||
|
|
b80f9567d5 | ||
|
|
e13e2fe9ba | ||
|
|
79a968b21e | ||
|
|
6c4e9d30b9 | ||
|
|
0ebab9d495 | ||
|
|
61f7dc1396 | ||
|
|
7ffc24b9f3 | ||
|
|
97f463c156 | ||
|
|
6dff869c51 | ||
|
|
fe13b8ef69 | ||
|
|
b04ecd08d2 | ||
|
|
e1d9cf07cd | ||
|
|
6dcb27d35c | ||
|
|
74868fae47 | ||
|
|
4a5dd30201 | ||
|
|
0aa24dc0a1 | ||
|
|
b8d26da1be | ||
|
|
5dea328391 | ||
|
|
4e6245978b | ||
|
|
f84c9acc77 | ||
|
|
8dffbf217d | ||
|
|
6ce1f43902 | ||
|
|
3563191049 | ||
|
|
b8be6d3664 | ||
|
|
a325d22cd1 | ||
|
|
1b688da7ac | ||
|
|
89a4054106 | ||
|
|
5bfe560cab | ||
|
|
d36a88bdda | ||
|
|
e70571c251 | ||
|
|
dc8221c154 | ||
|
|
94165e41a7 | ||
|
|
f08316b525 | ||
|
|
6e93f3eb8f | ||
|
|
ade3995a79 | ||
|
|
e795f8f427 | ||
|
|
7fd337f955 | ||
|
|
f87e7b8bab | ||
|
|
7d73045415 | ||
|
|
90ae21f310 | ||
|
|
7dc322754a | ||
|
|
41de805a9d | ||
|
|
e43a77d84c | ||
|
|
35ce5db25e | ||
|
|
a9080d38f4 | ||
|
|
0b12f7307e | ||
|
|
65211cddcc | ||
|
|
a1024ce679 | ||
|
|
54adfc6fcf | ||
|
|
d46b474e1e | ||
|
|
b32a78c4fa | ||
|
|
622347bd8c | ||
|
|
5c1dbf51af | ||
|
|
22c501b016 | ||
|
|
ea86f819a3 | ||
|
|
65cca0dc20 | ||
|
|
7addae5089 | ||
|
|
e2218515d2 | ||
|
|
1aa1c535b5 | ||
|
|
3840e428bb | ||
|
|
f128dff1ff | ||
|
|
84ad62553d | ||
|
|
3022080d84 | ||
|
|
477f503b9e | ||
|
|
c4b81d8720 | ||
|
|
728493ca37 | ||
|
|
2e37e86366 | ||
|
|
2e91228d15 | ||
|
|
e3ea152fee | ||
|
|
c5d70528d7 | ||
|
|
44d4ba478f | ||
|
|
d4ba0a9fc3 | ||
|
|
cde6f6e0cc | ||
|
|
3e056bc13c | ||
|
|
0b300dac3a | ||
|
|
4d442447f1 | ||
|
|
2d4b399fe1 | ||
|
|
2d02bedd9c | ||
|
|
5a69b29082 | ||
|
|
84fc80064b | ||
|
|
8fe5bc7010 | ||
|
|
bf213a2c7b | ||
|
|
941b0651dc | ||
|
|
611a6dece9 | ||
|
|
027abfd702 | ||
|
|
016dbe414e | ||
|
|
6520ff9afc | ||
|
|
521502f416 | ||
|
|
6d494f9725 | ||
|
|
c009a4f361 | ||
|
|
9f53c8e313 | ||
|
|
07e7092729 | ||
|
|
7409ed6403 | ||
|
|
f5241f165f | ||
|
|
c6cb1598be | ||
|
|
289f45c279 | ||
|
|
4ea898b79f | ||
|
|
089f1283ad | ||
|
|
59fa57d232 | ||
|
|
4b23428d9d | ||
|
|
f0d9ae46c3 | ||
|
|
afd8f0b608 | ||
|
|
78516c7905 | ||
|
|
92ac0940d3 | ||
|
|
bab48a0906 | ||
|
|
f10bab6f97 | ||
|
|
a8be85ce7e | ||
|
|
1e8aad5075 | ||
|
|
ce9dfedc69 | ||
|
|
2108714a2b | ||
|
|
f2ac3274d7 | ||
|
|
96843fe434 | ||
|
|
a790d6ed3d | ||
|
|
716d22a8f6 | ||
|
|
82b6ccbc30 | ||
|
|
8068342483 | ||
|
|
d43d090362 | ||
|
|
3608dd4c11 | ||
|
|
c65d61a301 | ||
|
|
1a170a3de2 | ||
|
|
1e05eec591 | ||
|
|
11187a40e0 | ||
|
|
9c614f8f8f | ||
|
|
4b2b9461d4 | ||
|
|
535a2e6092 | ||
|
|
5fb8810c76 | ||
|
|
e8d38828cd | ||
|
|
08c4c9c202 | ||
|
|
6cc9f92d16 | ||
|
|
8fe545aab7 | ||
|
|
044d24a23c | ||
|
|
c09237ffce | ||
|
|
8600417c79 | ||
|
|
f541b63e1f | ||
|
|
b0f0192f0c | ||
|
|
991c753bc5 | ||
|
|
1f8b320679 | ||
|
|
39a4a46ae4 | ||
|
|
0a6b074034 | ||
|
|
7deff63e3c | ||
|
|
3bafa8cead | ||
|
|
9167991f69 | ||
|
|
73605400e8 | ||
|
|
7831900882 | ||
|
|
5f83d7ce90 | ||
|
|
da30791861 | ||
|
|
0473a11ca2 | ||
|
|
f3e11a705c | ||
|
|
a3b941642c | ||
|
|
beea63529c | ||
|
|
6c180238fd | ||
|
|
a0d912490d | ||
|
|
a7c845ffcb | ||
|
|
38409e944c | ||
|
|
bccf4bd9e7 | ||
|
|
8911fac653 | ||
|
|
c353a52a11 | ||
|
|
4a179933b6 | ||
|
|
f2772ecc0d | ||
|
|
ff4ee6f043 | ||
|
|
aa920b8e00 | ||
|
|
64972c02de | ||
|
|
647eafcb5d | ||
|
|
3c1b981a28 | ||
|
|
3f68c2164b | ||
|
|
6f632a77c3 | ||
|
|
56db3290e2 | ||
|
|
39d71e375c | ||
|
|
5e673e0639 | ||
|
|
c3c092bba6 | ||
|
|
a78a0b460c | ||
|
|
aa1142eded | ||
|
|
52232a7f7a | ||
|
|
b179e081ab | ||
|
|
a31f337c24 | ||
|
|
db7195ee0c | ||
|
|
a266261eb6 | ||
|
|
3a4a0e3cef | ||
|
|
0c972edce4 | ||
|
|
0655132e2c | ||
|
|
ff30daae6e | ||
|
|
0506d1a9f5 | ||
|
|
7dc9be77fc | ||
|
|
6a176fa7b3 | ||
|
|
7e7fcc3a07 | ||
|
|
9774b6d3e6 | ||
|
|
d115747a24 | ||
|
|
8c55d477d8 | ||
|
|
b90d985a23 | ||
|
|
823b39b698 | ||
|
|
b73349dbe4 | ||
|
|
0249f6b6b6 | ||
|
|
526bc44ff7 | ||
|
|
3a800fe146 | ||
|
|
eb91dfc69e | ||
|
|
6f66a63cda | ||
|
|
657d5f086f | ||
|
|
b22ab5b5d3 | ||
|
|
f80f58168c | ||
|
|
9b0f4a6234 | ||
|
|
af56d9f1d4 | ||
|
|
e44b9f08f6 | ||
|
|
80cc4867e3 | ||
|
|
329198a955 | ||
|
|
f16b8429da | ||
|
|
2bfe34e06d | ||
|
|
fe52312f59 | ||
|
|
a146043c25 | ||
|
|
9494521055 | ||
|
|
26127e510f | ||
|
|
b12f8e6811 | ||
|
|
1b546b9f77 | ||
|
|
c5ef24bfee | ||
|
|
9eda552c75 | ||
|
|
ed58b573a1 | ||
|
|
84554b0364 | ||
|
|
c53b926a35 | ||
|
|
cb4bb6e389 | ||
|
|
77915bc208 | ||
|
|
ec605ac2ad | ||
|
|
8fde2249c3 | ||
|
|
9cb7d29f84 | ||
|
|
5f25d80d10 | ||
|
|
d0e1a4fdca | ||
|
|
ff438f1139 | ||
|
|
9cbc3ae264 | ||
|
|
2d1d476391 | ||
|
|
1d461a6bcc | ||
|
|
b1cebf32e4 | ||
|
|
cb27823e82 | ||
|
|
813a5651c1 | ||
|
|
4803abf07c | ||
|
|
e4295ed864 | ||
|
|
ffe84c11a7 | ||
|
|
90bb16db5a | ||
|
|
1070dec09a | ||
|
|
4697099ab0 | ||
|
|
5fb6e0703f | ||
|
|
0621bcc9e1 | ||
|
|
c447acf863 | ||
|
|
82d5901664 | ||
|
|
864004d4d7 | ||
|
|
01e8d313c8 | ||
|
|
26ef74f867 | ||
|
|
f0a60af876 | ||
|
|
fb7608a006 | ||
|
|
1d72f55e7d | ||
|
|
56242031aa | ||
|
|
4278ffd3b4 | ||
|
|
5a6a07467f | ||
|
|
b6cb9d3ce5 | ||
|
|
52933fc89d | ||
|
|
5ea4c827c9 | ||
|
|
e736bfc8b6 | ||
|
|
afa77062d1 | ||
|
|
328c294569 | ||
|
|
0f4302b872 | ||
|
|
5f9dde24d8 | ||
|
|
694042e527 | ||
|
|
ac1ec7914c | ||
|
|
3062348c75 | ||
|
|
bc410c3863 | ||
|
|
b8360c376b | ||
|
|
4b1791a767 | ||
|
|
71d4d4a91f | ||
|
|
3d80bd0cdf | ||
|
|
d059b92fea | ||
|
|
8488861e12 | ||
|
|
1edc8eec88 | ||
|
|
66cfc793a2 | ||
|
|
97086b2bc6 | ||
|
|
add3c79a23 | ||
|
|
a408c539cf | ||
|
|
5854cf10c7 | ||
|
|
04ac1f7fd1 | ||
|
|
fecfb80a00 | ||
|
|
c061fc6c37 | ||
|
|
1cdaf5d7b1 | ||
|
|
575e6b6e7c | ||
|
|
c863542dc1 | ||
|
|
754b747637 | ||
|
|
64447a29aa | ||
|
|
0851c649d1 | ||
|
|
e6f4c2bce2 | ||
|
|
db2697aae0 | ||
|
|
6c509aa837 | ||
|
|
f113090832 | ||
|
|
e731da3653 | ||
|
|
1cfcdf6612 | ||
|
|
8f5005e4b6 | ||
|
|
6ba295f311 | ||
|
|
ad1bbaca04 | ||
|
|
778c635c40 | ||
|
|
21891aecc1 | ||
|
|
92f050786f | ||
|
|
f079ef83ab | ||
|
|
5b46c42641 | ||
|
|
4972b45520 | ||
|
|
de8d0920d4 | ||
|
|
58349878fc | ||
|
|
4d64a617c3 | ||
|
|
02f405ccb1 | ||
|
|
08feff327a | ||
|
|
96723680d0 | ||
|
|
6486069a3f | ||
|
|
0d0f3e290b | ||
|
|
8c56ee5cb6 | ||
|
|
c4790e3a9e | ||
|
|
6fcc365c75 | ||
|
|
5121b2a78a | ||
|
|
32dc6ee526 | ||
|
|
8340e30313 | ||
|
|
e9c813af61 | ||
|
|
8eb44c317e | ||
|
|
b185e09245 | ||
|
|
864a2897df | ||
|
|
fc4fb89cac | ||
|
|
30cb5e36b8 | ||
|
|
61e93ccfe8 | ||
|
|
0d4965407e | ||
|
|
88268c6bcc | ||
|
|
594139b1ea | ||
|
|
da692974ab | ||
|
|
47e6f644f7 | ||
|
|
f9bfdc921a | ||
|
|
43fdbe99cd | ||
|
|
0839cadef6 | ||
|
|
fb91408a17 | ||
|
|
22f4a05149 | ||
|
|
58576f71c3 | ||
|
|
bcc1654de3 | ||
|
|
a5e15f2e1c | ||
|
|
6d8c69e3cb | ||
|
|
d4dd29194b | ||
|
|
488500acfb | ||
|
|
64a7e46506 | ||
|
|
34f32d4dcd | ||
|
|
e99fac3d01 | ||
|
|
d6ee7d1d9a | ||
|
|
9b01900321 | ||
|
|
e5ab119ad3 | ||
|
|
e2dd2d7e7a | ||
|
|
3a75666285 | ||
|
|
d03aea048f | ||
|
|
62b9a736bf | ||
|
|
63e14480fc | ||
|
|
12894cc1b6 | ||
|
|
5bd93221a8 | ||
|
|
220490222a | ||
|
|
56567d31b3 | ||
|
|
e3fd31503b | ||
|
|
9846878450 | ||
|
|
8479546920 | ||
|
|
90c6bfd259 | ||
|
|
8d63360fc4 | ||
|
|
c7d2d2a689 | ||
|
|
c2c7bc6a10 | ||
|
|
2a140b8f40 | ||
|
|
dc7ecd41ef | ||
|
|
bb29557060 | ||
|
|
b905bddda8 | ||
|
|
ad5af84a3c | ||
|
|
c5b9552891 | ||
|
|
b0ccd89450 | ||
|
|
5c32e974aa | ||
|
|
25aeeb5e25 | ||
|
|
a5acdfc5f2 | ||
|
|
3795f9d8bb | ||
|
|
0e396980a1 | ||
|
|
b5aeda4e65 | ||
|
|
f046cdf3fa | ||
|
|
21e1f5da43 | ||
|
|
f34a85bc58 | ||
|
|
d7c1980a21 | ||
|
|
73ab144544 | ||
|
|
74d3631062 | ||
|
|
64363f71f2 | ||
|
|
537900c8e8 | ||
|
|
8b35266a35 | ||
|
|
22ee7f8e3e | ||
|
|
ec1a7e02d4 | ||
|
|
7669169bd5 | ||
|
|
56d78654a3 | ||
|
|
6bcb57fc2b | ||
|
|
41284d17b0 | ||
|
|
386581b3f8 | ||
|
|
7ebca7d3b7 | ||
|
|
d07b094461 | ||
|
|
077559d3e4 | ||
|
|
f5a7694305 | ||
|
|
cfda375620 | ||
|
|
ef0c0cc62b | ||
|
|
2e50763315 | ||
|
|
319dff73fb | ||
|
|
6c2ebc6d76 | ||
|
|
11105b1eed | ||
|
|
caac5ef86d | ||
|
|
eea08af619 | ||
|
|
1a36aaf874 | ||
|
|
9a6a266b16 | ||
|
|
ad61a18a2e | ||
|
|
42f8bef053 | ||
|
|
b1cb83f3c9 | ||
|
|
7f75b5fbf4 | ||
|
|
d411d72053 | ||
|
|
f7c77f0f33 | ||
|
|
fc6d0f3264 | ||
|
|
4628a41c00 | ||
|
|
983263ce5d | ||
|
|
e18a1d7c08 | ||
|
|
248be6fcfc | ||
|
|
cf90abfc24 | ||
|
|
35343ffaec | ||
|
|
a151e632d5 | ||
|
|
3515689363 | ||
|
|
8c4d236546 | ||
|
|
a0872d6bed | ||
|
|
1c0971f3ce | ||
|
|
9c2ea13abc | ||
|
|
a034972797 | ||
|
|
7c17499079 | ||
|
|
ad90780930 | ||
|
|
c5b4115fd6 | ||
|
|
7f6018aa3a | ||
|
|
53e37ac843 | ||
|
|
c01d79b2df | ||
|
|
0986f33d1e | ||
|
|
34ff54e4c7 | ||
|
|
a7d2ac4189 | ||
|
|
970298401b | ||
|
|
fc0fe6472e | ||
|
|
59aecb1d88 | ||
|
|
fe3f66e188 | ||
|
|
8710b8c5f5 | ||
|
|
d09ad216a0 | ||
|
|
604990d6a5 | ||
|
|
b7d5d7047b | ||
|
|
c92ae847c7 | ||
|
|
97200944d2 | ||
|
|
fb607b0327 | ||
|
|
81a2bacdc4 | ||
|
|
f90214347e | ||
|
|
d831a501f7 | ||
|
|
ab056b02a1 | ||
|
|
8e43f0085b | ||
|
|
eb99c74567 | ||
|
|
af264f6f0d | ||
|
|
81c25d8700 | ||
|
|
48336bcd71 | ||
|
|
f0a0f89a2c | ||
|
|
3782a4acf2 | ||
|
|
670b075f87 | ||
|
|
97ec0f3db5 | ||
|
|
3450841dbe | ||
|
|
61c9b22536 | ||
|
|
5961160f95 | ||
|
|
cd82349b9e | ||
|
|
5df2f5df42 | ||
|
|
efff8a45e2 | ||
|
|
9255733c4f | ||
|
|
84326a9b72 | ||
|
|
aec3b4e73c | ||
|
|
4e09db1dbf | ||
|
|
78244d64af | ||
|
|
fc4ebee3e3 | ||
|
|
2a130b19fc | ||
|
|
e8a7e6a8cf | ||
|
|
7b581f6d19 | ||
|
|
32220d2e7e | ||
|
|
e989e9f70f | ||
|
|
ae5204a02a | ||
|
|
9e8a1bfcbe | ||
|
|
8aedeb8513 | ||
|
|
0d38bc9f80 | ||
|
|
5500dea5f1 | ||
|
|
93d339bede | ||
|
|
2a29db4b2b | ||
|
|
20b97141d4 | ||
|
|
5238fb0bee | ||
|
|
86ecf121e5 | ||
|
|
b1264f7172 | ||
|
|
99cd9ed713 | ||
|
|
59dc41f761 | ||
|
|
2b413f7af2 | ||
|
|
6654b31e26 | ||
|
|
b6f856fbec | ||
|
|
2f3678eb44 | ||
|
|
8d4080a6e1 | ||
|
|
29f5ce9af3 | ||
|
|
46f922bdf7 | ||
|
|
6370ae56ed | ||
|
|
a9ffac3eda | ||
|
|
5da39c99c6 | ||
|
|
58bd1ac860 | ||
|
|
ab55ed15d5 | ||
|
|
b83a0eb10c | ||
|
|
8370e1aca4 | ||
|
|
f7276af1c6 | ||
|
|
c2ed71a879 | ||
|
|
94518ca8e4 | ||
|
|
1024844a41 | ||
|
|
87db368a75 | ||
|
|
bfb72e0c08 | ||
|
|
905007669d | ||
|
|
18a99796ad | ||
|
|
adc26d2bca | ||
|
|
8c991f6a49 | ||
|
|
849a614275 | ||
|
|
70a53e10c6 | ||
|
|
e6ae0e99c3 | ||
|
|
e4210e3851 | ||
|
|
579e00d489 | ||
|
|
dfcc155c76 | ||
|
|
69fdadf1a0 | ||
|
|
10f77a5d71 | ||
|
|
4bb39ad2a5 | ||
|
|
57492cc2d4 | ||
|
|
0cd997d79c | ||
|
|
418223e2f6 | ||
|
|
17907a50cd | ||
|
|
460a4fecef | ||
|
|
8fee6ac1e2 | ||
|
|
84cd3c125c | ||
|
|
33c87b395f | ||
|
|
bdf9c4d15c | ||
|
|
a91f9fb786 | ||
|
|
9417c070f6 | ||
|
|
cb3cca21b3 | ||
|
|
67313884c1 | ||
|
|
5c8027584f | ||
|
|
85a578e029 | ||
|
|
00b9392bf5 | ||
|
|
b041abbb4e | ||
|
|
1b7e3fe2a5 | ||
|
|
71c7cdb7d9 | ||
|
|
f7aec44aee | ||
|
|
6c65d6df59 | ||
|
|
3ce27140dc | ||
|
|
900d49a553 | ||
|
|
cdb699b497 | ||
|
|
bc22352c30 | ||
|
|
f94b3012bd | ||
|
|
882a9effe6 | ||
|
|
a8a4d7944d | ||
|
|
a939717011 | ||
|
|
ec4fd02760 | ||
|
|
d43833ecff | ||
|
|
379cd5a6df | ||
|
|
db312cf18e | ||
|
|
a74463e9bd | ||
|
|
ddcc5257ac | ||
|
|
f19c2e00ec | ||
|
|
64f82f9c00 | ||
|
|
f75efcb505 | ||
|
|
60db0632dd | ||
|
|
bac905b982 | ||
|
|
9bb52c750c | ||
|
|
85a261bb85 | ||
|
|
d05c2a40d8 | ||
|
|
af1d83d783 | ||
|
|
c19fa0bbde | ||
|
|
ba6c82eee9 | ||
|
|
b3fc86b5f4 | ||
|
|
933d1d174c | ||
|
|
5e9c6555ad | ||
|
|
cc96967132 | ||
|
|
ca42324497 | ||
|
|
7a6ac7ce16 | ||
|
|
599221036f | ||
|
|
ce90a27a48 | ||
|
|
5461b5a6b1 | ||
|
|
eef44c609b | ||
|
|
4ccdc86561 | ||
|
|
b8572a0c9c | ||
|
|
c98ef984d8 | ||
|
|
6b86285dd2 | ||
|
|
fbeb8ae0d4 | ||
|
|
a4d0a4c625 | ||
|
|
ccdeb10696 | ||
|
|
84051ba42b | ||
|
|
c287dec802 | ||
|
|
185f085735 | ||
|
|
0d1efb245b | ||
|
|
25de19a2fb | ||
|
|
484de9c3a4 | ||
|
|
25670c59d3 | ||
|
|
b30602b78b | ||
|
|
3d4c1d6886 | ||
|
|
644cf05505 | ||
|
|
90bdbfa921 | ||
|
|
24d824d4e8 | ||
|
|
2d234ec4ac | ||
|
|
d5bb2e38ef | ||
|
|
9e8bf1a20f | ||
|
|
bfa084ddba | ||
|
|
241659ff70 | ||
|
|
e5bd8e32f5 | ||
|
|
5b561a6df3 | ||
|
|
2796160d15 | ||
|
|
0e46f5113c | ||
|
|
24af85dfe9 | ||
|
|
8c8907458c | ||
|
|
481ec28566 | ||
|
|
5e223ad13b | ||
|
|
31c35e5cad | ||
|
|
2b059ae91f | ||
|
|
dfba12435d | ||
|
|
085ff7f19b | ||
|
|
5fd5bead8a | ||
|
|
f2415625d4 | ||
|
|
aa1b0709f2 | ||
|
|
684d68bb27 | ||
|
|
3e669bc950 | ||
|
|
347032c753 | ||
|
|
a4295629b8 | ||
|
|
06b36f7cea | ||
|
|
253392f64f | ||
|
|
635e2bb028 | ||
|
|
4e874820e9 | ||
|
|
b9af8f2719 | ||
|
|
d95275052b | ||
|
|
a3c0b190d1 | ||
|
|
9e1c5a32a3 | ||
|
|
4cbde95247 | ||
|
|
a3af52c11e | ||
|
|
d0a54af4c5 | ||
|
|
f20a62b164 | ||
|
|
f58f7f4e67 | ||
|
|
66832decc5 | ||
|
|
bbe1f9d280 | ||
|
|
7154c617bf | ||
|
|
6aba1816ee | ||
|
|
3eafc3d329 | ||
|
|
937e9f801d | ||
|
|
4ce11c2a63 | ||
|
|
012e5bf4cd | ||
|
|
ab34dafb69 | ||
|
|
9ee0707cfa | ||
|
|
6abf54a489 | ||
|
|
55a299075b | ||
|
|
17683295e4 | ||
|
|
bd0aaa0198 | ||
|
|
66fbae9d75 | ||
|
|
2994c23670 | ||
|
|
eb83ca1cd3 | ||
|
|
15afc78f85 | ||
|
|
b01f5b35f5 | ||
|
|
58c05c04f4 | ||
|
|
d1ce095f84 | ||
|
|
b09703e921 | ||
|
|
ca0d712c3c | ||
|
|
d72347f7bc | ||
|
|
6190512876 | ||
|
|
3f666e1dfe | ||
|
|
bb6aa3ebd3 | ||
|
|
7cf9dfe237 | ||
|
|
d66e492c3d | ||
|
|
72e366657b | ||
|
|
c7c71b8530 | ||
|
|
3cfdbdbd12 | ||
|
|
c6fb5f38c0 | ||
|
|
7d8d573f0d | ||
|
|
f5fae65194 | ||
|
|
bde40a73db | ||
|
|
ee372651d0 | ||
|
|
860c3a5a32 | ||
|
|
6c3e2b32bf | ||
|
|
ef7cb6880f | ||
|
|
4bfba57f96 | ||
|
|
40ad5745a7 | ||
|
|
e9f5066faa | ||
|
|
2e3ae884fb | ||
|
|
2196bda958 | ||
|
|
ab6a987f86 | ||
|
|
ee72c31788 | ||
|
|
2fae8d37c0 | ||
|
|
bcd9356df5 | ||
|
|
950de07889 | ||
|
|
20c3b72bf0 | ||
|
|
039c69da18 | ||
|
|
06c57b7d55 | ||
|
|
b935f6f13a | ||
|
|
7901a6dbef | ||
|
|
b45292a819 | ||
|
|
59087fee52 | ||
|
|
fc8d9584b1 | ||
|
|
bd8df0b32a | ||
|
|
4e03ce9fc5 | ||
|
|
f4248e51a4 | ||
|
|
f74f26f487 | ||
|
|
c23052d6d2 | ||
|
|
7a652e397b | ||
|
|
f496bf9dda | ||
|
|
da6e561d2b | ||
|
|
3756201e04 | ||
|
|
916ad6c8f7 | ||
|
|
8768ab94b3 | ||
|
|
673dc5ee5f | ||
|
|
c1cb5e6885 | ||
|
|
8c7f03c8a4 | ||
|
|
0a1ba06e5d | ||
|
|
c83472edf1 | ||
|
|
d23ad35375 | ||
|
|
ae07423bcd | ||
|
|
9c2183f622 | ||
|
|
911355bee8 | ||
|
|
de8052aa41 | ||
|
|
279e4f7219 | ||
|
|
7cb0480d04 | ||
|
|
16177d63f2 | ||
|
|
c60079862b | ||
|
|
a8a55dc086 | ||
|
|
4ec16344a9 | ||
|
|
a8c0463961 | ||
|
|
5b6cc7d96c | ||
|
|
e20b4ab640 | ||
|
|
b6b6ec2a97 | ||
|
|
c230f7defb | ||
|
|
22efcfd530 | ||
|
|
6357acc086 | ||
|
|
0a5d10a5b9 | ||
|
|
02aad34c43 | ||
|
|
7eb04b7907 | ||
|
|
046bff25fb | ||
|
|
559c624806 | ||
|
|
30dc899c2e | ||
|
|
ea80259eb3 | ||
|
|
49f673979b | ||
|
|
128119b9ab | ||
|
|
6f5b9894a2 | ||
|
|
820b5aa9e4 | ||
|
|
28dfe0dfd9 | ||
|
|
1cbe552f4d | ||
|
|
d79e01e211 | ||
|
|
37661c8b39 | ||
|
|
efcd3e318b | ||
|
|
bc9fc0d6cf | ||
|
|
0242b892d2 | ||
|
|
d61e8d63fd | ||
|
|
5db70599d1 | ||
|
|
4250a26f5c | ||
|
|
40666b6708 | ||
|
|
5d1cf6a544 | ||
|
|
6dec77d25e | ||
|
|
4a400ce14f | ||
|
|
ac48d5d24f | ||
|
|
0626f6ca0a | ||
|
|
40a3cdd97b | ||
|
|
131033352d | ||
|
|
2ad81f4584 | ||
|
|
22f2b206b7 | ||
|
|
52e1590285 | ||
|
|
c2ec68ab62 | ||
|
|
26b8b65c18 | ||
|
|
14594953d2 | ||
|
|
da9abd8b73 | ||
|
|
d69ab24f69 | ||
|
|
13af4c9a09 | ||
|
|
b15e33f85a | ||
|
|
d0ea27b802 | ||
|
|
419a9c6cac | ||
|
|
5a606e0be3 | ||
|
|
b4dd85ff46 | ||
|
|
7a05927e44 | ||
|
|
63dae4ee74 | ||
|
|
6543134dea | ||
|
|
cdbe4a5cab | ||
|
|
3b3f8137c3 | ||
|
|
4320984303 | ||
|
|
8b443a1851 | ||
|
|
b81012c718 | ||
|
|
bd196f4bd0 | ||
|
|
93608bf8a5 | ||
|
|
fc34aa8489 | ||
|
|
e678e7a6af | ||
|
|
e8ec9a98dd | ||
|
|
51e3beb4cb | ||
|
|
934e19107d | ||
|
|
c37b13e0db | ||
|
|
9aebeaaf09 | ||
|
|
b3a48855ab | ||
|
|
331726338b | ||
|
|
497fae9d1f | ||
|
|
ef08c58664 | ||
|
|
339b4dbd6f | ||
|
|
ab6a675131 | ||
|
|
426fb96cc9 | ||
|
|
36d62a2f84 | ||
|
|
0b9f9de012 | ||
|
|
85ad81736c | ||
|
|
1ea0bae9c0 | ||
|
|
57f76446cf | ||
|
|
0f3d8acfd6 | ||
|
|
46ae03d872 | ||
|
|
7241dea7ef | ||
|
|
b6307d1014 | ||
|
|
4e3cd72df5 | ||
|
|
244c9a4ba0 | ||
|
|
c0c096b752 | ||
|
|
366832fbd2 | ||
|
|
4e4b98a66d | ||
|
|
dc0db7382c | ||
|
|
350aec954e | ||
|
|
7107105429 | ||
|
|
17f504a0ec | ||
|
|
70331c361e | ||
|
|
2256ec00ef | ||
|
|
2618322506 | ||
|
|
268ac81e39 | ||
|
|
1d3f0d8891 | ||
|
|
c2d53719c2 | ||
|
|
bb2f034eff | ||
|
|
363b0ce10b | ||
|
|
0a865c89c5 | ||
|
|
94ab6069b8 | ||
|
|
dfdd1e4caf | ||
|
|
2814b749ec | ||
|
|
7aa61c312d | ||
|
|
fb81446ec9 | ||
|
|
aae30f20fc | ||
|
|
8e49bacf95 | ||
|
|
a570981151 | ||
|
|
f5117c81b3 | ||
|
|
a420b562df | ||
|
|
c13c6e4f68 | ||
|
|
4dbac17f9c |
No files matched your search
@@ -1,8 +1,7 @@
|
||||
set $zts = 0
|
||||
|
||||
define ____executor_globals
|
||||
if $zts
|
||||
set $eg = ((zend_executor_globals) (*((void ***) tsrm_ls))[executor_globals_id-1])
|
||||
if basic_functions_module.zts
|
||||
set $tsrm_ls = ts_resource_ex(0, 0)
|
||||
set $eg = ((zend_executor_globals) (*((void ***) $tsrm_ls))[executor_globals_id-1])
|
||||
else
|
||||
set $eg = executor_globals
|
||||
end
|
||||
@@ -10,7 +9,7 @@ end
|
||||
|
||||
document ____executor_globals
|
||||
portable way of accessing executor_globals
|
||||
type "set $zts = 1" if you use --enable-maintainer-zts on your configure line
|
||||
ZTS detection is automatically based on ext/standard module struct
|
||||
end
|
||||
|
||||
define dump_bt
|
||||
@@ -44,55 +43,33 @@ document printzv
|
||||
end
|
||||
|
||||
define ____printzv_contents
|
||||
____executor_globals
|
||||
set $zvalue = $arg0
|
||||
set $type = $zvalue->type
|
||||
|
||||
if $zvalue.type == 0
|
||||
set $typename = "NULL"
|
||||
printf "(refcount=%d) ", $zvalue->refcount
|
||||
if $type == 0
|
||||
printf "NULL"
|
||||
end
|
||||
if $zvalue.type == 1
|
||||
set $typename = "long"
|
||||
if $type == 1
|
||||
printf "long: %ld", $zvalue->value.lval
|
||||
end
|
||||
if $zvalue.type == 2
|
||||
set $typename = "double"
|
||||
if $type == 2
|
||||
printf "double: %lf", $zvalue->value.dval
|
||||
end
|
||||
if $zvalue.type == 3
|
||||
set $typename = "string"
|
||||
if $type == 3
|
||||
printf "bool: "
|
||||
if $zvalue->value.lval
|
||||
printf "true"
|
||||
else
|
||||
printf "false"
|
||||
end
|
||||
end
|
||||
if $zvalue.type == 4
|
||||
set $typename = "array"
|
||||
end
|
||||
if $zvalue.type == 5
|
||||
set $typename = "object"
|
||||
end
|
||||
if $zvalue.type == 6
|
||||
set $typename = "bool"
|
||||
end
|
||||
if $zvalue.type == 7
|
||||
set $typename = "resource"
|
||||
end
|
||||
if $zvalue.type == 8
|
||||
set $typename = "constant"
|
||||
end
|
||||
if $zvalue.type == 9
|
||||
set $typename = "const_array"
|
||||
end
|
||||
|
||||
printf "(refcount=%d) %s: ", $zvalue.refcount, $typename
|
||||
if $zvalue.type == 1
|
||||
printf "%ld", $zvalue.value.lval
|
||||
end
|
||||
if $zvalue->type == 2
|
||||
printf "%lf", $zvalue.value.dval
|
||||
end
|
||||
if $zvalue.type == 3
|
||||
printf "\"%s\"(%d)", $zvalue.value.str.val, $zvalue.value.str.len
|
||||
end
|
||||
if $zvalue.type == 4
|
||||
if $type == 4
|
||||
printf "array(%d): ", $zvalue->value.ht->nNumOfElements
|
||||
if ! $arg1
|
||||
printf "{\n"
|
||||
set $ind = $ind + 1
|
||||
____print_ht $zvalue.value.ht
|
||||
____print_ht $zvalue->value.ht
|
||||
set $ind = $ind - 1
|
||||
set $i = $ind
|
||||
while $i > 0
|
||||
@@ -101,34 +78,61 @@ define ____printzv_contents
|
||||
end
|
||||
printf "}"
|
||||
end
|
||||
set $type = 0
|
||||
end
|
||||
if $zvalue.type == 5
|
||||
if $type == 5
|
||||
printf "object"
|
||||
____executor_globals
|
||||
set $handle = $zvalue->value.obj.handle
|
||||
set $handlers = $zvalue->value.obj.handlers
|
||||
if basic_functions_module.zts
|
||||
set $zobj = zend_objects_get_address($zvalue, $tsrm_ls)
|
||||
else
|
||||
set $zobj = zend_objects_get_address($zvalue)
|
||||
end
|
||||
if $handlers->get_class_entry == &zend_std_object_get_class
|
||||
set $cname = $zobj->ce.name
|
||||
else
|
||||
set $cname = "Unknown"
|
||||
end
|
||||
printf "(%s) #%d", $cname, $handle
|
||||
if ! $arg1
|
||||
printf "(prop examination disabled due to a gdb bug)"
|
||||
if $zvalue.value.obj.handlers->get_properties
|
||||
# set $ht = $zvalue->value.obj.handlers->get_properties($zvalue)
|
||||
# printf "{\n"
|
||||
# set $ind = $ind + 1
|
||||
# ____print_ht $ht
|
||||
# set $ind = $ind - 1
|
||||
# set $i = $ind
|
||||
# while $i > 0
|
||||
# printf " "
|
||||
# set $i = $i - 1
|
||||
# end
|
||||
# printf "}"
|
||||
if $handlers->get_properties == &zend_std_get_properties
|
||||
set $ht = $zobj->properties
|
||||
if $ht
|
||||
printf "(%d): ", $ht->nNumOfElements
|
||||
printf "{\n"
|
||||
set $ind = $ind + 1
|
||||
____print_ht $ht
|
||||
set $ind = $ind - 1
|
||||
set $i = $ind
|
||||
while $i > 0
|
||||
printf " "
|
||||
set $i = $i - 1
|
||||
end
|
||||
printf "}"
|
||||
else
|
||||
echo "no properties found"
|
||||
end
|
||||
end
|
||||
end
|
||||
set $type = 0
|
||||
end
|
||||
if $zvalue.type == 6
|
||||
if $zvalue.value.lval
|
||||
printf "true"
|
||||
else
|
||||
printf "false"
|
||||
end
|
||||
if $type == 6
|
||||
printf "string(%d): ", $zvalue->value.str.len
|
||||
____print_str $zvalue->value.str.val $zvalue->value.str.len
|
||||
end
|
||||
if $zvalue.type == 7
|
||||
printf "#%d", $zvalue.value.lval
|
||||
if $type == 7
|
||||
printf "resource: #%d", $zvalue->value.lval
|
||||
end
|
||||
if $type == 8
|
||||
printf "constant"
|
||||
end
|
||||
if $type == 9
|
||||
printf "const_array"
|
||||
end
|
||||
if $type > 9
|
||||
printf "unknown type %d", $type
|
||||
end
|
||||
printf "\n"
|
||||
end
|
||||
@@ -143,7 +147,7 @@ define ____printzv
|
||||
printf "*uninitialized* "
|
||||
end
|
||||
|
||||
set $zcontents = *(struct _zval_struct *) $zvalue
|
||||
set $zcontents = (zval*) $zvalue
|
||||
if $arg1
|
||||
____printzv_contents $zcontents $arg1
|
||||
else
|
||||
@@ -156,7 +160,7 @@ define ____print_const_table
|
||||
set $p = $ht->pListHead
|
||||
|
||||
while $p != 0
|
||||
set $const = *(zend_constant *) $p->pData
|
||||
set $const = (zend_constant *) $p->pData
|
||||
|
||||
set $i = $ind
|
||||
while $i > 0
|
||||
@@ -164,13 +168,14 @@ define ____print_const_table
|
||||
set $i = $i - 1
|
||||
end
|
||||
|
||||
if $p->nKeyLength > 0
|
||||
printf "\"%s\" => ", $p->arKey
|
||||
if $p->nKeyLength > 0
|
||||
____print_str $p->arKey $p->nKeyLength
|
||||
printf " => "
|
||||
else
|
||||
printf "%d => ", $p->h
|
||||
end
|
||||
|
||||
____printzv_contents $const.value 0
|
||||
____printzv_contents &$const->value 0
|
||||
set $p = $p->pListNext
|
||||
end
|
||||
end
|
||||
@@ -187,7 +192,7 @@ define ____print_ht
|
||||
set $p = $ht->pListHead
|
||||
|
||||
while $p != 0
|
||||
set $zval = *(struct _zval_struct **)$p->pData
|
||||
set $zval = *(zval **)$p->pData
|
||||
|
||||
set $i = $ind
|
||||
while $i > 0
|
||||
@@ -195,8 +200,9 @@ define ____print_ht
|
||||
set $i = $i - 1
|
||||
end
|
||||
|
||||
if $p->nKeyLength > 0
|
||||
printf "\"%s\" => ", $p->arKey
|
||||
if $p->nKeyLength > 0
|
||||
____print_str $p->arKey $p->nKeyLength
|
||||
printf " => "
|
||||
else
|
||||
printf "%d => ", $p->h
|
||||
end
|
||||
@@ -217,6 +223,149 @@ document print_ht
|
||||
dumps elements of HashTable made of zval
|
||||
end
|
||||
|
||||
define ____print_ft
|
||||
set $ht = $arg0
|
||||
set $p = $ht->pListHead
|
||||
|
||||
while $p != 0
|
||||
set $func = (zend_function*)$p->pData
|
||||
|
||||
set $i = $ind
|
||||
while $i > 0
|
||||
printf " "
|
||||
set $i = $i - 1
|
||||
end
|
||||
|
||||
if $p->nKeyLength > 0
|
||||
____print_str $p->arKey $p->nKeyLength
|
||||
printf " => "
|
||||
else
|
||||
printf "%d => ", $p->h
|
||||
end
|
||||
|
||||
printf "\"%s\"\n", $func->common.function_name
|
||||
set $p = $p->pListNext
|
||||
end
|
||||
end
|
||||
|
||||
define print_ft
|
||||
set $ind = 1
|
||||
printf "[0x%08x] {\n", $arg0
|
||||
____print_ft $arg0
|
||||
printf "}\n"
|
||||
end
|
||||
|
||||
document print_ft
|
||||
dumps a function table (HashTable)
|
||||
end
|
||||
|
||||
define ____print_inh_class
|
||||
set $ce = $arg0
|
||||
if $ce->ce_flags & 0x10 || $ce->ce_flags & 0x20
|
||||
printf "abstract "
|
||||
else
|
||||
if $ce->ce_flags & 0x40
|
||||
printf "final "
|
||||
end
|
||||
end
|
||||
printf "class %s", $ce->name
|
||||
if $ce->parent != 0
|
||||
printf " extends %s", $ce->parent->name
|
||||
end
|
||||
if $ce->num_interfaces != 0
|
||||
printf " implements"
|
||||
set $tmp = 0
|
||||
while $tmp < $ce->num_interfaces
|
||||
printf " %s", $ce->interfaces[$tmp]->name
|
||||
set $tmp = $tmp + 1
|
||||
if $tmp < $ce->num_interfaces
|
||||
printf ","
|
||||
end
|
||||
end
|
||||
end
|
||||
set $ce = $ce->parent
|
||||
end
|
||||
|
||||
define ____print_inh_iface
|
||||
set $ce = $arg0
|
||||
printf "interface %s", $ce->name
|
||||
if $ce->num_interfaces != 0
|
||||
set $ce = $ce->interfaces[0]
|
||||
printf " extends %s", $ce->name
|
||||
else
|
||||
set $ce = 0
|
||||
end
|
||||
end
|
||||
|
||||
define print_inh
|
||||
set $ce = $arg0
|
||||
set $depth = 0
|
||||
while $ce != 0
|
||||
set $tmp = $depth
|
||||
while $tmp != 0
|
||||
printf " "
|
||||
set $tmp = $tmp - 1
|
||||
end
|
||||
set $depth = $depth + 1
|
||||
if $ce->ce_flags & 0x80
|
||||
____print_inh_iface $ce
|
||||
else
|
||||
____print_inh_class $ce
|
||||
end
|
||||
printf " {\n"
|
||||
end
|
||||
while $depth != 0
|
||||
set $tmp = $depth
|
||||
while $tmp != 1
|
||||
printf " "
|
||||
set $tmp = $tmp - 1
|
||||
end
|
||||
printf "}\n"
|
||||
set $depth = $depth - 1
|
||||
end
|
||||
end
|
||||
|
||||
define print_pi
|
||||
set $pi = $arg0
|
||||
printf "[0x%08x] {\n", $pi
|
||||
printf " h = %lu\n", $pi->h
|
||||
printf " flags = %d (", $pi->flags
|
||||
if $pi->flags & 0x100
|
||||
printf "ZEND_ACC_PUBLIC"
|
||||
else
|
||||
if $pi->flags & 0x200
|
||||
printf "ZEND_ACC_PROTECTED"
|
||||
else
|
||||
if $pi->flags & 0x400
|
||||
printf "ZEND_ACC_PRIVATE"
|
||||
else
|
||||
if $pi->flags & 0x800
|
||||
printf "ZEND_ACC_CHANGED"
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
printf ")\n"
|
||||
printf " name = "
|
||||
____print_str $pi->name $pi->name_length
|
||||
printf "\n}\n"
|
||||
end
|
||||
|
||||
define ____print_str
|
||||
set $tmp = 0
|
||||
set $str = $arg0
|
||||
printf "\""
|
||||
while $tmp < $arg1
|
||||
if $str[$tmp] > 32 && $str[$tmp] < 127
|
||||
printf "%c", $str[$tmp]
|
||||
else
|
||||
printf "\\%o", $str[$tmp]
|
||||
end
|
||||
set $tmp = $tmp + 1
|
||||
end
|
||||
printf "\""
|
||||
end
|
||||
|
||||
define printzn
|
||||
____executor_globals
|
||||
set $ind = 0
|
||||
|
||||
+12
-7
@@ -148,20 +148,19 @@ Naming Conventions
|
||||
'buildsomewidget'
|
||||
'getI()'
|
||||
|
||||
[7] Classes should be given descriptive names. Avoid using abbreviations
|
||||
where possible. Each word in the class name should start with a capital
|
||||
letter, with words underscore delimited. The class name should be prefixed
|
||||
with the name of the 'parent set'.
|
||||
[7] Classes should be given descriptive names. Avoid using abbreviations where
|
||||
possible. Each word in the class name should start with a capital letter,
|
||||
without underscore delimiters (CampelCaps starting with a capital letter).
|
||||
The class name should be prefixed with the name of the 'parent set' (e.g.
|
||||
the name of the extension).
|
||||
|
||||
Good:
|
||||
'Curl'
|
||||
'Foo_Bar'
|
||||
'FooBar'
|
||||
|
||||
Bad:
|
||||
'foobar'
|
||||
'foo_bar'
|
||||
'FooBar'
|
||||
|
||||
|
||||
Syntax and indentation
|
||||
----------------------
|
||||
@@ -208,6 +207,12 @@ Syntax and indentation
|
||||
indent preprocessor directives you should put the # at the beginning
|
||||
of a line, followed by any number of whitespace.
|
||||
|
||||
Testing
|
||||
-------
|
||||
|
||||
[1] Extensions should be well tested using *.phpt tests. Read about that
|
||||
in README.TESTING.
|
||||
|
||||
Documentation and Folding Hooks
|
||||
-------------------------------
|
||||
|
||||
|
||||
+13
-13
@@ -46,9 +46,9 @@ MAINTENANCE: Maintained
|
||||
STATUS: Experimental
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: apache2handler
|
||||
PRIMARY MAINTAINER: Aaron Bannert <aaron@php.net>
|
||||
PRIMARY MAINTAINER: Aaron Bannert <aaron@php.net>, Ilia Alshanetsky <iliaa@php.net>
|
||||
MAINTENANCE: Maintained
|
||||
STATUS: Experimental
|
||||
STATUS: Working
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: caudium
|
||||
MAINTENANCE: Unknown
|
||||
@@ -68,11 +68,6 @@ PRIMARY MAINTAINER: Alex Leigh <aleigh@php.net>
|
||||
MAINTENANCE: Unknown
|
||||
STATUS: Unknown
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: date
|
||||
PRIMARY MAINTAINER: Derick Rethans <derick@php.net>
|
||||
MAINTENANCE: Maintained
|
||||
STATUS: Working
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: embed
|
||||
PRIMARY MAINTAINER: Edin Kadribasic <edink@php.net>
|
||||
MAINTENANCE: Maintained
|
||||
@@ -176,9 +171,9 @@ MAINTENANCE: Maintained
|
||||
STATUS: Working
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: mysqli
|
||||
PRIMARY MAINTAINER: Georg Richter <georg@php.net>
|
||||
PRIMARY MAINTAINER: Georg Richter <georg@php.net>, Andrey Hristov <andrey@php.net>
|
||||
MAINTENANCE: Maintained
|
||||
STATUS: Experimental
|
||||
STATUS: Working
|
||||
SINCE: 5.0
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: oci8
|
||||
@@ -302,11 +297,16 @@ MAINTENANCE: Maintained
|
||||
STATUS: Working
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: curl
|
||||
PRIMARY MAINTAINER: Sterling Hughes <sterling@php.net>
|
||||
PRIMARY MAINTAINER: Sterling Hughes <sterling@php.net>,Ilia Alshanetsky <iliaa@php.net>
|
||||
MAINTENANCE: Maintained
|
||||
STATUS: Working
|
||||
SINCE: 4.0.2
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: date
|
||||
PRIMARY MAINTAINER: Derick Rethans <derick@php.net>
|
||||
MAINTENANCE: Maintained
|
||||
STATUS: Working
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: exif
|
||||
PRIMARY MAINTAINER: Marcus Boerger <helly@php.net>
|
||||
MAINTENANCE: Maintained
|
||||
@@ -357,8 +357,8 @@ MAINTENANCE: Maintained
|
||||
STATUS: Working
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: imap
|
||||
PRIMARY MAINTAINER: Chuck Hagenbuch <chuck@horde.org>
|
||||
MAINTENANCE: Odd Fixes
|
||||
PRIMARY MAINTAINER: Chuck Hagenbuch <chuck@horde.org>, Ilia Alshanetsky <iliaa@php.net>
|
||||
MAINTENANCE: Maintained
|
||||
STATUS: Working
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: ircg
|
||||
@@ -465,7 +465,7 @@ MAINTENANCE: Maintained
|
||||
STATUS: Working
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: session
|
||||
PRIMARY MAINTAINER: Sascha Schumann <sascha@schumann.cx>
|
||||
PRIMARY MAINTAINER: Sascha Schumann <sascha@schumann.cx>, Ilia Alshanetsky <iliaa@php.net>
|
||||
MAINTENANCE: Maintained
|
||||
STATUS: Working
|
||||
-------------------------------------------------------------------------------
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
|
||||
Installing PHP
|
||||
_________________________________________________________________
|
||||
|
||||
@@ -17,6 +16,7 @@ Installing PHP
|
||||
OpenBSD installation notes
|
||||
Solaris specific installation tips
|
||||
Gentoo installation notes
|
||||
Debian GNU/Linux installation notes
|
||||
|
||||
3. Installation on Mac OS X
|
||||
|
||||
@@ -43,6 +43,8 @@ Installing PHP
|
||||
|
||||
The configuration file
|
||||
How to change configuration settings
|
||||
|
||||
7. Installation FAQ
|
||||
_________________________________________________________________
|
||||
|
||||
Preface
|
||||
@@ -164,7 +166,7 @@ Apache 1.3.x on Unix systems
|
||||
your files.
|
||||
|
||||
Example 2-1. Installation Instructions (Apache Shared Module Version)
|
||||
for PHP
|
||||
for PHP
|
||||
1. gunzip apache_xxx.tar.gz
|
||||
2. tar -xvf apache_xxx.tar
|
||||
3. gunzip php-xxx.tar.gz
|
||||
@@ -248,14 +250,14 @@ Apache 1.3.x on Unix systems
|
||||
Alternatively, to install PHP as a static object:
|
||||
|
||||
Example 2-2. Installation Instructions (Static Module Installation for
|
||||
Apache) for PHP
|
||||
Apache) for PHP
|
||||
1. gunzip -c apache_1.3.x.tar.gz | tar xf -
|
||||
2. cd apache_1.3.x
|
||||
3. ./configure
|
||||
4. cd ..
|
||||
|
||||
5. gunzip -c php-4.x.y.tar.gz | tar xf -
|
||||
6. cd php-4.x.y
|
||||
5. gunzip -c php-5.x.y.tar.gz | tar xf -
|
||||
6. cd php-5.x.y
|
||||
7. ./configure --with-mysql --with-apache=../apache_1.3.x
|
||||
8. make
|
||||
9. make install
|
||||
@@ -269,15 +271,17 @@ Apache 1.3.x on Unix systems
|
||||
12. make
|
||||
(you should now have an httpd binary which you can copy to your Apache bin
|
||||
dir if
|
||||
is is your first install then you need to "make install" as well)
|
||||
it is your first install then you need to "make install" as well)
|
||||
|
||||
13. cd ../php-4.x.y
|
||||
13. cd ../php-5.x.y
|
||||
14. cp php.ini-dist /usr/local/lib/php.ini
|
||||
|
||||
15. You can edit /usr/local/lib/php.ini file to set PHP options.
|
||||
Edit your httpd.conf or srm.conf file and add:
|
||||
AddType application/x-httpd-php .php
|
||||
|
||||
Note: Replace php-5 by php-4 and php5 by php4 in PHP 4.
|
||||
|
||||
Depending on your Apache install and Unix variant, there are many
|
||||
possible ways to stop and restart the server. Below are some typical
|
||||
lines used in restarting the server, for different apache/unix
|
||||
@@ -309,13 +313,13 @@ stop and start:
|
||||
|
||||
./configure --with-apxs --with-pgsql
|
||||
|
||||
This will create a libphp5.so shared library that is loaded into
|
||||
Apache using a LoadModule line in Apache's httpd.conf file. The
|
||||
PostgreSQL support is embedded into this libphp5.so library.
|
||||
This will create a libphp5.so (or libphp4.so in PHP 4) shared library
|
||||
that is loaded into Apache using a LoadModule line in Apache's
|
||||
httpd.conf file. The PostgreSQL support is embedded into this library.
|
||||
|
||||
./configure --with-apxs --with-pgsql=shared
|
||||
|
||||
This will create a libphp5.so shared library for Apache, but it will
|
||||
This will create a libphp4.so shared library for Apache, but it will
|
||||
also create a pgsql.so shared library that is loaded into PHP either
|
||||
by using the extension directive in php.ini file or by loading it
|
||||
explicitly in a script using the dl() function.
|
||||
@@ -327,9 +331,9 @@ stop and start:
|
||||
in the Apache source tree. Then you compile Apache using
|
||||
--activate-module=src/modules/php5/libphp5.a and the Apache build
|
||||
system will create libphp5.a and link it statically into the httpd
|
||||
binary. The PostgreSQL support is included directly into this httpd
|
||||
binary, so the final result here is a single httpd binary that
|
||||
includes all of Apache and all of PHP.
|
||||
binary (replace php5 by php4 in PHP 4). The PostgreSQL support is
|
||||
included directly into this httpd binary, so the final result here is
|
||||
a single httpd binary that includes all of Apache and all of PHP.
|
||||
|
||||
./configure --with-apache=/path/to/apache_source --with-pgsql=shared
|
||||
|
||||
@@ -403,7 +407,7 @@ Apache 2.0 on Unix systems
|
||||
files.
|
||||
|
||||
Example 2-4. Installation Instructions (Apache 2 Shared Module
|
||||
Version)
|
||||
Version)
|
||||
1. gzip -d httpd-2_0_NN.tar.gz
|
||||
2. tar xvf httpd-2_0_NN.tar
|
||||
3. gunzip php-NN.tar.gz
|
||||
@@ -461,11 +465,11 @@ Apache 2.0 on Unix systems
|
||||
|
||||
For PHP 4:
|
||||
|
||||
LoadModule php4_module libexec/libphp4.so
|
||||
LoadModule php4_module modules/libphp4.so
|
||||
|
||||
For PHP 5:
|
||||
|
||||
LoadModule php5_module libexec/libphp5.so
|
||||
LoadModule php5_module modules/libphp5.so
|
||||
|
||||
15. Tell Apache to parse certain extensions as PHP. For example,
|
||||
let's have Apache parse the .php extension as PHP. You could
|
||||
@@ -1097,6 +1101,121 @@ Common Problems
|
||||
"Apache PHP".
|
||||
_________________________________________________________________
|
||||
|
||||
Debian GNU/Linux installation notes
|
||||
|
||||
This section contains notes and hints specific to installing PHP on
|
||||
Debian GNU/Linux.
|
||||
_________________________________________________________________
|
||||
|
||||
Using APT
|
||||
|
||||
While you can just download the PHP source and compile it yourself,
|
||||
using Debian's packaging system is the simplest and cleanest method of
|
||||
installing PHP. If you are not familiar with building software on
|
||||
Linux, this is the way to go.
|
||||
|
||||
The first decision you need to make is whether you want to install
|
||||
Apache 1.3.x or Apache 2.x. The corresponding PHP packages are
|
||||
respectively named libapache-mod-php* and libapache2-mod-php*. The
|
||||
steps given below will use Apache 1.3.x. Please note that, as of this
|
||||
writing, there is no official Debian packages of PHP 5. Then the steps
|
||||
given below will install PHP 4.
|
||||
|
||||
PHP is available in Debian as CGI or CLI flavour too, named
|
||||
respectively php4-cgi and php4-cli. If you need them, you'll just have
|
||||
to reproduce the following steps with the good package names. Another
|
||||
special package you'd want to install is php4-pear. It contains a
|
||||
minimal PEAR installation and the pear commandline utility.
|
||||
|
||||
If you need more recent packages of PHP than the Debian's stable ones
|
||||
or if some PHP modules lacks the Debian official repository, perhaps
|
||||
you should take a look at http://www.apt-get.org/. One of the results
|
||||
found should be Dotdeb. This unofficial repository is maintained by
|
||||
Guillaume Plessis and contains Debian packages of the most recent
|
||||
versions of PHP 4 and PHP 5. To use it, just add the to following two
|
||||
lines to your /etc/apt/sources.lists and run apt-get update :
|
||||
|
||||
Example 2-10. The two Dotdeb related lines
|
||||
deb http://packages.dotdeb.org stable all
|
||||
deb-src http://packages.dotdeb.org stable all
|
||||
|
||||
The last thing to consider is whether your list of packages is up to
|
||||
date. If you have not updated it recently, you need to run apt-get
|
||||
update before anything else. This way, you will be using the most
|
||||
recent stable version of the Apache and PHP packages.
|
||||
|
||||
Now that everything is in place, you can use the following example to
|
||||
install Apache and PHP:
|
||||
|
||||
Example 2-11. Debian Install Example with Apache 1.3
|
||||
# apt-get install libapache-mod-php4
|
||||
|
||||
APT will automatically install the PHP 4 module for Apache 1.3, and
|
||||
all its dependencies and then activate it. If you're not asked to
|
||||
restart Apache during the install process, you'll have to do it
|
||||
manually :
|
||||
|
||||
Example 2-12. Stopping and starting Apache once PHP 4 is installed
|
||||
# /etc/init.d/apache stop
|
||||
# /etc/init.d/apache start
|
||||
_________________________________________________________________
|
||||
|
||||
Better control on configuration
|
||||
|
||||
In the last section, PHP was installed with only core modules. This
|
||||
may not be what you want and you will soon discover that you need more
|
||||
activated modules, like MySQL, cURL, GD, etc.
|
||||
|
||||
When you compile PHP from source yourself, you need to activate
|
||||
modules via the configure command. With APT, you just have to install
|
||||
additional packages. They're all named 'php4-*' (or 'php5-*' if you
|
||||
installed PHP 5 from a third party repository).
|
||||
|
||||
Example 2-13. Getting the list of PHP additional packages
|
||||
# dpkg -l 'php4-*'
|
||||
|
||||
As you can see from the last output, there's a lot of PHP modules that
|
||||
you can install (excluding the php4-cgi, php4-cli or php4-pear special
|
||||
packages). Look at them closely and choose what you need. If you
|
||||
choose a module and you do not have the proper libraries, APT will
|
||||
automatically install all the dependencies for you.
|
||||
|
||||
If you choose to add the MySQL, cURL and GD support to PHP the command
|
||||
will look something like this:
|
||||
|
||||
Example 2-14. Install PHP with MySQL, cURL and GD
|
||||
# apt-get install php4-mysql php4-curl php4-gd
|
||||
|
||||
APT will automatically add the appropriate lines to your different
|
||||
php.ini (/etc/php4/apache/php.ini, /etc/php4/cgi/php.ini, etc).
|
||||
|
||||
Example 2-15. These lines activate MySQL, cURL and GD into PHP
|
||||
extension=mysql.so
|
||||
extension=curl.so
|
||||
extension=gd.so
|
||||
|
||||
You'll only have to stop/start Apache as previously to activate the
|
||||
modules.
|
||||
_________________________________________________________________
|
||||
|
||||
Common Problems
|
||||
|
||||
* If you see the PHP source instead of the result the script should
|
||||
produce, APT has probably not included /etc/apache/conf.d/php4 in
|
||||
your Apache 1.3 configuration. Please ensure that the following
|
||||
line is present in your /etc/apache/httpd.conf file then
|
||||
stop/start Apache:
|
||||
|
||||
Example 2-16. This line activates PHP 4 into Apache
|
||||
# Include /etc/apache/conf.d/
|
||||
|
||||
* If you installed an additional module and if its functions are not
|
||||
available in your scripts, please ensure that the appropriate line
|
||||
is present in your php.ini, as seen before. APT may fail during
|
||||
the installation of the additional module, due to a confusing
|
||||
debconf configuration.
|
||||
_________________________________________________________________
|
||||
|
||||
Chapter 3. Installation on Mac OS X
|
||||
|
||||
This section contains notes and hints specific to installing PHP on
|
||||
@@ -1119,7 +1238,7 @@ Using Packages
|
||||
|
||||
Compiling for OS X Server
|
||||
|
||||
Mac OS X Server install.
|
||||
Mac OS X Server install.
|
||||
|
||||
1. Get the latest distributions of Apache and PHP.
|
||||
2. Untar them, and run the configure program on Apache like so.
|
||||
@@ -1221,24 +1340,24 @@ Chapter 4. Installation of PECL extensions
|
||||
|
||||
Introduction to PECL Installations
|
||||
|
||||
PHP extensions may be installed in a variety of ways. PECL is a
|
||||
repository of PHP extensions living within the PEAR structure, and the
|
||||
following demonstrates how to install these extensions.
|
||||
PECL is a repository of PHP extensions that are made available to you
|
||||
via the PEAR packaging system. This section of the manual is intended
|
||||
to demonstrate how to obtain and install PECL extensions.
|
||||
|
||||
These instructions assume /your/phpsrcdir/ is the path to the PHP
|
||||
source, and extname is the name of the PECL extension. Adjust
|
||||
accordingly. These instructions also assume a familiarity with the
|
||||
pear command.
|
||||
source distribution, and that extname is the name of the PECL
|
||||
extension. Adjust accordingly. These instructions also assume a
|
||||
familiarity with the pear command.
|
||||
|
||||
Shared extensions may be installed by including them inside of php.ini
|
||||
using the extension PHP directive. See also the extensions_dir
|
||||
directive, and dl(). The installation methods described below do not
|
||||
automatically configure PHP to include these extensions, this step
|
||||
must be done manually.
|
||||
To be useful, a shared extension must be built, installed, and loaded.
|
||||
The methods described below provide you with various instructions on
|
||||
how to build and install the extensions, but they do not automatically
|
||||
load them. Extensions can be loaded by adding an extension directive.
|
||||
To this php.ini file, or through the use of the dl() function.
|
||||
|
||||
When building PHP modules, it's important to have the appropriate
|
||||
versions of the required tools (autoconf, automake, libtool, etc.) See
|
||||
the Anonymous CVS Instructions for details on the required tools, and
|
||||
When building PHP modules, it's important to have known-good versions
|
||||
of the required tools (autoconf, automake, libtool, etc.) See the
|
||||
Anonymous CVS Instructions for details on the required tools, and
|
||||
required versions.
|
||||
_________________________________________________________________
|
||||
|
||||
@@ -1247,16 +1366,19 @@ Downloading PECL extensions
|
||||
There are several options for downloading PECL extensions, such as:
|
||||
|
||||
* http://pecl.php.net
|
||||
Listed here is information like the ChangeLog, release
|
||||
information, requirements, revisions, etc. Although not every PECL
|
||||
extension has a webpage, most do.
|
||||
The PECL web site contains information about the different
|
||||
extensions that are offered by the PHP Development Team. The
|
||||
information available here includes: ChangeLog, release notes,
|
||||
requirements and other similar details.
|
||||
* pear download extname
|
||||
The pear command may also be used to download source files.
|
||||
PECL extensions that have releases listed on the PECL web site are
|
||||
available for download and installation using the pear command.
|
||||
Specific revisions may also be specified.
|
||||
* CVS
|
||||
All PECL files reside in CVS. A web-based view may be seen at
|
||||
http://cvs.php.net/pecl/. To download straight from CVS, consider
|
||||
the following where phpfi is the password for user cvsread:
|
||||
Most PECL extensions also reside in CVS. A web-based view may be
|
||||
seen at http://cvs.php.net/pecl/. To download straight from CVS,
|
||||
the following sequence of commands may be used. Note that phpfi is
|
||||
the password for user cvsread:
|
||||
|
||||
$ cvs -d:pserver:cvsread@cvs.php.net:/repository login
|
||||
$ cvs -d:pserver:cvsread@cvs.php.net:/repository co pecl/extname
|
||||
@@ -1270,9 +1392,10 @@ $ cvs -d:pserver:cvsread@cvs.php.net:/repository co pecl/extname
|
||||
|
||||
PECL for Windows users
|
||||
|
||||
Like with any other PHP extension DLL, to install move the PECL
|
||||
extension DLLs into the extension_dir folder and include them within
|
||||
php.ini. For example:
|
||||
As with any other PHP extension DLL, installation is as simple as
|
||||
copying the PECL extension DLLs into the extension_dir folder and
|
||||
loading them from php.ini. For example, add the following line to your
|
||||
php.ini:
|
||||
|
||||
extension=php_extname.dll
|
||||
|
||||
@@ -1286,67 +1409,76 @@ Compiling shared PECL extensions with PEAR
|
||||
|
||||
$ pear install extname
|
||||
|
||||
That will download the source for extname, and compile it on the
|
||||
system. This results in an extname.so file that may then be included
|
||||
in php.ini
|
||||
This will download the source for extname, compile, and install
|
||||
extname.so into your extension_dir. extname.so may then be loaded via
|
||||
php.ini
|
||||
|
||||
In case the systems preferred_state is set higher than an available
|
||||
extname version, like it's set to stable and the extension is still in
|
||||
beta, either alter the preferred_state via pear config-set or specify
|
||||
a specific version of the PECL extension. For example:
|
||||
By default, the pear command will not install packages that are marked
|
||||
with the alpha or beta state. If no stable packages are available, you
|
||||
may install a beta package using the following command:
|
||||
|
||||
$ pear install extname-0.1.1
|
||||
$ pear install extname-beta
|
||||
|
||||
Regardless, pear will copy this extname.so into the extensions
|
||||
directory. Adjust php.ini accordingly.
|
||||
You may also install a specific version using this variant:
|
||||
|
||||
$ pear install extname-0.1
|
||||
_________________________________________________________________
|
||||
|
||||
Compiling shared PECL extensions with phpize
|
||||
|
||||
If using pear is not an option, like for building shared PECL
|
||||
extensions from CVS, or for unreleased PECL packages, then creating a
|
||||
shared extension may also be done by manually using the phpize
|
||||
command. The pear command essentially does this but it may also be
|
||||
done manually. Assuming the source file is named extname.tgz, and that
|
||||
it was downloaded into the current directory, consider the following:
|
||||
Sometimes, using the pear installer is not an option. This could be
|
||||
because you're behind a firewall, or it could be because the extension
|
||||
you want to install is not available as a PEAR compatible package,
|
||||
such as unreleased extensions from CVS. If you need to build such an
|
||||
extension, you can use the lower-level build tools to perform the
|
||||
build manually.
|
||||
|
||||
The phpize command is used to prepare the build environment for a PHP
|
||||
extension. In the following sample, the sources for an extension are
|
||||
in a directory named extname:
|
||||
|
||||
$ pear download extname
|
||||
$ gzip -d < extname.tgz | tar -xvf -
|
||||
$ cd extname
|
||||
$ phpize
|
||||
$ ./configure && make
|
||||
$ ./configure
|
||||
$ make
|
||||
# make install
|
||||
|
||||
Upon success, this will create extname.so and put it into the modules/
|
||||
and/or .libs/ directory within the extname/ source. Move this shared
|
||||
extension (extname.so) into the PHP extensions directory, and adjust
|
||||
php.ini accordingly.
|
||||
A successful install will have created extname.so and put it into the
|
||||
PHP extensions directory. You'll need to and adjust php.ini and add an
|
||||
extension=extname.so line before you can use the extension.
|
||||
_________________________________________________________________
|
||||
|
||||
Compiling PECL extensions statically into PHP
|
||||
|
||||
To statically include the extension within the PHP build, put the
|
||||
extensions source into the ext/ directory found in the PHP source. For
|
||||
example:
|
||||
You might find that you need to build a PECL extension statically into
|
||||
your PHP binary. To do this, you'll need to place the extension source
|
||||
under the php-src/ext/ directory and tell the PHP build system to
|
||||
regenerate its configure script.
|
||||
|
||||
$ cd /your/phpsrcdir/ext
|
||||
$ pear download extname
|
||||
$ gzip -d < extname.tgz | tar -xvf -
|
||||
$ mv extname-x.x.x extname
|
||||
$ rm package.xml
|
||||
|
||||
This will result in the following directory:
|
||||
|
||||
/your/phpsrcdir/ext/extname
|
||||
|
||||
From here, build PHP as normal:
|
||||
From here, force PHP to rebuild the configure script, and then build
|
||||
PHP as normal:
|
||||
|
||||
$ cd /your/phpsrcdir
|
||||
$ ./buildconf
|
||||
$ rm configure
|
||||
$ ./buildconf --force
|
||||
$ ./configure --help
|
||||
$ ./configure --with-extname --enable-someotherext --with-foobar
|
||||
$ make
|
||||
$ make install
|
||||
|
||||
Note: To run the 'buildconf' script you need autoconf 2.13 and
|
||||
automake 1.4+ (newer versions of autoconf may work, but are not
|
||||
supported).
|
||||
|
||||
Whether --enable-extname or --with-extname is used depends on the
|
||||
extension. Typically an extension that does not require external
|
||||
libraries uses --enable. To be sure, run the following after
|
||||
@@ -1403,14 +1535,23 @@ The configuration file
|
||||
versions of PHP, this happens only once when the web server is
|
||||
started. For the CGI and CLI version, it happens on every invocation.
|
||||
|
||||
The default location of php.ini is a compile time option (see the FAQ
|
||||
entry), but can be changed for the CGI and CLI version with the -c
|
||||
command line switch, see the chapter about using PHP from the command
|
||||
line. You can also use the environment variable PHPRC for an
|
||||
additional path to search for a php.ini file.
|
||||
php.ini is searched in these locations (in order):
|
||||
|
||||
* SAPI module specific location (PHPIniDir directive in Apache 2, -c
|
||||
command line option in CGI and CLI, php_ini parameter in NSAPI,
|
||||
PHP_INI_PATH environment variable in THTTPD)
|
||||
* HKEY_LOCAL_MACHINE\SOFTWARE\PHP\IniFilePath (Windows Registry
|
||||
location)
|
||||
* The PHPRC environment variable
|
||||
* Current working directory (for CLI)
|
||||
* The web server's directory (for SAPI modules), or directory of PHP
|
||||
(otherwise in Windows)
|
||||
* Windows directory (C:\windows or C:\winnt) (for Windows), or
|
||||
--with-config-file-path compile time option
|
||||
|
||||
If php-SAPI.ini exists (where SAPI is used SAPI, so the filename is
|
||||
e.g. php-cli.ini or php-apache.ini), it's used instead of php.ini.
|
||||
SAPI name can be determined by php_sapi_name().
|
||||
|
||||
Note: The Apache web server changes the directory to root at
|
||||
startup causing PHP to attempt to read php.ini from the root
|
||||
@@ -1418,11 +1559,11 @@ The configuration file
|
||||
|
||||
The php.ini directives handled by extensions are documented
|
||||
respectively on the pages of the extensions themselves. The list of
|
||||
the core directives is available in the appendix. Probably not all the
|
||||
PHP directives are documented in the manual though. For a completel
|
||||
list of directives available in your PHP version, please read your
|
||||
well commented php.ini file. Alternatively, you may find the the
|
||||
latest php.ini from CVS helpful too.
|
||||
the core directives is available in the appendix. Probably not all PHP
|
||||
directives are documented in the manual though. For a complete list of
|
||||
directives available in your PHP version, please read your well
|
||||
commented php.ini file. Alternatively, you may find the the latest
|
||||
php.ini from CVS helpful too.
|
||||
|
||||
Example 6-1. php.ini example
|
||||
; any text on a line after an unquoted semicolon (;) is ignored
|
||||
@@ -1438,6 +1579,10 @@ include_path = ".:/usr/local/lib/php"
|
||||
|
||||
; backslashes are treated the same as any other character
|
||||
include_path = ".;c:\php\lib"
|
||||
|
||||
Since PHP 5.1.0, it is possible to refer to existing .ini variables
|
||||
from within .ini files. Example: open_basedir = ${open_basedir}
|
||||
":/new/dir".
|
||||
_________________________________________________________________
|
||||
|
||||
How to change configuration settings
|
||||
@@ -1533,3 +1678,420 @@ Other interfaces to PHP
|
||||
function, and review the resulting page. You can also access the
|
||||
values of individual configuration directives at runtime using
|
||||
ini_get() or get_cfg_var().
|
||||
_________________________________________________________________
|
||||
|
||||
Chapter 7. Installation FAQ
|
||||
|
||||
This section holds common questions about the way to install PHP. PHP
|
||||
is available for almost any OS (except maybe for MacOS before OSX),
|
||||
and almost any web server.
|
||||
|
||||
To install PHP, follow the instructions in the INSTALL file located in
|
||||
the distribution. Windows users should also read the install.txt file.
|
||||
There are also some helpful hints for Windows users here.
|
||||
|
||||
1. Why shouldn't I use Apache2 with a threaded MPM in a production
|
||||
environment?
|
||||
|
||||
2. Unix/Windows: Where should my php.ini file be located?
|
||||
3. Unix: I installed PHP, but every time I load a document, I get the
|
||||
message 'Document Contains No Data'! What's going on here?
|
||||
|
||||
4. Unix: I installed PHP using RPMS, but Apache isn't processing the
|
||||
PHP pages! What's going on here?
|
||||
|
||||
5. Unix: I installed PHP 3 using RPMS, but it doesn't compile with the
|
||||
database support I need! What's going on here?
|
||||
|
||||
6. Unix: I patched Apache with the FrontPage extensions patch, and
|
||||
suddenly PHP stopped working. Is PHP incompatible with the
|
||||
Apache FrontPage extensions?
|
||||
|
||||
7. Unix/Windows: I have installed PHP, but when I try to access a PHP
|
||||
script file via my browser, I get a blank screen.
|
||||
|
||||
8. Unix/Windows: I have installed PHP, but when try to access a PHP
|
||||
script file via my browser, I get a server 500 error.
|
||||
|
||||
9. Some operating systems: I have installed PHP without errors, but
|
||||
when I try to start apache I get undefined symbol errors:
|
||||
|
||||
[mybox:user /src/php4] root# apachectl configtest
|
||||
apachectl: /usr/local/apache/bin/httpd Undefined symbols:
|
||||
_compress
|
||||
_uncompress
|
||||
|
||||
10. Windows: I have installed PHP, but when I to access a PHP script
|
||||
file via my browser, I get the error:
|
||||
|
||||
cgi error:
|
||||
The specified CGI application misbehaved by not
|
||||
returning a complete set of HTTP headers.
|
||||
The headers it did return are:
|
||||
|
||||
11. Windows: I've followed all the instructions, but still can't get
|
||||
PHP and IIS to work together!
|
||||
|
||||
12. When running PHP as CGI with IIS, PWS, OmniHTTPD or Xitami, I get
|
||||
the following error: Security Alert! PHP CGI cannot be accessed
|
||||
directly..
|
||||
|
||||
13. How do I know if my php.ini is being found and read? It seems like
|
||||
it isn't as my changes aren't being implemented.
|
||||
|
||||
14. How do I add my PHP directory to the PATH on Windows?
|
||||
15. How do I make the php.ini file available to PHP on windows?
|
||||
16. Is it possible to use Apache content negotiation (MultiViews
|
||||
option) with PHP?
|
||||
|
||||
17. Is PHP limited to process GET and POST request methods only?
|
||||
|
||||
1. Why shouldn't I use Apache2 with a threaded MPM in a production
|
||||
environment?
|
||||
|
||||
PHP is glue. It is the glue used to build cool web applications by
|
||||
sticking dozens of 3rd-party libraries together and making it all
|
||||
appear as one coherent entity through an intuitive and easy to learn
|
||||
language interface. The flexibility and power of PHP relies on the
|
||||
stability and robustness of the underlying platform. It needs a
|
||||
working OS, a working web server and working 3rd-party libraries to
|
||||
glue together. When any of these stop working PHP needs ways to
|
||||
identify the problems and fix them quickly. When you make the
|
||||
underlying framework more complex by not having completely separate
|
||||
execution threads, completely separate memory segments and a strong
|
||||
sandbox for each request to play in, feet of clay are introduced into
|
||||
PHP's system.
|
||||
|
||||
If you feel you have to use a threaded MPM, look at a FastCGI
|
||||
configuration where PHP is running in its own memory space.
|
||||
|
||||
And finally, this warning against using a threaded MPM is not as
|
||||
strong for Windows systems because most libraries on that platform
|
||||
tend to be threadsafe.
|
||||
|
||||
2. Unix/Windows: Where should my php.ini file be located?
|
||||
|
||||
By default on Unix it should be in /usr/local/lib which is
|
||||
<install-path>/lib. Most people will want to change this at
|
||||
compile-time with the --with-config-file-path flag. You would, for
|
||||
example, set it with something like:
|
||||
--with-config-file-path=/etc
|
||||
|
||||
And then you would copy php.ini-dist from the distribution to
|
||||
/etc/php.ini and edit it to make any local changes you want.
|
||||
--with-config-file-scan-dir=PATH
|
||||
|
||||
On Windows the default path for the php.ini file is the Windows
|
||||
directory. If you're using the Apache webserver, php.ini is first
|
||||
searched in the Apaches install directory, e.g. c:\program
|
||||
files\apache group\apache. This way you can have different php.ini
|
||||
files for different versions of Apache on the same machine.
|
||||
|
||||
See also the chapter about the configuration file.
|
||||
|
||||
3. Unix: I installed PHP, but every time I load a document, I get the
|
||||
message 'Document Contains No Data'! What's going on here?
|
||||
|
||||
This probably means that PHP is having some sort of problem and is
|
||||
core-dumping. Look in your server error log to see if this is the
|
||||
case, and then try to reproduce the problem with a small test case. If
|
||||
you know how to use 'gdb', it is very helpful when you can provide a
|
||||
backtrace with your bug report to help the developers pinpoint the
|
||||
problem. If you are using PHP as an Apache module try something like:
|
||||
|
||||
* Stop your httpd processes
|
||||
* gdb httpd
|
||||
* Stop your httpd processes
|
||||
* > run -X -f /path/to/httpd.conf
|
||||
* Then fetch the URL causing the problem with your browser
|
||||
* > run -X -f /path/to/httpd.conf
|
||||
* If you are getting a core dump, gdb should inform you of this now
|
||||
* type: bt
|
||||
* You should include your backtrace in your bug report. This should
|
||||
be submitted to http://bugs.php.net/
|
||||
|
||||
If your script uses the regular expression functions (ereg() and
|
||||
friends), you should make sure that you compiled PHP and Apache with
|
||||
the same regular expression package. This should happen automatically
|
||||
with PHP and Apache 1.3.x
|
||||
|
||||
4. Unix: I installed PHP using RPMS, but Apache isn't processing the
|
||||
PHP pages! What's going on here?
|
||||
|
||||
Assuming you installed both Apache and PHP from RPM packages, you need
|
||||
to uncomment or add some or all of the following lines in your
|
||||
httpd.conf file:
|
||||
# Extra Modules
|
||||
AddModule mod_php.c
|
||||
AddModule mod_php3.c
|
||||
AddModule mod_perl.c
|
||||
|
||||
# Extra Modules
|
||||
LoadModule php_module modules/mod_php.so
|
||||
LoadModule php3_module modules/libphp3.so # for PHP 3
|
||||
LoadModule php4_module modules/libphp4.so # for PHP 4
|
||||
LoadModule perl_module modules/libperl.so
|
||||
|
||||
And add:
|
||||
AddType application/x-httpd-php3 .php3 # for PHP 3
|
||||
AddType application/x-httpd-php .php # for PHP 4
|
||||
|
||||
... to the global properties, or to the properties of the
|
||||
VirtualDomain you want to have PHP support added to.
|
||||
|
||||
5. Unix: I installed PHP 3 using RPMS, but it doesn't compile with the
|
||||
database support I need! What's going on here?
|
||||
|
||||
Due to the way PHP 3 built, it is not easy to build a complete
|
||||
flexible PHP RPM. This issue is addressed in PHP 4. For PHP 3, we
|
||||
currently suggest you use the mechanism described in the
|
||||
INSTALL.REDHAT file in the PHP distribution. If you insist on using an
|
||||
RPM version of PHP 3, read on...
|
||||
|
||||
The RPM packagers are setting up the RPMS to install without database
|
||||
support to simplify installations and because RPMS use /usr/ instead
|
||||
of the standard /usr/local/ directory for files. You need to tell the
|
||||
RPM spec file which databases to support and the location of the
|
||||
top-level of your database server.
|
||||
|
||||
This example will explain the process of adding support for the
|
||||
popular MySQL database server, using the mod installation for Apache.
|
||||
|
||||
Of course all of this information can be adjusted for any database
|
||||
server that PHP supports. We will assume you installed MySQL and
|
||||
Apache completely with RPMS for this example as well.
|
||||
|
||||
* First remove mod_php3 :
|
||||
|
||||
rpm -e mod_php3
|
||||
|
||||
* Then get the source rpm and INSTALL it, NOT --rebuild
|
||||
|
||||
rpm -Uvh mod_php3-3.0.5-2.src.rpm
|
||||
|
||||
* Then edit the /usr/src/redhat/SPECS/mod_php3.spec file
|
||||
In the %build section add the database support you want, and the
|
||||
path.
|
||||
For MySQL you would add --with-mysql=/usr The %build section will
|
||||
look something like this:
|
||||
|
||||
./configure --prefix=/usr \
|
||||
--with-apxs=/usr/sbin/apxs \
|
||||
--with-config-file-path=/usr/lib \
|
||||
--enable-debug=no \
|
||||
--enable-safe-mode \
|
||||
--with-exec-dir=/usr/bin \
|
||||
--with-mysql=/usr \
|
||||
--with-system-regex
|
||||
|
||||
* Once this modification is made then build the binary rpm as
|
||||
follows:
|
||||
|
||||
rpm -bb /usr/src/redhat/SPECS/mod_php3.spec
|
||||
|
||||
* Then install the rpm
|
||||
|
||||
rpm -ivh /usr/src/redhat/RPMS/i386/mod_php3-3.0.5-2.i386.rpm
|
||||
|
||||
Make sure you restart Apache, and you now have PHP 3 with MySQL
|
||||
support using RPM's. Note that it is probably much easier to just
|
||||
build from the distribution tarball of PHP 3 and follow the
|
||||
instructions in INSTALL.REDHAT found in that distribution.
|
||||
|
||||
6. Unix: I patched Apache with the FrontPage extensions patch, and
|
||||
suddenly PHP stopped working. Is PHP incompatible with the Apache
|
||||
FrontPage extensions?
|
||||
|
||||
No, PHP works fine with the FrontPage extensions. The problem is that
|
||||
the FrontPage patch modifies several Apache structures, that PHP
|
||||
relies on. Recompiling PHP (using 'make clean ; make') after the FP
|
||||
patch is applied would solve the problem.
|
||||
|
||||
7. Unix/Windows: I have installed PHP, but when I try to access a PHP
|
||||
script file via my browser, I get a blank screen.
|
||||
|
||||
Do a 'view source' in the web browser and you will probably find that
|
||||
you can see the source code of your PHP script. This means that the
|
||||
web server did not send the script to PHP for interpretation.
|
||||
Something is wrong with the server configuration - double check the
|
||||
server configuration against the PHP installation instructions.
|
||||
|
||||
8. Unix/Windows: I have installed PHP, but when try to access a PHP
|
||||
script file via my browser, I get a server 500 error.
|
||||
|
||||
Something went wrong when the server tried to run PHP. To get to see a
|
||||
sensible error message, from the command line, change to the directory
|
||||
containing the PHP executable (php.exe on Windows) and run php -i. If
|
||||
PHP has any problems running, then a suitable error message will be
|
||||
displayed which will give you a clue as to what needs to be done next.
|
||||
If you get a screen full of HTML codes (the output of the phpinfo()
|
||||
function) then PHP is working, and your problem may be related to your
|
||||
server configuration which you should double check.
|
||||
|
||||
9. Some operating systems: I have installed PHP without errors, but
|
||||
when I try to start apache I get undefined symbol errors:
|
||||
[mybox:user /src/php4] root# apachectl configtest
|
||||
apachectl: /usr/local/apache/bin/httpd Undefined symbols:
|
||||
_compress
|
||||
_uncompress
|
||||
|
||||
This has actually nothing to do with PHP, but with the MySQL client
|
||||
libraries. Some need --with-zlib, others do not. This is also covered
|
||||
in the MySQL FAQ.
|
||||
|
||||
10. Windows: I have installed PHP, but when I to access a PHP script
|
||||
file via my browser, I get the error:
|
||||
cgi error:
|
||||
The specified CGI application misbehaved by not
|
||||
returning a complete set of HTTP headers.
|
||||
The headers it did return are:
|
||||
|
||||
This error message means that PHP failed to output anything at all. To
|
||||
get to see a sensible error message, from the command line, change to
|
||||
the directory containing the PHP executable (php.exe on Windows) and
|
||||
run php -i. If PHP has any problems running, then a suitable error
|
||||
message will be displayed which will give you a clue as to what needs
|
||||
to be done next. If you get a screen full of HTML codes (the output of
|
||||
the phpinfo() function) then PHP is working.
|
||||
|
||||
Once PHP is working at the command line, try accessing the script via
|
||||
the browser again. If it still fails then it could be one of the
|
||||
following:
|
||||
|
||||
* File permissions on your PHP script, php.exe, php4ts.dll, php.ini
|
||||
or any PHP extensions you are trying to load are such that the
|
||||
anonymous internet user ISUR_<machinename> cannot access them.
|
||||
* The script file does not exist (or possibly isn't where you think
|
||||
it is relative to your web root directory). Note that for IIS you
|
||||
can trap this error by ticking the 'check file exists' box when
|
||||
setting up the script mappings in the Internet Services Manager.
|
||||
If a script file does not exist then the server will return a 404
|
||||
error instead. There is also the additional benefit that IIS will
|
||||
do any authentication required for you based on the NTLanMan
|
||||
permissions on your script file.
|
||||
|
||||
11. Windows: I've followed all the instructions, but still can't get
|
||||
PHP and IIS to work together!
|
||||
|
||||
Make sure any user who needs to run a PHP script has the rights to run
|
||||
php.exe! IIS uses an anonymous user which is added at the time IIS is
|
||||
installed. This user needs rights to php.exe. Also, any authenticated
|
||||
user will also need rights to execute php.exe. And for IIS4 you need
|
||||
to tell it that PHP is a script engine. Also, you will want to read
|
||||
this faq.
|
||||
|
||||
12. When running PHP as CGI with IIS, PWS, 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 to 1
|
||||
so be sure the directive isn't commented out (with a ;). Like all
|
||||
directives, this is set in php.ini
|
||||
|
||||
Because the default is 1, it's critical that you're 100% sure that the
|
||||
correct php.ini file is being read. Read this faq for details.
|
||||
|
||||
13. How do I know if my php.ini is being found and read? It seems like
|
||||
it isn't as my changes aren't being implemented.
|
||||
|
||||
To be sure your php.ini is being read by PHP, make a call to phpinfo()
|
||||
and near the top will be a listing called Configuration File
|
||||
(php.ini). This will tell you where PHP is looking for php.ini and
|
||||
whether or not it's being read. If just a directory PATH exists than
|
||||
it's not being read and you should put your php.ini in that directory.
|
||||
If php.ini is included within the PATH than it is being read.
|
||||
|
||||
If php.ini is being read and you're running PHP as a module, then be
|
||||
sure to restart your web server after making changes to php.ini
|
||||
|
||||
14. How do I add my PHP directory to the PATH on Windows?
|
||||
|
||||
On Windows NT, 2000, XP and 2003:
|
||||
|
||||
* Go to Control Panel and open the System icon (Start -> Settings ->
|
||||
Control Panel -> System, or just Start -> Control Panel -> System
|
||||
for Windows XP/2003)
|
||||
* Go to the Advanced tab
|
||||
* Click on the 'Environment Variables' button
|
||||
* Look into the 'System Variables' pane
|
||||
* Find the Path entry (you may need to scroll to find it)
|
||||
* Double click on the Path entry
|
||||
* Enter your PHP directory ant the end, including ';' before (e.g.
|
||||
;C:\php)
|
||||
* Press OK and restart your computer
|
||||
|
||||
On Windows 98/Me you need to edit the autoexec.bat file:
|
||||
|
||||
* Open the Notepad (Start -> Run and enter notepad)
|
||||
* Open the C:\autoexec.bat file
|
||||
* Locate the line with PATH=C:\WINDOWS;C:\WINDOWS\COMMAND;..... and
|
||||
add: ;C:\php to the end of the line
|
||||
* Save the file and restart your computer
|
||||
|
||||
Note: Be sure to reboot after following the steps above to ensure
|
||||
that the PATH changes are applied.
|
||||
|
||||
The PHP manual used to promote the copying of files into the Windows
|
||||
system directory, this is because this directory (C:\Windows,
|
||||
C:\WINNT, etc.) is by default in the systems PATH. Copying files into
|
||||
the Windows system directory has long since been deprecated and may
|
||||
cause problems.
|
||||
|
||||
15. How do I make the php.ini file available to PHP on windows?
|
||||
|
||||
There are several ways of doing this. If you are using Apache, read
|
||||
their installation specific instructions (Apache 1, Apache 2),
|
||||
otherwise you must set the PHPRC environment variable:
|
||||
|
||||
On Windows NT, 2000, XP and 2003:
|
||||
|
||||
* Go to Control Panel and open the System icon (Start -> Settings ->
|
||||
Control Panel -> System, or just Start -> Control Panel -> System
|
||||
for Windows XP/2003)
|
||||
* Go to the Advanced tab
|
||||
* Click on the 'Environment Variables' button
|
||||
* Look into the 'System variables' pane
|
||||
* Click on 'New' and enter 'PHPRC' as the variable name and the
|
||||
directory where php.ini is located as the variable value (e.g.
|
||||
C:\php)
|
||||
* Press OK and restart your computer
|
||||
|
||||
On Windows 98/Me you need to edit the autoexec.bat file:
|
||||
|
||||
* Open the Notepad (Start -> Run and enter notepad)
|
||||
* Open the C:\autoexec.bat file
|
||||
* Add a new line to the end of the file: set PHPRC=C:\php (replace
|
||||
C:\php with the directory where php.ini is located). Please note
|
||||
that the path cannot contain spaces. For instance, if you have
|
||||
installed PHP in C:\Program Files\PHP, you would enter
|
||||
C:\PROGRA~1\PHP instead.
|
||||
* Save the file and restart your computer
|
||||
|
||||
16. Is it possible to use Apache content negotiation (MultiViews
|
||||
option) with PHP?
|
||||
|
||||
If links to PHP files include extension, everything works perfect.
|
||||
This FAQ is only for the case when links to PHP files don't include
|
||||
extension and you want to use content negotiation to choose PHP files
|
||||
from URL with no extension. In this case, replace the line AddType
|
||||
application/x-httpd-php .php with:
|
||||
# PHP 4
|
||||
AddHandler php-script php
|
||||
AddType text/html php
|
||||
|
||||
# PHP 5
|
||||
AddHandler php5-script php
|
||||
AddType text/html php
|
||||
|
||||
This solution doesn't work for Apache 1 as PHP module doesn't catch
|
||||
php-script.
|
||||
|
||||
17. Is PHP limited to process GET and POST request methods only?
|
||||
|
||||
No, it is possible to handle any request method, e.g. CONNECT. Proper
|
||||
response status can be sent with header(). If only GET and POST
|
||||
methods should be handled, it can be achieved with this Apache
|
||||
configuration:
|
||||
<LimitExcept GET POST>
|
||||
Deny from all
|
||||
</LimitExcept>
|
||||
@@ -1,6 +1,6 @@
|
||||
--------------------------------------------------------------------
|
||||
The PHP License, Version 3.0
|
||||
Copyright (c) 1999 - 2005 The PHP Group. All rights reserved.
|
||||
The PHP License, version 3.01
|
||||
Copyright (c) 1999 - 2006 The PHP Group. All rights reserved.
|
||||
--------------------------------------------------------------------
|
||||
|
||||
Redistribution and use in source and binary forms, with or without
|
||||
@@ -38,8 +38,8 @@ are met:
|
||||
|
||||
6. Redistributions of any form whatsoever must retain the following
|
||||
acknowledgment:
|
||||
"This product includes PHP, freely available from
|
||||
<http://www.php.net/>".
|
||||
"This product includes PHP software, freely available from
|
||||
<http://www.php.net/software/>".
|
||||
|
||||
THIS SOFTWARE IS PROVIDED BY THE PHP DEVELOPMENT TEAM ``AS IS'' AND
|
||||
ANY EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
|
||||
@@ -64,5 +64,5 @@ The PHP Group can be contacted via Email at group@php.net.
|
||||
For more information on the PHP Group and the PHP project,
|
||||
please see <http://www.php.net>.
|
||||
|
||||
This product includes the Zend Engine, freely available at
|
||||
PHP includes the Zend Engine, freely available at
|
||||
<http://www.zend.com>.
|
||||
@@ -0,0 +1,70 @@
|
||||
|
||||
#
|
||||
# LCOV
|
||||
#
|
||||
|
||||
lcov: lcov-html
|
||||
|
||||
lcov-test: all
|
||||
@echo "Running test suite"
|
||||
@find . -name \*.gcda -o -name \*.da -o -name \*.bbg? | xargs rm -f
|
||||
-@if test ! -z "$(PHP_EXECUTABLE)" && test -x "$(PHP_EXECUTABLE)"; then \
|
||||
NO_INTERACTION=1 \
|
||||
TEST_PHP_EXECUTABLE=$(PHP_EXECUTABLE) \
|
||||
TEST_PHP_SRCDIR=$(top_srcdir) \
|
||||
CC="$(CC)" \
|
||||
$(PHP_EXECUTABLE) -d 'open_basedir=' -d 'safe_mode=0' -d 'output_buffering=0' -d 'memory_limit=-1' $(top_srcdir)/run-tests.php -d 'extension_dir=modules/' -d `( . $(PHP_MODULES) ; echo extension=$$dlname)` tests/; \
|
||||
elif test ! -z "$(SAPI_CLI_PATH)" && test -x "$(SAPI_CLI_PATH)"; then \
|
||||
NO_INTERACTION=1 \
|
||||
TEST_PHP_EXECUTABLE=$(top_builddir)/$(SAPI_CLI_PATH) \
|
||||
TEST_PHP_SRCDIR=$(top_srcdir) \
|
||||
CC="$(CC)" \
|
||||
$(top_builddir)/$(SAPI_CLI_PATH) -d 'open_basedir=' -d 'safe_mode=0' -d 'output_buffering=0' -d 'memory_limit=-1' $(top_srcdir)/run-tests.php $(TESTS); \
|
||||
else \
|
||||
echo "ERROR: Cannot run tests without CLI sapi."; \
|
||||
fi
|
||||
|
||||
php_lcov.info: lcov-test
|
||||
@echo "Generating data for $@"
|
||||
@rm -rf lcov_data/
|
||||
@$(mkinstalldirs) lcov_data/
|
||||
@echo
|
||||
-@find . -name \*.gcda -o -name \*.gcno -o -name \*.da | sed -e 's/^\.\///' | sed -e 's/\.gcda//g' -e 's/\.gcno//g' -e 's/\.da//g' | uniq | while read x; do \
|
||||
echo -n . ;\
|
||||
y=`echo $$x | sed -e 's!\.libs/!!'`; \
|
||||
dir=lcov_data/`dirname $$x`; \
|
||||
test -d "$$dir" || $(mkinstalldirs) "$$dir"; \
|
||||
if test -f "$(top_srcdir)/$$y.c"; then \
|
||||
ln -f -s $(top_srcdir)/$$y.c lcov_data/$$y.c; \
|
||||
fi; \
|
||||
if test -f "$(top_srcdir)/$$y.re"; then \
|
||||
ln -f -s $(top_srcdir)/$$y.re lcov_data/$$y.re; \
|
||||
fi; \
|
||||
if test -f "$(top_srcdir)/$$y.y"; then \
|
||||
ln -f -s $(top_srcdir)/$$y.y lcov_data/$$y.y; \
|
||||
fi; \
|
||||
if test -f "$(top_srcdir)/$$y.l"; then \
|
||||
ln -f -s $(top_srcdir)/$$y.l lcov_data/$$y.l; \
|
||||
fi; \
|
||||
if test -f "$(top_builddir)/$$y.c"; then \
|
||||
ln -f -s $(top_builddir)/$$y.c lcov_data/$$y.c; \
|
||||
fi; \
|
||||
test -f "$$x.gcno" && cp $$x.gcno lcov_data/$$y.gcno ; \
|
||||
test -f "$$x.gcda" && cp $$x.gcda lcov_data/$$y.gcda ; \
|
||||
test -f "$$x.da" && cp $$x.da lcov_data/$$y.da ; \
|
||||
test -f "$$x.bb" && cp $$x.bb lcov_data/$$y.bb ; \
|
||||
test -f "$$x.bbg" && cp $$x.bbg lcov_data/$$y.bbg ; \
|
||||
done
|
||||
@echo
|
||||
@echo "Generating $@"
|
||||
@$(LTP) --directory lcov_data/ --capture --base-directory=lcov_data --output-file $@
|
||||
|
||||
lcov-html: php_lcov.info
|
||||
@echo "Generating lcov HTML"
|
||||
@$(LTP_GENHTML) --legend --output-directory lcov_html/ --title "PHP Code Coverage" --show-details php_lcov.info
|
||||
|
||||
lcov-clean:
|
||||
rm -f php_lcov.info
|
||||
rm -rf lcov_data/
|
||||
rm -rf lcov_html/
|
||||
|
||||
+5
-5
@@ -25,10 +25,10 @@ install: $(all_targets) $(install_targets)
|
||||
install-sapi: $(OVERALL_TARGET)
|
||||
@echo "Installing PHP SAPI module: $(PHP_SAPI)"
|
||||
-@$(mkinstalldirs) $(INSTALL_ROOT)$(bindir)
|
||||
-@if test ! -r $(phptempdir)/libphp5.$(SHLIB_SUFFIX_NAME); then \
|
||||
-@if test ! -r $(phptempdir)/libphp5.$(SHLIB_DL_SUFFIX_NAME); then \
|
||||
for i in 0.0.0 0.0 0; do \
|
||||
if test -r $(phptempdir)/libphp5.$(SHLIB_SUFFIX_NAME).$$i; then \
|
||||
$(LN_S) $(phptempdir)/libphp5.$(SHLIB_SUFFIX_NAME).$$i $(phptempdir)/libphp5.$(SHLIB_SUFFIX_NAME); \
|
||||
if test -r $(phptempdir)/libphp5.$(SHLIB_DL_SUFFIX_NAME).$$i; then \
|
||||
$(LN_S) $(phptempdir)/libphp5.$(SHLIB_DL_SUFFIX_NAME).$$i $(phptempdir)/libphp5.$(SHLIB_DL_SUFFIX_NAME); \
|
||||
break; \
|
||||
fi; \
|
||||
done; \
|
||||
@@ -44,13 +44,13 @@ install-modules: build-modules
|
||||
|
||||
install-headers:
|
||||
-@if test "$(INSTALL_HEADERS)"; then \
|
||||
for i in $(INSTALL_HEADERS); do \
|
||||
for i in `echo $(INSTALL_HEADERS)`; do \
|
||||
i=`$(top_srcdir)/build/shtool path -d $$i`; \
|
||||
paths="$$paths $(INSTALL_ROOT)$(phpincludedir)/$$i"; \
|
||||
done; \
|
||||
$(mkinstalldirs) $$paths && \
|
||||
echo "Installing header files: $(INSTALL_ROOT)$(phpincludedir)/" && \
|
||||
for i in $(INSTALL_HEADERS); do \
|
||||
for i in `echo $(INSTALL_HEADERS)`; do \
|
||||
if test "$(PHP_PECL_EXTENSION)"; then \
|
||||
src=`echo $$i | $(SED) -e "s#ext/$(PHP_PECL_EXTENSION)/##g"`; \
|
||||
else \
|
||||
|
||||
@@ -1,6 +1,482 @@
|
||||
PHP NEWS
|
||||
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
||||
?? ??? 2006, PHP 5.1.1
|
||||
24 Aug 2006, PHP 5.1.6
|
||||
- Fixed memory_limit on 64bit systems. (Stefan E.)
|
||||
- Fixed bug #38488 (Access to "php://stdin" and family crashes PHP on win32).
|
||||
(Dmitry)
|
||||
|
||||
17 Aug 2006, PHP 5.1.5
|
||||
- Fixed overflow on 64bit systems in str_repeat() and wordwrap(). (Stefan E.)
|
||||
- Disabled CURLOPT_FOLLOWLOCATION in curl when open_basedir or safe_mode are
|
||||
enabled. (Stefan E., Ilia)
|
||||
- Fixed bug #38322 (reading past array in sscanf() leads to arbitrary code
|
||||
execution). (Tony)
|
||||
- Fixed bug #38125 (undefined reference to spl_dual_it_free_storage). (Marcus)
|
||||
- Fixed bug #38112 (corrupted gif segfaults) (Pierre)
|
||||
- Fixed bug #37587 (var without attribute causes segfault). (Marcus)
|
||||
- Fixed bug #37576 (FastCGI env (cgi vars) table overflow). (Piotr)
|
||||
- Fixed bug #37496 (FastCGI output buffer overrun). (Piotr, Dmitry)
|
||||
- Fixed bug #37487 (oci_fetch_array() array-type should always default to
|
||||
OCI_BOTH). (Tony)
|
||||
- Fixed bug #37416 (iterator_to_array() hides exceptions thrown in rewind()
|
||||
method). (Tony)
|
||||
- Fixed bug #37392 (Unnecessary call to OCITransRollback() at the end of
|
||||
request). (Tony)
|
||||
- Fixed bug #37341 ($_SERVER in included file is shortened to two entries,
|
||||
if $_ENV gets used). (Dmitry)
|
||||
- Fixed bug #37313 (sigemptyset() used without including <signal.h>).
|
||||
(jdolecek)
|
||||
- Fixed bug #37346 (invalid colormap format) (Pierre)
|
||||
- Fixed bug #37360 (invalid gif size) (Pierre)
|
||||
- Fixed bug #37306 (max_execution_time = max_input_time). (Dmitry)
|
||||
- Fixed Bug #37278 (SOAP not respecting uri in __soapCall). (Dmitry)
|
||||
- Fixed bug #37265 (Added missing safe_mode & open_basedir checks to
|
||||
imap_body()). (Ilia)
|
||||
- Fixed bug #37256 (php-fastcgi dosen't handle connection abort). (Dmitry)
|
||||
|
||||
04 May 2006, PHP 5.1.4
|
||||
- Added "capture_peer_cert" and "capture_peer_cert_chain" context options
|
||||
for SSL streams. (Wez).
|
||||
- Added PDO::PARAM_EVT_* family of constants. (Sara)
|
||||
- Fixed possible crash in highlight_string(). (Dmitry)
|
||||
- Fixed bug #37291 (FastCGI now longer works with isapi_fcgi.dll). (Dmitry)
|
||||
- Fixed bug #37277 (cloning Dom Documents or Nodes does not work). (Rob)
|
||||
- Fixed bug #37276 (problems with $_POST array). (Dmitry)
|
||||
- Fixed bug #36632 (bad error reporting for pdo_odbc exec UPDATE). (Wez).
|
||||
- Fixed bug #35552 (crash when pdo_odbc prepare fails). (Wez).
|
||||
|
||||
28 Apr 2006, PHP 5.1.3
|
||||
- Updated bundled PCRE library to version 6.6. (Andrei)
|
||||
- Moved extensions to PECL:
|
||||
. ext/msession (Derick)
|
||||
- Reimplemented FastCGI interface. (Dmitry)
|
||||
- Improved SPL: (Marcus)
|
||||
- Fixed issues with not/double calling of constructors of SPL iterators.
|
||||
- Fixed issues with info-class/file-class in SPL directory handling classes.
|
||||
- Fixed ArrayIterator::seek().
|
||||
- Added SimpleXMLIterator::count().
|
||||
- Dropped erroneous RecursiveDirectoryIterator::getSubPathInfo().
|
||||
- Improved SimpleXML: (Marcus, Rob)
|
||||
. Added SimpleXMLElement::getName() to retrieve name of element.
|
||||
. Added ability to create elements on the fly.
|
||||
. Added addChild() method for element creation supporting namespaces.
|
||||
. Added addAttribute() method for attribute creation supporting namespaces.
|
||||
. Added ability to delete specific elements and attributes by offset.
|
||||
- Improved Reflection API: (Marcus)
|
||||
. Added ReflectionClass::newInstanceArgs($args).
|
||||
. Added ability to analyze extension dependency.
|
||||
. Added ReflectionFunction::isDeprecated() and constant IS_DEPRECATED.
|
||||
. Added ReflectionParameter::getDeclaringClass().
|
||||
. Changed reflection constants to be prefixed with IS_. (Johannes)
|
||||
- Improved cURL extension: (Ilia)
|
||||
. Added curl_setopt_array() function that allows setting of multiple
|
||||
options via an associated array.
|
||||
. Added the ability to retrieve the request message sent to the server.
|
||||
- Improved GD extension: (Pierre)
|
||||
. Added a weak/tolerant mode to the JPEG loader.
|
||||
. Added filtering mode option to imagepng() to allow reducing file size.
|
||||
. Fixed imagecolorallocate() and imagecolorallocatelapha() to return FALSE
|
||||
on error.
|
||||
- Changed get_headers() to retrieve headers also from non-200 responses.
|
||||
(Ilia)
|
||||
- Changed get_headers() to use the default context. (Ilia)
|
||||
- Added lchown() and lchgrp() to change user/group ownership of symlinks.
|
||||
(Derick)
|
||||
- Added support for exif date format in strtotime(). (Derick)
|
||||
- Added a check for special characters in the session name. (Ilia)
|
||||
- Added "consumed" stream filter. (Marcus)
|
||||
- Added new mysqli constants for BIT and NEW_DECIMAL field types:
|
||||
MYSQLI_TYPE_NEWDECIMAL and MYSQLI_TYPE_BIT. FR #36007. (Georg)
|
||||
- Added imap_savebody() that allows message body to be written to a
|
||||
file. (Mike)
|
||||
- Added overflow checks to wordwrap() function. (Ilia)
|
||||
- Added support for BINARY_DOUBLE and BINARY_FLOAT to PDO_OCI and OCI8
|
||||
(also fixes bug #36764). (Tony)
|
||||
- Eliminated run-time constant fetching for TRUE, FALSE and NULL. (Dmitry)
|
||||
- Removed the E_STRICT deprecation notice from "var". (Ilia)
|
||||
- Fixed reading stream filters never notified about EOF. (Mike)
|
||||
- Fixed tempnam() 2nd parameter to be checked against path components. (Ilia)
|
||||
- Fixed a bug that would not fill in the fifth argument to preg_replace()
|
||||
properly, if the variable was not declared previously. (Andrei)
|
||||
- Fixed safe_mode check for source argument of the copy() function. (Ilia)
|
||||
- Fixed mysqli bigint conversion under Windows (Georg)
|
||||
- Fixed XSS inside phpinfo() with long inputs. (Ilia)
|
||||
- Fixed Apache2 SAPIs header handler modifying header strings. (Mike)
|
||||
- Fixed 'auto_globals_jit' to work together with 'register_argc_argv'. (Dmitry)
|
||||
- Fixed offset/length parameter validation in substr_compare() function. (Ilia)
|
||||
- Fixed debug_zval_dump() to support private and protected members. (Dmitry)
|
||||
- Fixed SoapFault::getMessage(). (Dmitry)
|
||||
- Fixed issue with iconv_mime_decode where the "encoding" would only allow
|
||||
upper case specifiers. (Derick)
|
||||
- Fixed tiger hash algorithm generating wrong results on big endian platforms.
|
||||
(Mike)
|
||||
- Fixed crash with DOMImplementation::createDocumentType("name:"). (Mike)
|
||||
- Fixed bug #37205 (Serving binary content/images fails with "comm with server
|
||||
aborted" FastCGI err). (Dmitry)
|
||||
- Fixed bug #37192 (cc may complain about non-constant initializers in
|
||||
hash_adler.c). (Mike)
|
||||
- Fixed bug #37191 (chmod takes off sticky bit when safe_mode is On). (Tony)
|
||||
- Fixed bug #37167 (PDO segfaults when throwing exception from the
|
||||
fetch handler). (Tony)
|
||||
- Fixed bug #37162 (wddx does not build as a shared extension).
|
||||
(jdolecek at NetBSD dot org, Ilia)
|
||||
- Fixed bug #37158 (fread behavior changes after calling
|
||||
stream_wrapper_register). (Wez)
|
||||
- Fixed bug #37138 (__autoload tries to load callback'ed self and parent).
|
||||
(Dmitry)
|
||||
- Fixed bug #37103 (libmbfl headers not installed). (Jani)
|
||||
- Fixed bug #37062 (compile failure on ARM architecture). (Tony)
|
||||
- Fixed bug #37061 (curl_exec() doesn't zero-terminate binary strings). (Tony)
|
||||
- Fixed bug #37060 (Type of retval of Countable::count() is not checked).
|
||||
(Johannes)
|
||||
- Fixed bug #37059 (oci_bind_by_name() doesn't support RAW and LONG RAW
|
||||
fields). (Tony)
|
||||
- Fixed bug #37057 (xmlrpc_decode() may produce arrays with numeric strings,
|
||||
which are unaccessible). (Tony)
|
||||
- Fixed bug #37055 (incorrect reference counting for persistent OCI8
|
||||
connections). (Tony)
|
||||
- Fixed bug #37054 (SoapClient Error Fetching http headers). (Dmitry)
|
||||
- Fixed bug #37053 (html_errors with internal classes produces wrong links).
|
||||
(Tony)
|
||||
- Fixed bug #37046 (foreach breaks static scope). (Dmitry)
|
||||
- Fixed bug #37045 (Fixed check for special chars for http redirects). (Ilia)
|
||||
- Fixed bug #37017 (strtotime fails before 13:00:00 with some time zones
|
||||
identifiers). (Derick)
|
||||
- Fixed bug #37002 (Have to quote literals in INI when concatenating with
|
||||
vars). (Dmitry)z
|
||||
- Fixed bug #36988 (mktime freezes on long numbers). (Derick)
|
||||
- Fixed bug #36981 (SplFileObject->fgets() ignores max_length). (Tony)
|
||||
- Fixed bug #36957 (serialize() does not handle recursion). (Ilia)
|
||||
- Fixed bug #36944 (strncmp & strncasecmp do not return false on negative
|
||||
string length). (Tony)
|
||||
- Fixed bug #36941 (ArrayIterator does not clone itself). (Marcus)
|
||||
- Fixed bug #36934 (OCILob->read() doesn't move internal pointer when
|
||||
reading 0's). (Tony)
|
||||
- Fixed bug #36908 (wsdl default value overrides value in soap request).
|
||||
(Dmitry)
|
||||
- Fixed bug #36898 (__set() leaks in classes extending internal ones).
|
||||
(Tony, Dmitry)
|
||||
- Fixed bug #36886 (User filters can leak buckets in some situations). (Ilia)
|
||||
- Fixed bug #36878 (error messages are printed even though an exception has
|
||||
been thrown). (Tony)
|
||||
- Fixed bug #36875 (is_*() functions do not account for open_basedir). (Ilia)
|
||||
- Fixed bug #36872 (session_destroy() fails after call to
|
||||
session_regenerate_id(true)). (Ilia)
|
||||
- Fixed bug #36869 (memory leak in output buffering when using chunked
|
||||
output). (Tony)
|
||||
- Fixed bug #36859 (DOMElement crashes when calling __construct when
|
||||
cloning). (Tony)
|
||||
- Fixed bug #36857 (Added support for partial content fetching to the
|
||||
HTTP streams wrapper). (Ilia)
|
||||
- Fixed bug #36851 (Documentation and code discrepancies for NULL
|
||||
data in oci_fetch_*() functions). (Tony)
|
||||
- Fixed bug #36825 (Exceptions thrown in ArrayObject::offsetGet cause
|
||||
segfault). (Tony)
|
||||
- Fixed bug #36820 (Privileged connection with an Oracle password file
|
||||
fails). (Tony)
|
||||
- Fixed bug #36809 (__FILE__ behavior changed). (Dmitry)
|
||||
- Fixed bug #36808 (syslog ident becomes garbage between requests). (Tony)
|
||||
- Fixed bug #36802 (mysqli_set_charset() crash with a non-open connection).
|
||||
(Ilia)
|
||||
- Fixed bug #36756 (DOMDocument::removeChild corrupts node). (Rob)
|
||||
- Fixed bug #36749 (SOAP: 'Error Fetching http body' when using HTTP Proxy).
|
||||
(Dmitry)
|
||||
- Fixed bug #36745 (No error message when load data local file isn't found).
|
||||
(Georg)
|
||||
- Fixed bug #36743 (In a class extending XMLReader array properties are not
|
||||
writable). (Tony)
|
||||
- Fixed bug #36727 (segfault in pdo_pgsql bindValue() when no parameters are
|
||||
defined). (Tony)
|
||||
- Fixed bug #36721 (The SoapServer is not able to send a header that it didn't
|
||||
receive). (Dmitry)
|
||||
- Fixed bug #36697 (Transparency is lost when using imagecreatetruecolor).
|
||||
(Pierre)
|
||||
- Fixed bug #36689 (Removed arbitrary limit on the length of syslog messages).
|
||||
(Ilia)
|
||||
- Fixed bug #36656 (http_build_query generates invalid URIs due to use of
|
||||
square brackets). (Mike)
|
||||
- Fixed bug #36638 (strtotime() returns false when 2nd argument < 1). (Derick)
|
||||
- Fixed bug #36629 (SoapServer::handle() exits on SOAP faults). (Dmitry)
|
||||
- Fixed bug #36625 (pg_trace() does not work). (iakio at mono-space dot net)
|
||||
- Fixed bug #36614 (Segfault when using Soap). (Dmitry)
|
||||
- Fixed bug #36611 (assignment to SimpleXML object attribute changes argument
|
||||
type to string). (Tony)
|
||||
- Fixed bug #36606 (pg_query_params() changes arguments type to string). (Tony)
|
||||
- Fixed bug #36599 (DATE_W3C format constant incorrect). (Derick)
|
||||
- Fixed bug #36575 (SOAP: Incorrect complex type instantiation with
|
||||
hierarchies). (Dmitry)
|
||||
- Fixed bug #36572 (Added PDO::MYSQL_ATTR_DIRECT_QUERY constant that should
|
||||
be set when executing internal queries like "show master status" via MySQL).
|
||||
(Ilia)
|
||||
- Fixed bug #36568 (memory_limit setting on win32 has no effect). (Dmitry)
|
||||
- Fixed bug #36513 (comment will be outputted in last line). (Dmitry)
|
||||
- Fixed bug #36510 (strtotime() fails to parse date strings with tabs).
|
||||
(Ilia, Derick)
|
||||
- Fixed bug #36459 (Incorrect adding PHPSESSID to links, which contains \r\n).
|
||||
(Ilia)
|
||||
- Fixed bug #36458 (sleep() accepts negative values). (Ilia)
|
||||
- Fixed bug #36436 (DBA problem with Berkeley DB4). (Marcus)
|
||||
- Fixed bug #36434 (Improper resolution of declaring class name of an
|
||||
inherited property). (Ilia)
|
||||
- Fixed bug #36420 (segfault when access result->num_rows after calling
|
||||
result->close()). (Ilia,Tony)
|
||||
- Fixed bug #36403 (oci_execute() no longer supports OCI_DESCRIBE_ONLY). (Tony)
|
||||
- Fixed bug #36400 (Custom 5xx error does not return correct HTTP response error
|
||||
code). (Tony)
|
||||
- Fixed bug #36396 (strtotime() fails to parse dates in dd-mm-yyyy format).
|
||||
(Derick)
|
||||
- Fixed bug #36388 (ext/soap crashes when throwing exception and session
|
||||
persistence). (David)
|
||||
- Fixed bug #36382 (PDO/PgSQL's getColumnMeta() crashes). (Derick)
|
||||
- Fixed bug #36359 (splFileObject::fwrite() doesn't write when no data
|
||||
length specified). (Tony)
|
||||
- Fixed bug #36351 (parse_url() does not parse numeric paths properly). (Ilia)
|
||||
- Fixed bug #36345 (PDO/MySQL problem loading BLOB over 1MB). (Ilia)
|
||||
- Fixed bug #36337 (ReflectionProperty fails to return correct visibility).
|
||||
(Ilia)
|
||||
- Fixed bug #36334 (Added missing documentation about realpath cache INI
|
||||
settings). (Ilia)
|
||||
- Fixed bug #36308 (ReflectionProperty::getDocComment() does not reflect
|
||||
extended class commentary). (Ilia)
|
||||
- Fixed bug #36306 (crc32() differ on 32-bit and 64-bit platforms)
|
||||
(anight@eyelinkmedia dot com, Pierre)
|
||||
- Fixed bug #36303 (foreach on error_zval produces segfault). (Dmitry)
|
||||
- Fixed bug #36295 (typo in SplFileObject::flock() parameter name). (Tony)
|
||||
- Fixed bug #36287 (Segfault with SplFileInfo conversion). (Marcus)
|
||||
- Fixed bug #36283 (SOAPClient Compression Broken). (Dmitry)
|
||||
- Fixed bug #36268 (Object destructors called even after fatal errors). (Dmitry)
|
||||
- Fixed bug #36258 (SplFileObject::getPath() may lead to segfault). (Tony)
|
||||
- Fixed bug #36250 (PHP causes ORA-07445 core dump in Oracle server 9.2.x).
|
||||
(Tony)
|
||||
- Fixed bug #36242 (Possible memory corruption in stream_select()). (Tony)
|
||||
- Fixed bug #36235 (ocicolumnname returns false before a successful fetch).
|
||||
(Tony)
|
||||
- Fixed bug #36226 (Inconsistent handling when passing potential arrays).
|
||||
(Dmitry)
|
||||
- Fixed bug #36224 (date(DATE_ATOM) gives wrong results).
|
||||
(Derick, Hannes Magnusson)
|
||||
- Fixed bug #36222 (errorInfo in PDOException is always NULL). (Ilia)
|
||||
- Fixed bug #36208 (symbol namespace conflicts using bundled gd). (Jakub Moc)
|
||||
- Fixed bug #36205 (Memory leaks on duplicate cookies). (Dmitry)
|
||||
- Fixed bug #36185 (str_rot13() crash on non-string parameter). (Pierre)
|
||||
- Fixed bug #36176 (PDO_PGSQL - PDO::exec() does not return number of rows
|
||||
affected by the operation). (Ilia)
|
||||
- Fixed bug #36158 (SIGTERM is not handled correctly when running as a
|
||||
FastCGI server). (Dmitry)
|
||||
- Fixed bug #36152 (problems with curl+ssl and pgsql+ssl in same PHP). (Mike)
|
||||
- Fixed bug #36148 (unpack("H*hex", $data) is adding an extra character to
|
||||
the end of the string). (Ilia)
|
||||
- Fixed bug #36134 (DirectoryIterator constructor failed to detect empty
|
||||
directory names). (Ilia)
|
||||
- Fixed bug #36113 (Reading records of unsupported type causes segfault).
|
||||
(Tony)
|
||||
- Fixed bug #36096 (oci_result() returns garbage after oci_fetch() failed).
|
||||
(Tony)
|
||||
- Fixed bug #36083 (SoapClient waits for responses on one-way operations).
|
||||
(Dmitry)
|
||||
- Fixed bug #36071 (Engine Crash related with 'clone'). (Dmitry)
|
||||
- Fixed bug #36055 (possible OCI8 crash in multi-threaded environment). (Tony)
|
||||
- Fixed bug #36046 (parse_ini_file() miscounts lines in multi-line values).
|
||||
(Ilia)
|
||||
- Fixed bug #36038 (ext/hash compile failure on Mac OSX). (Tony)
|
||||
- Fixed bug #36037 (heredoc adds extra line number). (Dmitry)
|
||||
- Fixed bug #36016 (realpath cache memleaks). (Dmitry, Nuno)
|
||||
- Fixed bug #36011 (Strict errormsg wrong for call_user_func() and the likes).
|
||||
(Marcus)
|
||||
- Fixed bug #36010 (Segfault when re-creating and re-executing statements with
|
||||
bound parameters). (Tony)
|
||||
- Fixed bug #36006 (Problem with $this in __destruct()). (Dmitry)
|
||||
- Fixed bug #35999 (recursive mkdir() does not work with relative path
|
||||
like "foo/bar"). (Tony)
|
||||
- Fixed bug #35998 (SplFileInfo::getPathname() returns unix style filenames
|
||||
in win32). (Marcus)
|
||||
- Fixed bug #35988 (Unknown persistent list entry type in module shutdown).
|
||||
(Dmitry)
|
||||
- Fixed bug #35954 (Fatal com_exception casting object). (Rob)
|
||||
- Fixed bug #35900 (stream_select() should warning when tv_sec is negative).
|
||||
(Ilia)
|
||||
- Fixed bug #35785 (SimpleXML causes memory read error zend engine). (Marcus)
|
||||
- Fixed bug #34272 (empty array onto COM object blows up). (Rob)
|
||||
- Fixed bug #33292 (apache_get_modules() crashes on Windows). (Edin)
|
||||
- Fixed bug #29476 (sqlite_fetch_column_types() locks the database forever).
|
||||
(Ilia)
|
||||
|
||||
12 Jan 2006, PHP 5.1.2
|
||||
- Updated libsqlite in ext/sqlite to 2.8.17. (Ilia)
|
||||
- Updated libsqlite in ext/pdo_sqlite to 3.2.8. (Ilia)
|
||||
- Updated to libxml2-2.6.22 and libxslt-1.1.15 in the win32 bundle. (Rob)
|
||||
- Added new extensions: (Ilia, Wez)
|
||||
. XMLWriter
|
||||
. Hash
|
||||
- Added PNG compression support to GD extension. (Pierre)
|
||||
- Added reflection constants as class constants. (Johannes)
|
||||
- Added --enable-gcov configure option to enable C-level code coverage.
|
||||
(John, Jani, Ilia, Marcus)
|
||||
- Added missing support for 'B' format identifier to date() function. (Ilia)
|
||||
- Changed reflection to be an extension. (Marcus)
|
||||
- Improved SPL extension: (Marcus)
|
||||
. Added class SplFileInfo as root class for DirectoryIterator and
|
||||
SplFileObject
|
||||
. Added SplTempFileObject
|
||||
- Improved SimpleXML extension: (Marcus)
|
||||
. Fixed memleaks
|
||||
. Fixed var_dump()
|
||||
. Fixed isset/empty/(bool) behavior
|
||||
. Fixed iterator edge cases
|
||||
. Added methods getNamespaces(), getDocNamespaces()
|
||||
- Upgraded pear to version 1.4.6. (Greg)
|
||||
- Added constants for libxslt and libexslt versions: LIBXSLT_VERSION,
|
||||
LIBXSLT_DOTTED_VERSION, LIBEXSLT_VERSION and LIBEXSLT_DOTTED_VERSION. (Pierre)
|
||||
- Fixed possible crash in apache_getenv()/apache_setenv() on invalid parameters.
|
||||
(Ilia)
|
||||
- Changed errors to warnings in imagecolormatch(). (Pierre)
|
||||
- Fixed segfault/leak in imagecolormatch(). (Pierre)
|
||||
- Fixed small leak in mysqli_stmt_fetch() when bound variable was empty string.
|
||||
(Andrey)
|
||||
- Fixed prepared statement name conflict handling in PDO_PGSQL. (Thies, Ilia)
|
||||
- Fixed memory corruption when PDO::FETCH_LAZY mode is being used. (Ilia)
|
||||
- Fixed possible leaks in imagecreatefromstring() with invalid data. (Pierre)
|
||||
- Fixed possible memory corruption inside mb_strcut(). (Ilia)
|
||||
- Fixed possible header injection by limiting each header to a single line.
|
||||
(Ilia)
|
||||
- Fixed possible XSS inside error reporting functionality. (Ilia)
|
||||
- Fixed many bugs in OCI8. (Tony)
|
||||
- Fixed crash and leak in mysqli when using 4.1.x client libraries and
|
||||
connecting to 5.x server. (Andrey)
|
||||
- Fixed bug #35916 (Duplicate calls to stream_bucket_append() lead to a crash).
|
||||
(Ilia)
|
||||
- Fixed bug #35908 (curl extension uses undefined GCRY_THREAD_OPTIONS_USER).
|
||||
(Ilia)
|
||||
- Fixed bug #35907 (PDO_OCI uses hardcoded lib path $ORACLE_HOME/lib). (Tony)
|
||||
- Fixed bug #35887 (wddx_deserialize not parsing dateTime fields properly).
|
||||
(Derick)
|
||||
- Fixed bug #35885 (strtotime("NOW") no longer works). (Derick)
|
||||
- Fixed bug #35821 (array_map() segfaults when exception is throwed from
|
||||
the callback). (Tony)
|
||||
- Fixed bug #35817 (unpack() does not decode odd number of hexadecimal values).
|
||||
(Ilia)
|
||||
- Fixed bug #35797 (segfault on PDOStatement::execute() with
|
||||
zend.ze1_compatibility_mode = On). (Tony, Ilia)
|
||||
- Fixed bug #35781 (stream_filter_append() can cause segfault). (Tony)
|
||||
- Fixed bug #35760 (sybase_ct doesn't compile on Solaris using old gcc). (Tony)
|
||||
- Fixed bug #35759 (mysqli_stmt_bind_result() makes huge allocation when
|
||||
column empty). (Andrey)
|
||||
- Fixed bug #35751 (using date with a timestamp makes httpd segfault). (Derick)
|
||||
- Fixed bug #35740 (memory leak when including a directory). (Tony)
|
||||
- Fixed bug #35730 (ext/mssql + freetds: Use correct character encoding
|
||||
and allow setting it). (Frank)
|
||||
- Fixed bug #35723 (xmlrpc_introspection.c fails compile per C99 std). (Jani)
|
||||
- Fixed bug #35720 (A final constructor can be overwritten). (Marcus)
|
||||
- Fixed bug #35713 (getopt() returns array with numeric strings when passed
|
||||
options like '-1'). (Tony)
|
||||
- Fixed bug #35705 (strtotime() fails to parse soap date format without TZ).
|
||||
(Ilia)
|
||||
- Fixed bug #35699 (date() can't handle leap years before 1970). (Derick)
|
||||
- Fixed bug #35694 (Improved error message for invalid fetch mode). (Ilia)
|
||||
- Fixed bug #35692 (iconv_mime_decode() segmentation fault; with libiconv
|
||||
only). (Tony)
|
||||
- Fixed bug #35690 (pack() tries to allocate huge memory block when packing
|
||||
float values to strings). (Tony)
|
||||
- Fixed bug #35669 (imap_mail_compose() crashes with
|
||||
multipart-multiboundary-email). (Ilia)
|
||||
- Fixed bug #35660 (AIX TZ variable format not understood, yields UTC
|
||||
timezone). (Derick)
|
||||
- Fixed bug #35655 (whitespace following end of heredoc is lost). (Ilia)
|
||||
- Fixed bug #35630 (strtotime() crashes on certain relative identifiers).
|
||||
(Ilia)
|
||||
- Fixed bug #35629 (crash in http:// wrapper on multiple redirects). (Ilia)
|
||||
- Fixed bug #35624 (strtotime() does not handle 3 character weekdays). (Ilia)
|
||||
- Fixed bug #35612 (iis6 Access Violation crash). (Dmitry, alacn.uhahaa)
|
||||
- Fixed bug #35594 (Multiple calls to getopt() may result in a crash).
|
||||
(rabbitt at gmail dot com, Ilia)
|
||||
- Fixed bug #35571 (Fixed crash in Apache 2 SAPI when more then one php
|
||||
script is loaded via SSI include). (Ilia)
|
||||
- Fixed bug #35570 (segfault when re-using soap client object). (Dmitry)
|
||||
- Fixed bug #35558 (mktime() interpreting 3 digit years incorrectly). (Ilia)
|
||||
- Fixed bug #35543 (php crash when calling non existing method of a class
|
||||
that extends PDO). (Tony)
|
||||
- Fixed bug #35539 (typo in error message for ErrorException). (Tony)
|
||||
- FIxed bug #35536 (mysql_field_type() doesn't handle NEWDECIMAL). (Tony)
|
||||
- Fixed bug #35517 (mysql_stmt_fetch returns NULL on data truncation). (Georg)
|
||||
- Fixed bug #35509 (string constant as array key has different behavior inside
|
||||
object). (Dmitry)
|
||||
- Fixed bug #35508 (PDO fails when unknown fetch mode specified). (Tony)
|
||||
- Fixed bug #35499 (strtotime() does not handle whitespace around the date
|
||||
string). (Ilia)
|
||||
- Fixed bug #35496 (Crash in mcrypt_generic()/mdecrypt_generic() without
|
||||
proper init). (Ilia)
|
||||
- Fixed bug #35490 (socket_sendto() unable to handle IPv6 addresses). (Tony)
|
||||
- Fixed bug #35461 (Ming extension fails to compile with ming 0.3beta1). (Jani)
|
||||
- Fixed bug #35437 (Segfault or Invalid Opcode 137/1/4). (Dmitry)
|
||||
- Fixed bug #35470 (Assigning global using variable name from array doesn't
|
||||
function). (Dmitry)
|
||||
- Fixed bug #35456 (+ 1 [time unit] format did not work). (Ilia)
|
||||
- Fixed bug #35447 (xml_parse_into_struct() chokes on the UTF-8 BOM). (Rob)
|
||||
- Fixed bug #35431 (PDO crashes when using LAZY fetch with fetchAll). (Wez)
|
||||
- Fixed bug #35430 (PDO crashes on incorrect FETCH_FUNC use). (Tony)
|
||||
- Fixed bug #35427 (str_word_count() handles '-' incorrectly). (Ilia)
|
||||
- Fixed bug #35425 (idate() function ignores timezone settings). (Ilia)
|
||||
- Fixed bug #35422 (strtotime() does not parse times with UTC as timezone).
|
||||
(Ilia)
|
||||
- Fixed bug #35414 (strtotime() no longer works with ordinal suffix). (Ilia)
|
||||
- Fixed bug #35410 (wddx_deserialize() doesn't handle large ints as keys
|
||||
properly). (Ilia)
|
||||
- Fixed bug #35409 (undefined reference to 'rl_completion_matches'). (Jani)
|
||||
- Fixed bug #35399 (Since fix of bug #35273 SOAP decoding of
|
||||
soapenc:base64binary fails). (Dmitry)
|
||||
- Fixed bug #35393 (changing static protected members from outside the class,
|
||||
one more reference issue). (Dmitry)
|
||||
- Fixed bug #35381 (ssl library is not initialized properly). (Alan)
|
||||
- Fixed bug #35377 (PDO_SQLITE: undefined reference to "fdatasync").
|
||||
(Nuno, Jani)
|
||||
- Fixed bug #35373 (HP-UX "alias not allowed in this configuration"). (Dmitry)
|
||||
- Fixed bug #35288 (iconv() function defined as libiconv()). (Nuno)
|
||||
- Fixed bug #35103 (mysqli handles bad unsigned (big)int incorrectly).(Andrey)
|
||||
- Fixed bug #35062 (socket_read() produces warnings on non blocking sockets).
|
||||
(Nuno, Ilia)
|
||||
- Fixed bug #35028 (SimpleXML object fails FALSE test). (Marcus)
|
||||
- Fixed bug #34729 (Crash in ZTS mode under Apache). (Dmitry, Zeev)
|
||||
- Fixed bug #34429 (Output buffering cannot be turned off with FastCGI).
|
||||
(Dmitry, Ilya)
|
||||
- Fixed bug #34359 (Possible crash inside fopen http wrapper). (Ilia,Sara,Nuno)
|
||||
- Fixed bug #33789 (Many Problems with SunFuncs). (Derick)
|
||||
- Fixed bug #33671 (sun_rise and sun_set don't return a GMT timestamp if one
|
||||
passes an offset). (Derick)
|
||||
- Fixed bug #32820 (date_sunrise and date_sunset don't handle GMT offset
|
||||
well). (Derick)
|
||||
- Fixed bug #31347 (is_dir and is_file (incorrectly) return true for any string
|
||||
greater then 255 characters). (Nuno,Ilia)
|
||||
- Fixed bug #30937 (date_sunrise() & date_sunset() don't handle endless
|
||||
day/night at high latitudes). (Derick)
|
||||
- Fixed bug #30760 (Remove MessageBox on win32 for E_CORE errors if
|
||||
display_startup_error is off). (Ilia)
|
||||
- Fixed bug #29955 (mb_strtoupper() / lower() broken with Turkish encoding).
|
||||
(Rui)
|
||||
- Fixed bug #28899 (mb_substr() and substr() behave differently when
|
||||
"mbstring.func_overload" is enabled). (Rui)
|
||||
- Fixed bug #27678 (number_format() crashes with large numbers). (Marcus)
|
||||
|
||||
28 Nov 2005, PHP 5.1.1
|
||||
- Disabled native date class to prevent pear::date conflict. (Ilia)
|
||||
- Changed reflection constants be both PHP and class constants. (Johannes)
|
||||
- Added an additional field $frame['object'] to the result array of
|
||||
debug_backtrace() that contains a reference to the respective object when the
|
||||
frame was called from an object. (Sebastian)
|
||||
- Fixed bug #35423 (RecursiveDirectoryIterator doesnt appear to recurse with
|
||||
RecursiveFilterIterator). (Marcus)
|
||||
- Fixed bug #35413 (Removed -dev flag from Zend Engine version). (Ilia)
|
||||
- Fixed bug #35411 (Regression with \{$ handling). (Ilia)
|
||||
- Fixed bug #35406 (eval hangs when evall'ed code ends with comment w/o
|
||||
newline). (Marcus)
|
||||
- Fixed bug #35391 (pdo_mysql::exec does not return number of affected rows).
|
||||
(Tony)
|
||||
- Fixed bug #35382 (Comment in end of file produces fatal error). (Ilia)
|
||||
- Fixed bug #35360 (exceptions in interactive mode (php -a) may cause crash).
|
||||
(Dmitry)
|
||||
- Fixed bug #35358 (Incorrect error messages for PDO class constants). (Ilia)
|
||||
- Fixed bug #35338 (pdo_pgsql does not handle binary bound params). (Wez)
|
||||
- Fixed bug #35316 (Application exception trying to create COM object). (Rob)
|
||||
- Fixed bug #35170 (PHP_AUTH_DIGEST differs under Apache 1.x and 2.x). (Ilia)
|
||||
|
||||
24 Nov 2005, PHP 5.1
|
||||
- Added support for class constants and static members for internal classes.
|
||||
@@ -98,7 +574,7 @@ PHP NEWS
|
||||
- Added support of parameter=>value arrays to
|
||||
xsl_xsltprocessor_set_parameter(). (Tony)
|
||||
|
||||
- Improved PHP extension loading mechanism with support for module
|
||||
- PHP extension loading mechanism with support for module
|
||||
dependencies and conflicts. (Jani, Dmitry)
|
||||
- Improved interactive mode of PHP CLI (php -a). (Johannes, Marcus)
|
||||
- Improved performance of:
|
||||
|
||||
+14
-6
@@ -29,14 +29,22 @@ Having said that, here are the organizational rules:
|
||||
5. If you don't know how to do something, ask first!
|
||||
|
||||
6. Test your changes before committing them. We mean it. Really.
|
||||
To do so use "make test".
|
||||
|
||||
7. For development use the --enable-maintainer-zts switch to ensure your
|
||||
code handles TSRM correctly and doesn't break for thos who need that.
|
||||
|
||||
Currently we have the following branches in use:
|
||||
HEAD Will become PHP 5.1. This CVS branch is for active development.
|
||||
PHP_5_0 Is used to release the PHP 5.0.x series. Only minor feature
|
||||
enhancements may go in here, but please keep that as infrequent as
|
||||
possible.
|
||||
PHP_4_3 Is used to release the PHP 4.3.x series. Only bugfixes are permitted
|
||||
on this branch.
|
||||
HEAD Will become PHP 6.0. This CVS branch is for active development.
|
||||
PHP_5_2 Is used to release the PHP 5.2.x series. Only minor feature
|
||||
enhancements may go in here, but please keep that as infrequent as
|
||||
possible.
|
||||
PHP_5_1 Is used to release the PHP 5.1.x series. Only bugfixes are permitted
|
||||
on this branch (Consult the releasemaster prior to commit).
|
||||
PHP_5_0 This branch is closed.
|
||||
PHP_4_4 Is used to release the PHP 4.4.x series. Only bugfixes are permitted
|
||||
on this branch (Consult the releasemaster prior to commit).
|
||||
PHP_4_3 This branch is closed.
|
||||
|
||||
The next few rules are more of a technical nature.
|
||||
|
||||
|
||||
+1
-1
@@ -34,7 +34,7 @@ ZEND_END_MODULE_GLOBALS(my_input_filter)
|
||||
|
||||
ZEND_DECLARE_MODULE_GLOBALS(my_input_filter)
|
||||
|
||||
function_entry my_input_filter_functions[] = {
|
||||
zend_function_entry my_input_filter_functions[] = {
|
||||
PHP_FE(my_get_raw, NULL)
|
||||
{NULL, NULL, NULL}
|
||||
};
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
Copyright (c) 1999, 2000, Andi Gutmans, Sascha Schumann, Zeev Suraski.
|
||||
Copyright (c) 1999-2006, Andi Gutmans, Sascha Schumann, Zeev Suraski.
|
||||
All rights reserved.
|
||||
|
||||
Redistribution and use in source and binary forms, with or without
|
||||
|
||||
+47
-1
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Thread Safe Resource Manager |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1999, 2000, Andi Gutmans, Sascha Schumann, Zeev Suraski|
|
||||
| Copyright (c) 1999-2006, Andi Gutmans, Sascha Schumann, Zeev Suraski |
|
||||
| This source file is subject to the TSRM license, that is bundled |
|
||||
| with this package in the file LICENSE |
|
||||
+----------------------------------------------------------------------+
|
||||
@@ -480,6 +480,52 @@ void ts_free_thread(void)
|
||||
}
|
||||
|
||||
|
||||
/* frees all resources allocated for all threads except current */
|
||||
void ts_free_worker_threads(void)
|
||||
{
|
||||
tsrm_tls_entry *thread_resources;
|
||||
int i;
|
||||
THREAD_T thread_id = tsrm_thread_id();
|
||||
int hash_value;
|
||||
tsrm_tls_entry *last=NULL;
|
||||
|
||||
tsrm_mutex_lock(tsmm_mutex);
|
||||
hash_value = THREAD_HASH_OF(thread_id, tsrm_tls_table_size);
|
||||
thread_resources = tsrm_tls_table[hash_value];
|
||||
|
||||
while (thread_resources) {
|
||||
if (thread_resources->thread_id != thread_id) {
|
||||
for (i=0; i<thread_resources->count; i++) {
|
||||
if (resource_types_table[i].dtor) {
|
||||
resource_types_table[i].dtor(thread_resources->storage[i], &thread_resources->storage);
|
||||
}
|
||||
}
|
||||
for (i=0; i<thread_resources->count; i++) {
|
||||
free(thread_resources->storage[i]);
|
||||
}
|
||||
free(thread_resources->storage);
|
||||
if (last) {
|
||||
last->next = thread_resources->next;
|
||||
} else {
|
||||
tsrm_tls_table[hash_value] = thread_resources->next;
|
||||
}
|
||||
free(thread_resources);
|
||||
if (last) {
|
||||
thread_resources = last->next;
|
||||
} else {
|
||||
thread_resources = tsrm_tls_table[hash_value];
|
||||
}
|
||||
} else {
|
||||
if (thread_resources->next) {
|
||||
last = thread_resources;
|
||||
}
|
||||
thread_resources = thread_resources->next;
|
||||
}
|
||||
}
|
||||
tsrm_mutex_unlock(tsmm_mutex);
|
||||
}
|
||||
|
||||
|
||||
/* deallocates all occurrences of a given id */
|
||||
void ts_free_id(ts_rsrc_id id)
|
||||
{
|
||||
|
||||
+4
-1
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Thread Safe Resource Manager |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1999, 2000, Andi Gutmans, Sascha Schumann, Zeev Suraski|
|
||||
| Copyright (c) 1999-2006, Andi Gutmans, Sascha Schumann, Zeev Suraski |
|
||||
| This source file is subject to the TSRM license, that is bundled |
|
||||
| with this package in the file LICENSE |
|
||||
+----------------------------------------------------------------------+
|
||||
@@ -106,6 +106,9 @@ TSRM_API void *ts_resource_ex(ts_rsrc_id id, THREAD_T *th_id);
|
||||
/* frees all resources allocated for the current thread */
|
||||
TSRM_API void ts_free_thread(void);
|
||||
|
||||
/* frees all resources allocated for all threads except current */
|
||||
void ts_free_worker_threads(void);
|
||||
|
||||
/* deallocates all occurrences of a given id */
|
||||
TSRM_API void ts_free_id(ts_rsrc_id id);
|
||||
|
||||
|
||||
@@ -42,6 +42,8 @@ char *alloca ();
|
||||
#ifndef MAXPATHLEN
|
||||
# ifdef PATH_MAX
|
||||
# define MAXPATHLEN PATH_MAX
|
||||
# elif defined(MAX_PATH)
|
||||
# define MAXPATHLEN MAX_PATH
|
||||
# else
|
||||
# define MAXPATHLEN 256
|
||||
# endif
|
||||
|
||||
+3
-3
@@ -2,12 +2,12 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| PHP Version 5 |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1997-2005 The PHP Group |
|
||||
| Copyright (c) 1997-2006 The PHP Group |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 3.0 of the PHP license, |
|
||||
| This source file is subject to version 3.01 of the PHP license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
| available through the world-wide-web at the following url: |
|
||||
| http://www.php.net/license/3_0.txt. |
|
||||
| http://www.php.net/license/3_01.txt |
|
||||
| If you did not receive a copy of the PHP license and are unable to |
|
||||
| obtain it through the world-wide-web, please send a note to |
|
||||
| license@php.net so we can mail you a copy immediately. |
|
||||
|
||||
+3
-3
@@ -2,12 +2,12 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| PHP Version 5 |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1997-2005 The PHP Group |
|
||||
| Copyright (c) 1997-2006 The PHP Group |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 3.0 of the PHP license, |
|
||||
| This source file is subject to version 3.01 of the PHP license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
| available through the world-wide-web at the following url: |
|
||||
| http://www.php.net/license/3_0.txt. |
|
||||
| http://www.php.net/license/3_01.txt |
|
||||
| If you did not receive a copy of the PHP license and are unable to |
|
||||
| obtain it through the world-wide-web, please send a note to |
|
||||
| license@php.net so we can mail you a copy immediately. |
|
||||
|
||||
+47
-27
@@ -2,12 +2,12 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| PHP Version 5 |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1997-2005 The PHP Group |
|
||||
| Copyright (c) 1997-2006 The PHP Group |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 3.0 of the PHP license, |
|
||||
| This source file is subject to version 3.01 of the PHP license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
| available through the world-wide-web at the following url: |
|
||||
| http://www.php.net/license/3_0.txt. |
|
||||
| http://www.php.net/license/3_01.txt |
|
||||
| If you did not receive a copy of the PHP license and are unable to |
|
||||
| obtain it through the world-wide-web, please send a note to |
|
||||
| license@php.net so we can mail you a copy immediately. |
|
||||
@@ -163,18 +163,15 @@ static int php_is_file_ok(const cwd_state *state)
|
||||
static void cwd_globals_ctor(virtual_cwd_globals *cwd_globals TSRMLS_DC)
|
||||
{
|
||||
CWD_STATE_COPY(&cwd_globals->cwd, &main_cwd_state);
|
||||
#ifdef REALPATH_CACHE
|
||||
cwd_globals->realpath_cache_size = 0;
|
||||
cwd_globals->realpath_cache_size_limit = REALPATH_CACHE_SIZE;
|
||||
cwd_globals->realpath_cache_ttl = REALPATH_CACHE_TTL;
|
||||
memset(cwd_globals->realpath_cache, 0, sizeof(cwd_globals->realpath_cache));
|
||||
#endif
|
||||
}
|
||||
|
||||
static void cwd_globals_dtor(virtual_cwd_globals *cwd_globals TSRMLS_DC)
|
||||
{
|
||||
CWD_STATE_FREE(&cwd_globals->cwd);
|
||||
#ifdef REALPATH_CACHE
|
||||
{
|
||||
int i;
|
||||
|
||||
@@ -187,7 +184,6 @@ static void cwd_globals_dtor(virtual_cwd_globals *cwd_globals TSRMLS_DC)
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
static char *tsrm_strndup(const char *s, size_t length)
|
||||
@@ -308,7 +304,6 @@ CWD_API char *virtual_getcwd(char *buf, size_t size TSRMLS_DC)
|
||||
return buf;
|
||||
}
|
||||
|
||||
#ifdef REALPATH_CACHE
|
||||
static inline unsigned long realpath_cache_key(const char *path, int path_len)
|
||||
{
|
||||
register unsigned long h;
|
||||
@@ -352,19 +347,18 @@ static inline realpath_cache_bucket* realpath_cache_find(const char *path, int p
|
||||
while (*bucket != NULL) {
|
||||
if (CWDG(realpath_cache_ttl) && (*bucket)->expires < t) {
|
||||
realpath_cache_bucket *r = *bucket;
|
||||
*bucket = (*bucket)->next;
|
||||
CWDG(realpath_cache_size) -= sizeof(realpath_cache_bucket) + r->path_len + 1 + r->realpath_len + 1;
|
||||
free(r);
|
||||
*bucket = (*bucket)->next;
|
||||
CWDG(realpath_cache_size) -= sizeof(realpath_cache_bucket) + r->path_len + 1 + r->realpath_len + 1;
|
||||
free(r);
|
||||
} else if (key == (*bucket)->key && path_len == (*bucket)->path_len &&
|
||||
memcmp(path, (*bucket)->path, path_len) == 0) {
|
||||
return *bucket;
|
||||
} else {
|
||||
*bucket = (*bucket)->next;
|
||||
bucket = &(*bucket)->next;
|
||||
}
|
||||
}
|
||||
return NULL;
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
/* Resolve path relatively to state and put the real path into state */
|
||||
@@ -385,20 +379,17 @@ CWD_API int virtual_file_ex(cwd_state *state, const char *path, verify_path_func
|
||||
#else
|
||||
char *new_path;
|
||||
#endif
|
||||
#ifdef REALPATH_CACHE
|
||||
char orig_path[MAXPATHLEN];
|
||||
int orig_path_len;
|
||||
int orig_path_len = 0;
|
||||
realpath_cache_bucket *bucket;
|
||||
time_t t;
|
||||
time_t t = 0;
|
||||
TSRMLS_FETCH();
|
||||
#endif
|
||||
|
||||
if (path_length == 0)
|
||||
return (0);
|
||||
if (path_length >= MAXPATHLEN)
|
||||
return (1);
|
||||
|
||||
#ifdef REALPATH_CACHE
|
||||
if (use_realpath && CWDG(realpath_cache_size_limit)) {
|
||||
if (IS_ABSOLUTE_PATH(path, path_length) || (state->cwd_length < 1)) {
|
||||
memcpy(orig_path, path, path_length+1);
|
||||
@@ -430,7 +421,6 @@ CWD_API int virtual_file_ex(cwd_state *state, const char *path, verify_path_func
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif
|
||||
#if !defined(TSRM_WIN32) && !defined(NETWARE)
|
||||
/* cwd_length can be 0 when getcwd() fails.
|
||||
* This can happen under solaris when a dir does not have read permissions
|
||||
@@ -478,13 +468,14 @@ CWD_API int virtual_file_ex(cwd_state *state, const char *path, verify_path_func
|
||||
#endif
|
||||
#if defined(TSRM_WIN32)
|
||||
{
|
||||
char *dummy = NULL;
|
||||
int new_path_length;
|
||||
|
||||
new_path_length = GetLongPathName(path, dummy, 0) + 1;
|
||||
new_path_length = GetLongPathName(path, NULL, 0);
|
||||
if (new_path_length == 0) {
|
||||
return 1;
|
||||
goto php_failed_getlongpath;
|
||||
}
|
||||
|
||||
/* GetLongPathName already counts the \0 */
|
||||
new_path = (char *) malloc(new_path_length);
|
||||
if (!new_path) {
|
||||
return 1;
|
||||
@@ -495,6 +486,7 @@ CWD_API int virtual_file_ex(cwd_state *state, const char *path, verify_path_func
|
||||
path_length = new_path_length;
|
||||
} else {
|
||||
free(new_path);
|
||||
php_failed_getlongpath:
|
||||
new_path = NULL;
|
||||
}
|
||||
}
|
||||
@@ -607,11 +599,9 @@ CWD_API int virtual_file_ex(cwd_state *state, const char *path, verify_path_func
|
||||
#endif
|
||||
free(free_path);
|
||||
|
||||
#ifdef REALPATH_CACHE
|
||||
if (use_realpath && CWDG(realpath_cache_size_limit)) {
|
||||
realpath_cache_add(orig_path, orig_path_len, state->cwd, state->cwd_length, t TSRMLS_CC);
|
||||
}
|
||||
#endif
|
||||
|
||||
if (verify_path && verify_path(state)) {
|
||||
CWD_STATE_FREE(state);
|
||||
@@ -775,7 +765,7 @@ CWD_API int virtual_chmod(const char *filename, mode_t mode TSRMLS_DC)
|
||||
}
|
||||
|
||||
#if !defined(TSRM_WIN32) && !defined(NETWARE)
|
||||
CWD_API int virtual_chown(const char *filename, uid_t owner, gid_t group TSRMLS_DC)
|
||||
CWD_API int virtual_chown(const char *filename, uid_t owner, gid_t group, int link TSRMLS_DC)
|
||||
{
|
||||
cwd_state new_state;
|
||||
int ret;
|
||||
@@ -783,7 +773,15 @@ CWD_API int virtual_chown(const char *filename, uid_t owner, gid_t group TSRMLS_
|
||||
CWD_STATE_COPY(&new_state, &CWDG(cwd));
|
||||
virtual_file_ex(&new_state, filename, NULL, 0);
|
||||
|
||||
ret = chown(new_state.cwd, owner, group);
|
||||
if (link) {
|
||||
#if HAVE_LCHOWN
|
||||
ret = lchown(new_state.cwd, owner, group);
|
||||
#else
|
||||
ret = -1;
|
||||
#endif
|
||||
} else {
|
||||
ret = chown(new_state.cwd, owner, group);
|
||||
}
|
||||
|
||||
CWD_STATE_FREE(&new_state);
|
||||
return ret;
|
||||
@@ -856,7 +854,9 @@ CWD_API int virtual_stat(const char *path, struct stat *buf TSRMLS_DC)
|
||||
int retval;
|
||||
|
||||
CWD_STATE_COPY(&new_state, &CWDG(cwd));
|
||||
virtual_file_ex(&new_state, path, NULL, 1);
|
||||
if (virtual_file_ex(&new_state, path, NULL, 1)) {
|
||||
return -1;
|
||||
}
|
||||
|
||||
retval = stat(new_state.cwd, buf);
|
||||
|
||||
@@ -1043,6 +1043,26 @@ CWD_API FILE *virtual_popen(const char *command, const char *type TSRMLS_DC)
|
||||
|
||||
#endif
|
||||
|
||||
/* On AIX & Tru64 when a file does not exist realpath() returns
|
||||
* NULL, and sets errno to ENOENT. Unlike in other libc implementations
|
||||
* the destination is not filled and remains undefined. Therefor, we
|
||||
* must populate it manually using strcpy as done on systems with no
|
||||
* realpath() function.
|
||||
*/
|
||||
#if defined(__osf__) || defined(_AIX)
|
||||
char *php_realpath_hack(char *src, char *dest)
|
||||
{
|
||||
char *ret;
|
||||
|
||||
if ((ret = realpath(src, dest)) == NULL && errno == ENOENT) {
|
||||
return strcpy(dest, src);
|
||||
} else {
|
||||
return ret;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
|
||||
/*
|
||||
* Local variables:
|
||||
|
||||
+12
-26
@@ -2,12 +2,12 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| PHP Version 5 |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1997-2005 The PHP Group |
|
||||
| Copyright (c) 1997-2006 The PHP Group |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 3.0 of the PHP license, |
|
||||
| This source file is subject to version 3.01 of the PHP license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
| available through the world-wide-web at the following url: |
|
||||
| http://www.php.net/license/3_0.txt. |
|
||||
| http://www.php.net/license/3_01.txt |
|
||||
| If you did not receive a copy of the PHP license and are unable to |
|
||||
| obtain it through the world-wide-web, please send a note to |
|
||||
| license@php.net so we can mail you a copy immediately. |
|
||||
@@ -166,23 +166,8 @@ CWD_API int virtual_access(const char *pathname, int mode TSRMLS_DC);
|
||||
#endif
|
||||
#endif
|
||||
|
||||
/* On AIX & Tru64 when a file does not exist realpath() returns
|
||||
* NULL, and sets errno to ENOENT. Unlike in other libc implementations
|
||||
* the destination is not filled and remains undefined. Therefor, we
|
||||
* must populate it manually using strcpy as done on systems with no
|
||||
* realpath() function.
|
||||
*/
|
||||
#if defined(__osf__) || defined(_AIX)
|
||||
static char *php_realpath_hack(char *src, char *dest)
|
||||
{
|
||||
char *ret;
|
||||
|
||||
if ((ret = realpath(src, dest)) == NULL && errno == ENOENT) {
|
||||
return strcpy(dest, src);
|
||||
} else {
|
||||
return ret;
|
||||
}
|
||||
}
|
||||
char *php_realpath_hack(char *src, char *dest);
|
||||
#endif
|
||||
|
||||
#if HAVE_UTIME
|
||||
@@ -190,16 +175,14 @@ CWD_API int virtual_utime(const char *filename, struct utimbuf *buf TSRMLS_DC);
|
||||
#endif
|
||||
CWD_API int virtual_chmod(const char *filename, mode_t mode TSRMLS_DC);
|
||||
#if !defined(TSRM_WIN32) && !defined(NETWARE)
|
||||
CWD_API int virtual_chown(const char *filename, uid_t owner, gid_t group TSRMLS_DC);
|
||||
CWD_API int virtual_chown(const char *filename, uid_t owner, gid_t group, int link TSRMLS_DC);
|
||||
#endif
|
||||
|
||||
CWD_API int virtual_file_ex(cwd_state *state, const char *path, verify_path_func verify_path, int use_realpath);
|
||||
|
||||
#define REALPATH_CACHE
|
||||
#define REALPATH_CACHE_TTL (2*60) /* 2 minutes */
|
||||
#define REALPATH_CACHE_SIZE 0 /* disabled while php.ini isn't loaded */
|
||||
|
||||
#ifdef REALPATH_CACHE
|
||||
typedef struct _realpath_cache_bucket {
|
||||
unsigned long key;
|
||||
char *path;
|
||||
@@ -209,16 +192,13 @@ typedef struct _realpath_cache_bucket {
|
||||
time_t expires;
|
||||
struct _realpath_cache_bucket *next;
|
||||
} realpath_cache_bucket;
|
||||
#endif
|
||||
|
||||
typedef struct _virtual_cwd_globals {
|
||||
cwd_state cwd;
|
||||
#ifdef REALPATH_CACHE
|
||||
long realpath_cache_size;
|
||||
long realpath_cache_size_limit;
|
||||
long realpath_cache_ttl;
|
||||
realpath_cache_bucket *realpath_cache[1024];
|
||||
#endif
|
||||
} virtual_cwd_globals;
|
||||
|
||||
#ifdef ZTS
|
||||
@@ -262,7 +242,10 @@ extern virtual_cwd_globals cwd_globals;
|
||||
#endif
|
||||
#define VCWD_CHMOD(path, mode) virtual_chmod(path, mode TSRMLS_CC)
|
||||
#if !defined(TSRM_WIN32) && !defined(NETWARE)
|
||||
#define VCWD_CHOWN(path, owner, group) virtual_chown(path, owner, group TSRMLS_CC)
|
||||
#define VCWD_CHOWN(path, owner, group) virtual_chown(path, owner, group, 0 TSRMLS_CC)
|
||||
#if HAVE_LCHOWN
|
||||
#define VCWD_LCHOWN(path, owner, group) virtual_chown(path, owner, group, 1 TSRMLS_CC)
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#else
|
||||
@@ -305,6 +288,9 @@ extern virtual_cwd_globals cwd_globals;
|
||||
#define VCWD_CHMOD(path, mode) chmod(path, mode)
|
||||
#if !defined(TSRM_WIN32) && !defined(NETWARE)
|
||||
#define VCWD_CHOWN(path, owner, group) chown(path, owner, group)
|
||||
#if HAVE_LCHOWN
|
||||
#define VCWD_LCHOWN(path, owner, group) lchown(path, owner, group)
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
+3
-3
@@ -2,12 +2,12 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| PHP Version 5 |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1997-2005 The PHP Group |
|
||||
| Copyright (c) 1997-2006 The PHP Group |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 3.0 of the PHP license, |
|
||||
| This source file is subject to version 3.01 of the PHP license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
| available through the world-wide-web at the following url: |
|
||||
| http://www.php.net/license/3_0.txt. |
|
||||
| http://www.php.net/license/3_01.txt |
|
||||
| If you did not receive a copy of the PHP license and are unable to |
|
||||
| obtain it through the world-wide-web, please send a note to |
|
||||
| license@php.net so we can mail you a copy immediately. |
|
||||
|
||||
+3
-3
@@ -2,12 +2,12 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| PHP Version 5 |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1997-2005 The PHP Group |
|
||||
| Copyright (c) 1997-2006 The PHP Group |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 3.0 of the PHP license, |
|
||||
| This source file is subject to version 3.01 of the PHP license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
| available through the world-wide-web at the following url: |
|
||||
| http://www.php.net/license/3_0.txt. |
|
||||
| http://www.php.net/license/3_01.txt |
|
||||
| If you did not receive a copy of the PHP license and are unable to |
|
||||
| obtain it through the world-wide-web, please send a note to |
|
||||
| license@php.net so we can mail you a copy immediately. |
|
||||
|
||||
@@ -404,10 +404,6 @@ PDO_CLASS_CONSTANT
|
||||
|
||||
in order to minimise pollution of the global namespace in PHP.
|
||||
|
||||
Note that the new Date class exists at this point purely to allow the core date
|
||||
extension to adhere to the above convention, although extended functionality
|
||||
is planned for the the class in the future.
|
||||
|
||||
10. Date/time support
|
||||
====================
|
||||
|
||||
|
||||
+1
-1
@@ -1,6 +1,6 @@
|
||||
--------------------------------------------------------------------
|
||||
The Zend Engine License, Version 2.00
|
||||
Copyright (c) 1999-2005 Zend Technologies Ltd. All rights reserved.
|
||||
Copyright (c) 1999-2006 Zend Technologies Ltd. All rights reserved.
|
||||
--------------------------------------------------------------------
|
||||
|
||||
Redistribution and use in source and binary forms, with or without
|
||||
|
||||
+1
-1
@@ -15,7 +15,7 @@ libZend_la_SOURCES=\
|
||||
zend_list.c zend_indent.c zend_builtin_functions.c zend_sprintf.c \
|
||||
zend_ini.c zend_qsort.c zend_objects.c zend_object_handlers.c \
|
||||
zend_objects_API.c zend_ts_hash.c zend_stream.c zend_mm.c \
|
||||
zend_default_classes.c zend_reflection_api.c \
|
||||
zend_default_classes.c \
|
||||
zend_iterators.c zend_interfaces.c zend_exceptions.c \
|
||||
zend_strtod.c zend_multibyte.c
|
||||
|
||||
|
||||
@@ -227,10 +227,6 @@ SOURCE=.\zend_qsort.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_reflection_api.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_sprintf.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
@@ -407,10 +403,6 @@ SOURCE=.\zend_qsort.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_reflection_api.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_stack.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
@@ -260,10 +260,6 @@ SOURCE=.\zend_qsort.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_reflection_api.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_sprintf.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
@@ -444,10 +440,6 @@ SOURCE=.\zend_qsort.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_reflection_api.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_stack.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
+1
-1
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
+1
-1
@@ -4,7 +4,7 @@ dnl This file contains local autoconf functions.
|
||||
|
||||
AC_DEFUN([LIBZEND_BISON_CHECK],[
|
||||
# we only support certain bison versions
|
||||
bison_version_list="1.28 1.35 1.75 1.875 2.0 2.1"
|
||||
bison_version_list="1.28 1.35 1.75 1.875 2.0 2.1 2.2 2.3"
|
||||
|
||||
# for standalone build of Zend Engine
|
||||
test -z "$SED" && SED=sed
|
||||
|
||||
+3
-3
@@ -179,7 +179,7 @@ function fibo($n) {
|
||||
|
||||
/****/
|
||||
|
||||
function hash($n) {
|
||||
function hash1($n) {
|
||||
for ($i = 1; $i <= $n; $i++) {
|
||||
$X[dechex($i)] = $i;
|
||||
}
|
||||
@@ -401,8 +401,8 @@ ary3(2000);
|
||||
$t = end_test($t, "ary3(2000)");
|
||||
fibo(30);
|
||||
$t = end_test($t, "fibo(30)");
|
||||
hash(50000);
|
||||
$t = end_test($t, "hash(50000)");
|
||||
hash1(50000);
|
||||
$t = end_test($t, "hash1(50000)");
|
||||
hash2(500);
|
||||
$t = end_test($t, "hash2(500)");
|
||||
heapsort(20000);
|
||||
|
||||
+1
-1
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
@@ -0,0 +1,24 @@
|
||||
--TEST--
|
||||
Test for abstract static classes
|
||||
--FILE--
|
||||
<?php
|
||||
abstract class ezcDbHandler extends PDO
|
||||
{
|
||||
public function __construct( $dbParams, $dsn )
|
||||
{
|
||||
$user = null;
|
||||
$pass = null;
|
||||
$driverOptions = null;
|
||||
}
|
||||
|
||||
abstract static public function getName();
|
||||
|
||||
static public function hasFeature( $feature )
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
?>
|
||||
DONE
|
||||
--EXPECT--
|
||||
DONE
|
||||
@@ -1,5 +1,5 @@
|
||||
--TEST--
|
||||
Bug #26077 Memory leaks when creating an instance of an object
|
||||
Bug #26077 (Memory leaks when creating an instance of an object)
|
||||
--FILE--
|
||||
<?php
|
||||
class foo {} new foo();
|
||||
|
||||
@@ -89,7 +89,7 @@ if (is_callable(array('test_class','test_func4'))) {
|
||||
$object = new foo();
|
||||
$object->test();
|
||||
?>
|
||||
--EXPECT--
|
||||
--EXPECTF--
|
||||
test_func1
|
||||
test_func2
|
||||
test_func3
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
--TEST--
|
||||
Bug 30346 (arrayAcces & using $this)
|
||||
Bug #30346 (arrayAccess and using $this)
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
@@ -21,4 +21,4 @@ echo "\n";
|
||||
===DONE===
|
||||
--EXPECT--
|
||||
page_show
|
||||
===DONE===
|
||||
===DONE===
|
||||
@@ -1,5 +1,5 @@
|
||||
--TEST--
|
||||
Bug #31177 (menory corruption because of incorrect refcounting)
|
||||
Bug #31177 (memory corruption because of incorrect refcounting)
|
||||
--FILE--
|
||||
<?php
|
||||
class foo {
|
||||
|
||||
@@ -20,7 +20,7 @@ foreach ($a as $v) {
|
||||
--EXPECT--
|
||||
'$ \{ '
|
||||
' \{ $'
|
||||
' {$ '
|
||||
' \{$ '
|
||||
' $\{ '
|
||||
' $\{ '
|
||||
' \{$ '
|
||||
|
||||
@@ -7,7 +7,31 @@ class TestA
|
||||
{
|
||||
public function doSomething($i)
|
||||
{
|
||||
echo __METHOD__ . "($this)\n";
|
||||
echo __METHOD__ . "($i)\n";
|
||||
return --$i;
|
||||
}
|
||||
|
||||
public function doSomethingThis($i)
|
||||
{
|
||||
echo __METHOD__ . "($i)\n";
|
||||
return --$i;
|
||||
}
|
||||
|
||||
public function doSomethingParent($i)
|
||||
{
|
||||
echo __METHOD__ . "($i)\n";
|
||||
return --$i;
|
||||
}
|
||||
|
||||
public function doSomethingParentThis($i)
|
||||
{
|
||||
echo __METHOD__ . "($i)\n";
|
||||
return --$i;
|
||||
}
|
||||
|
||||
public static function doSomethingStatic($i)
|
||||
{
|
||||
echo __METHOD__ . "($i)\n";
|
||||
return --$i;
|
||||
}
|
||||
}
|
||||
@@ -16,20 +40,87 @@ class TestB extends TestA
|
||||
{
|
||||
public function doSomething($i)
|
||||
{
|
||||
echo __METHOD__ . "($this)\n";
|
||||
echo __METHOD__ . "($i)\n";
|
||||
$i++;
|
||||
if ($i >= 5) return 5;
|
||||
return call_user_func_array(array("TestA","doSomething"), array($i));
|
||||
return call_user_func_array(array("TestA", "doSomething"), array($i));
|
||||
}
|
||||
|
||||
public function doSomethingThis($i)
|
||||
{
|
||||
echo __METHOD__ . "($i)\n";
|
||||
$i++;
|
||||
if ($i >= 5) return 5;
|
||||
return call_user_func_array(array($this, "TestA::doSomethingThis"), array($i));
|
||||
}
|
||||
|
||||
public function doSomethingParent($i)
|
||||
{
|
||||
echo __METHOD__ . "($i)\n";
|
||||
$i++;
|
||||
if ($i >= 5) return 5;
|
||||
return call_user_func_array(array("parent", "doSomethingParent"), array($i));
|
||||
}
|
||||
|
||||
public function doSomethingParentThis($i)
|
||||
{
|
||||
echo __METHOD__ . "($i)\n";
|
||||
$i++;
|
||||
if ($i >= 5) return 5;
|
||||
return call_user_func_array(array($this, "parent::doSomethingParentThis"), array($i));
|
||||
}
|
||||
|
||||
public static function doSomethingStatic($i)
|
||||
{
|
||||
echo __METHOD__ . "($i)\n";
|
||||
$i++;
|
||||
if ($i >= 5) return 5;
|
||||
return call_user_func_array(array("TestA", "doSomethingStatic"), array($i));
|
||||
}
|
||||
}
|
||||
|
||||
$x = new TestB();
|
||||
echo "===A===\n";
|
||||
var_dump($x->doSomething(1));
|
||||
echo "\n===B===\n";
|
||||
var_dump($x->doSomethingThis(1));
|
||||
echo "\n===C===\n";
|
||||
var_dump($x->doSomethingParent(1));
|
||||
echo "\n===D===\n";
|
||||
var_dump($x->doSomethingParentThis(1));
|
||||
echo "\n===E===\n";
|
||||
var_dump($x->doSomethingStatic(1));
|
||||
|
||||
?>
|
||||
===DONE===
|
||||
<?php exit(0); ?>
|
||||
--EXPECTF--
|
||||
TestB::doSomething(Object id #%d)
|
||||
TestA::doSomething(Object id #%d)
|
||||
===A===
|
||||
TestB::doSomething(1)
|
||||
|
||||
Strict Standards: Non-static method TestA::doSomething() cannot be called statically, assuming $this from compatible context TestB in %sbug32290.php on line %d
|
||||
TestA::doSomething(2)
|
||||
int(1)
|
||||
|
||||
===B===
|
||||
TestB::doSomethingThis(1)
|
||||
TestA::doSomethingThis(2)
|
||||
int(1)
|
||||
|
||||
===C===
|
||||
TestB::doSomethingParent(1)
|
||||
|
||||
Strict Standards: Non-static method TestA::doSomethingParent() cannot be called statically, assuming $this from compatible context TestB in %sbug32290.php on line %d
|
||||
TestA::doSomethingParent(2)
|
||||
int(1)
|
||||
|
||||
===D===
|
||||
TestB::doSomethingParentThis(1)
|
||||
TestA::doSomethingParentThis(2)
|
||||
int(1)
|
||||
|
||||
===E===
|
||||
TestB::doSomethingStatic(1)
|
||||
TestA::doSomethingStatic(2)
|
||||
int(1)
|
||||
===DONE===
|
||||
@@ -1,5 +1,5 @@
|
||||
--TEST--
|
||||
bug #34873 (Segmentation Fault on foreach in object)
|
||||
Bug #34873 (Segmentation Fault on foreach in object)
|
||||
--FILE--
|
||||
<?php
|
||||
class pwa {
|
||||
|
||||
Executable
+30
@@ -0,0 +1,30 @@
|
||||
--TEST--
|
||||
Bug #35393 (changing static protected members from outside the class)
|
||||
--INI--
|
||||
error_reporting=4095
|
||||
--FILE--
|
||||
<?php
|
||||
class ObjectPath
|
||||
{
|
||||
static protected $type = array(0=>'main');
|
||||
|
||||
static function getType()
|
||||
{
|
||||
return self::$type;
|
||||
}
|
||||
}
|
||||
print_r(ObjectPath::getType());
|
||||
$object_type = array_pop((ObjectPath::getType()));
|
||||
print_r(ObjectPath::getType());
|
||||
?>
|
||||
--EXPECTF--
|
||||
Array
|
||||
(
|
||||
[0] => main
|
||||
)
|
||||
|
||||
Strict Standards: Only variables should be passed by reference in %sbug35393.php on line 12
|
||||
Array
|
||||
(
|
||||
[0] => main
|
||||
)
|
||||
Executable
+19
@@ -0,0 +1,19 @@
|
||||
--TEST--
|
||||
Bug #35411 (Regression with \{$ handling)
|
||||
--FILE--
|
||||
<?php
|
||||
$abc = "bar";
|
||||
echo "foo\{$abc}baz\n";
|
||||
echo "foo\{ $abc}baz\n";
|
||||
echo <<<TEST
|
||||
foo{$abc}baz
|
||||
foo\{$abc}baz
|
||||
foo\{ $abc}baz
|
||||
TEST;
|
||||
?>
|
||||
--EXPECT--
|
||||
foo\{bar}baz
|
||||
foo\{ bar}baz
|
||||
foobarbaz
|
||||
foo\{bar}baz
|
||||
foo\{ bar}baz
|
||||
Executable
+27
@@ -0,0 +1,27 @@
|
||||
--TEST--
|
||||
Bug #35437 Segfault or Invalid Opcode 137/1/4
|
||||
--FILE--
|
||||
<?php
|
||||
function err2exception($errno, $errstr)
|
||||
{
|
||||
throw new Exception("Error occuried: " . $errstr);
|
||||
}
|
||||
|
||||
set_error_handler('err2exception');
|
||||
|
||||
class TestClass
|
||||
{
|
||||
function testMethod()
|
||||
{
|
||||
$GLOBALS['t'] = new stdClass;
|
||||
}
|
||||
}
|
||||
|
||||
try {
|
||||
TestClass::testMethod();
|
||||
} catch (Exception $e) {
|
||||
echo "Catched: ".$e->getMessage()."\n";
|
||||
}
|
||||
?>
|
||||
--EXPECT--
|
||||
Catched: Error occuried: Non-static method TestClass::testMethod() should not be called statically
|
||||
Executable
+11
@@ -0,0 +1,11 @@
|
||||
--TEST--
|
||||
Bug #35470 (Assigning global using variable name from array doesn't function)
|
||||
--FILE--
|
||||
<?php
|
||||
$x = array("test", "55");
|
||||
global ${$x[0]};
|
||||
${$x[0]} = $x[1];
|
||||
echo "Test: $test\n";;
|
||||
?>
|
||||
--EXPECT--
|
||||
Test: 55
|
||||
Executable
+31
@@ -0,0 +1,31 @@
|
||||
--TEST--
|
||||
Bug #35509 (string constant as array key has different behavior inside object)
|
||||
--FILE--
|
||||
<?php
|
||||
class mytest
|
||||
{
|
||||
const classConstant = '01';
|
||||
|
||||
private $classArray = array( mytest::classConstant => 'value' );
|
||||
|
||||
public function __construct()
|
||||
{
|
||||
print_r($this->classArray);
|
||||
}
|
||||
}
|
||||
|
||||
$classtest = new mytest();
|
||||
|
||||
define( "normalConstant", '01' );
|
||||
$normalArray = array( normalConstant => 'value' );
|
||||
print_r($normalArray);
|
||||
?>
|
||||
--EXPECT--
|
||||
Array
|
||||
(
|
||||
[01] => value
|
||||
)
|
||||
Array
|
||||
(
|
||||
[01] => value
|
||||
)
|
||||
Executable
+25
@@ -0,0 +1,25 @@
|
||||
--TEST--
|
||||
Bug #35655 (whitespace following end of heredoc is lost)
|
||||
--INI--
|
||||
highlight.string = #DD0000
|
||||
highlight.comment = #FF8000
|
||||
highlight.keyword = #007700
|
||||
highlight.bg = #FFFFFF
|
||||
highlight.default = #0000BB
|
||||
highlight.html = #000000
|
||||
--FILE--
|
||||
<?php
|
||||
$code = '
|
||||
<?php
|
||||
$x = <<<EOT
|
||||
some string
|
||||
EOT
|
||||
$y = 2;
|
||||
?>';
|
||||
highlight_string($code);
|
||||
?>
|
||||
--EXPECT--
|
||||
<code><span style="color: #000000">
|
||||
<br /><span style="color: #0000BB"><?php<br /> $x </span><span style="color: #007700">= <<<EOT<br /></span><span style="color: #0000BB">some string <br /></span><span style="color: #007700">EOT<br /> </span><span style="color: #0000BB">$y </span><span style="color: #007700">= </span><span style="color: #0000BB">2</span><span style="color: #007700">;<br /></span><span style="color: #0000BB">?></span>
|
||||
</span>
|
||||
</code>
|
||||
Executable
+30
@@ -0,0 +1,30 @@
|
||||
--TEST--
|
||||
Bug #36006 (Problem with $this in __destruct())
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
class Person {
|
||||
public $dad;
|
||||
public function __destruct() {
|
||||
$this->dad = null; /* no segfault if this is commented out */
|
||||
}
|
||||
}
|
||||
|
||||
class Dad extends Person {
|
||||
public $son;
|
||||
public function __construct() {
|
||||
$this->son = new Person;
|
||||
$this->son->dad = $this; /* no segfault if this is commented out */
|
||||
}
|
||||
public function __destruct() {
|
||||
$this->son = null;
|
||||
parent::__destruct(); /* segfault here */
|
||||
}
|
||||
}
|
||||
|
||||
$o = new Dad;
|
||||
unset($o);
|
||||
echo "ok\n";
|
||||
?>
|
||||
--EXPECT--
|
||||
ok
|
||||
Executable
+14
@@ -0,0 +1,14 @@
|
||||
--TEST--
|
||||
Bug #36037 (heredoc adds extra line number)
|
||||
--FILE--
|
||||
<?php
|
||||
echo __LINE__, "\n";
|
||||
$x=<<<XXX
|
||||
123
|
||||
YYY;
|
||||
XXX;
|
||||
echo __LINE__, "\n";
|
||||
?>
|
||||
--EXPECT--
|
||||
2
|
||||
7
|
||||
Executable
+13
@@ -0,0 +1,13 @@
|
||||
--TEST--
|
||||
Bug #36071 (Engine Crash related with 'clone')
|
||||
--INI--
|
||||
error_reporting=4095
|
||||
--FILE--
|
||||
<?php
|
||||
$a = clone 0;
|
||||
$a[0]->b = 0;
|
||||
echo "ok\n";
|
||||
?>
|
||||
--EXPECTF--
|
||||
Warning: __clone method called on non-object in %sbug36071.php on line 2
|
||||
ok
|
||||
Executable
+14
@@ -0,0 +1,14 @@
|
||||
--TEST--
|
||||
Bug #36268 (Object destructors called even after fatal errors)
|
||||
--FILE--
|
||||
<?php
|
||||
class Foo {
|
||||
function __destruct() {
|
||||
echo "Ha!\n";
|
||||
}
|
||||
}
|
||||
$x = new Foo();
|
||||
bar();
|
||||
?>
|
||||
--EXPECTF--
|
||||
Fatal error: Call to undefined function bar() in %sbug36268.php on line 8
|
||||
Executable
+12
@@ -0,0 +1,12 @@
|
||||
--TEST--
|
||||
Bug #36303 (foreach on error_zval produces segfault)
|
||||
--FILE--
|
||||
<?php
|
||||
$x="test";
|
||||
foreach($x->a->b as &$v) {
|
||||
}
|
||||
echo "ok\n";
|
||||
?>
|
||||
--EXPECTF--
|
||||
Warning: Invalid argument supplied for foreach() in %sbug36303.php on line 3
|
||||
ok
|
||||
Executable
+22
@@ -0,0 +1,22 @@
|
||||
--TEST--
|
||||
Bug #36513 (comment will be outputed in last line)
|
||||
--FILE--
|
||||
<?php
|
||||
function test($s) {
|
||||
echo "'".trim(str_replace(" ", " ", htmlspecialchars_decode(strip_tags(highlight_string($s,1)))))."'\n";
|
||||
}
|
||||
|
||||
eval('echo "1";//2');
|
||||
eval('echo 3; //{ 4?>5');
|
||||
echo "\n";
|
||||
|
||||
//test('<?php echo "1";//');
|
||||
test('<?php echo "1";//2');
|
||||
test('<?php echo "1";//22');
|
||||
test('<?php echo 3; // 4 ?>5');
|
||||
?>
|
||||
--EXPECT--
|
||||
135
|
||||
'<?php echo "1";//2'
|
||||
'<?php echo "1";//22'
|
||||
'<?php echo 3; // 4 ?>5'
|
||||
Executable
+15
@@ -0,0 +1,15 @@
|
||||
--TEST--
|
||||
Bug #36568 (memory_limit has no effect)
|
||||
--SKIPIF--
|
||||
<?php
|
||||
if (!function_exists('memory_get_usage')) die('skip PHP is configured without memory_limit');
|
||||
?>
|
||||
--INI--
|
||||
memory_limit=16M
|
||||
--FILE--
|
||||
<?php
|
||||
ini_set("memory_limit", "32M");
|
||||
echo ini_get("memory_limit");
|
||||
?>
|
||||
--EXPECT--
|
||||
32M
|
||||
Executable
+23
@@ -0,0 +1,23 @@
|
||||
--TEST--
|
||||
Bug #37046 (foreach breaks static scope)
|
||||
--FILE--
|
||||
<?php
|
||||
function s() {
|
||||
static $storage = array(array('x', 'y'));
|
||||
return $storage[0];
|
||||
}
|
||||
|
||||
foreach (s() as $k => $function) {
|
||||
echo "op1 $k\n";
|
||||
if ($k == 0) {
|
||||
foreach (s() as $k => $function) {
|
||||
echo "op2 $k\n";
|
||||
}
|
||||
}
|
||||
}
|
||||
?>
|
||||
--EXPECT--
|
||||
op1 0
|
||||
op2 0
|
||||
op2 1
|
||||
op1 1
|
||||
Executable
+21
@@ -0,0 +1,21 @@
|
||||
--TEST--
|
||||
Bug #37138 (__autoload tries to load callback'ed self and parent)
|
||||
--FILE--
|
||||
<?php
|
||||
function __autoload ($CN) {var_dump ($CN);}
|
||||
class st {
|
||||
public static function e () {echo ("EHLO\n");}
|
||||
public static function e2 () {call_user_func (array ('self', 'e'));}
|
||||
}
|
||||
class stch extends st {
|
||||
public static function g () {call_user_func (array ('parent', 'e'));}
|
||||
}
|
||||
st::e ();
|
||||
st::e2 ();
|
||||
stch::g ();
|
||||
?>
|
||||
--EXPECT--
|
||||
EHLO
|
||||
EHLO
|
||||
EHLO
|
||||
|
||||
@@ -0,0 +1,21 @@
|
||||
--TEST--
|
||||
Test whether an object is NULL or not.
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
class Bla
|
||||
{
|
||||
}
|
||||
|
||||
$b = new Bla;
|
||||
|
||||
var_dump($b != null);
|
||||
var_dump($b == null);
|
||||
var_dump($b !== null);
|
||||
var_dump($b === null);
|
||||
?>
|
||||
--EXPECT--
|
||||
bool(true)
|
||||
bool(false)
|
||||
bool(true)
|
||||
bool(false)
|
||||
@@ -0,0 +1,19 @@
|
||||
--TEST--
|
||||
zend_strtod() leaks on big doubles
|
||||
--INI--
|
||||
precision=14
|
||||
--FILE--
|
||||
<?php
|
||||
var_dump("1139932690.21688500" - "1139932790.21688500");
|
||||
var_dump("1139932690000.21688500" - "331139932790.21688500");
|
||||
var_dump("339932690.21688500" - "4564645646456463461139932790.21688500");
|
||||
var_dump("123123139932690.21688500" - "11399327900000000.21688500");
|
||||
|
||||
echo "Done\n";
|
||||
?>
|
||||
--EXPECTF--
|
||||
float(-100)
|
||||
float(808792757210)
|
||||
float(-4.5646456464565E+27)
|
||||
float(-11276204760067000)
|
||||
Done
|
||||
+25
-6
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
@@ -102,7 +102,7 @@ ZEND_API zval zval_used_for_init; /* True global variable */
|
||||
/* version information */
|
||||
static char *zend_version_info;
|
||||
static uint zend_version_info_length;
|
||||
#define ZEND_CORE_VERSION_INFO "Zend Engine v" ZEND_VERSION ", Copyright (c) 1998-2005 Zend Technologies\n"
|
||||
#define ZEND_CORE_VERSION_INFO "Zend Engine v" ZEND_VERSION ", Copyright (c) 1998-2006 Zend Technologies\n"
|
||||
|
||||
|
||||
#define PRINT_ZVAL_INDENT 4
|
||||
@@ -237,11 +237,19 @@ ZEND_API void zend_make_printable_zval(zval *expr, zval *expr_copy, int *use_cop
|
||||
} else {
|
||||
if(Z_OBJ_HANDLER_P(expr, get)) {
|
||||
zval *z = Z_OBJ_HANDLER_P(expr, get)(expr TSRMLS_CC);
|
||||
|
||||
z->refcount++;
|
||||
if(Z_TYPE_P(z) != IS_OBJECT) {
|
||||
zend_make_printable_zval(z, expr_copy, use_copy);
|
||||
FREE_ZVAL(z);
|
||||
if (*use_copy) {
|
||||
zval_ptr_dtor(&z);
|
||||
} else {
|
||||
ZVAL_ZVAL(expr_copy, z, 0, 1);
|
||||
*use_copy = 1;
|
||||
}
|
||||
return;
|
||||
}
|
||||
zval_ptr_dtor(&z);
|
||||
}
|
||||
}
|
||||
if (EG(exception)) {
|
||||
@@ -453,6 +461,13 @@ static void compiler_globals_ctor(zend_compiler_globals *compiler_globals TSRMLS
|
||||
compiler_globals->auto_globals = (HashTable *) malloc(sizeof(HashTable));
|
||||
zend_hash_init_ex(compiler_globals->auto_globals, 8, NULL, NULL, 1, 0);
|
||||
zend_hash_copy(compiler_globals->auto_globals, global_auto_globals_table, NULL, NULL, sizeof(zend_auto_global) /* empty element */);
|
||||
|
||||
compiler_globals->last_static_member = zend_hash_num_elements(compiler_globals->class_table);
|
||||
if (compiler_globals->last_static_member) {
|
||||
compiler_globals->static_members = (HashTable**)calloc(compiler_globals->last_static_member, sizeof(HashTable*));
|
||||
} else {
|
||||
compiler_globals->static_members = NULL;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -470,6 +485,10 @@ static void compiler_globals_dtor(zend_compiler_globals *compiler_globals TSRMLS
|
||||
zend_hash_destroy(compiler_globals->auto_globals);
|
||||
free(compiler_globals->auto_globals);
|
||||
}
|
||||
if (compiler_globals->static_members) {
|
||||
free(compiler_globals->static_members);
|
||||
}
|
||||
compiler_globals->last_static_member = 0;
|
||||
}
|
||||
|
||||
|
||||
@@ -858,7 +877,7 @@ static int exec_done_cb(zend_module_entry *module TSRMLS_DC)
|
||||
void zend_post_deactivate_modules(TSRMLS_D)
|
||||
{
|
||||
zend_hash_apply(&module_registry, (apply_func_t) exec_done_cb TSRMLS_CC);
|
||||
zend_hash_apply(&module_registry, (apply_func_t) module_registry_unload_temp TSRMLS_CC);
|
||||
zend_hash_reverse_apply(&module_registry, (apply_func_t) module_registry_unload_temp TSRMLS_CC);
|
||||
}
|
||||
|
||||
|
||||
@@ -1006,7 +1025,7 @@ ZEND_API void zend_error(int type, const char *format, ...)
|
||||
}
|
||||
zval_ptr_dtor(&retval);
|
||||
}
|
||||
} else {
|
||||
} else if (!EG(exception)) {
|
||||
/* The user error handler failed, use built-in error handler */
|
||||
zend_error_cb(type, error_filename, error_lineno, format, args);
|
||||
}
|
||||
@@ -1035,7 +1054,7 @@ ZEND_API void zend_error(int type, const char *format, ...)
|
||||
}
|
||||
}
|
||||
|
||||
#if defined(__GNUC__) && !defined(__INTEL_COMPILER) && !defined(DARWIN)
|
||||
#if defined(__GNUC__) && !defined(__INTEL_COMPILER) && !defined(DARWIN) && !defined(__hpux) && !defined(_AIX)
|
||||
void zend_error_noreturn(int type, const char *format, ...) __attribute__ ((alias("zend_error"),noreturn));
|
||||
#endif
|
||||
|
||||
|
||||
+5
-13
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
@@ -22,7 +22,7 @@
|
||||
#ifndef ZEND_H
|
||||
#define ZEND_H
|
||||
|
||||
#define ZEND_VERSION "2.1.0-dev"
|
||||
#define ZEND_VERSION "2.1.0"
|
||||
|
||||
#define ZEND_ENGINE_2
|
||||
|
||||
@@ -91,7 +91,7 @@ const char *zend_mh_bundle_error(void);
|
||||
|
||||
#endif /* HAVE_MACH_O_DYLD_H */
|
||||
|
||||
#if defined(HAVE_LIBDL) && !defined(HAVE_MACH_O_DYLD_H)
|
||||
#if defined(HAVE_LIBDL) && !defined(HAVE_MACH_O_DYLD_H) && !defined(ZEND_WIN32)
|
||||
|
||||
# ifndef RTLD_LAZY
|
||||
# define RTLD_LAZY 1 /* Solaris 1, FreeBSD's (2.1.7.1 and older) */
|
||||
@@ -171,7 +171,7 @@ char *alloca ();
|
||||
# define ZEND_ATTRIBUTE_FORMAT(type, idx, first)
|
||||
#endif
|
||||
|
||||
#if ZEND_GCC_VERSION >= 3001
|
||||
#if ZEND_GCC_VERSION >= 3001 && !defined(__INTEL_COMPILER)
|
||||
# define ZEND_ATTRIBUTE_PTR_FORMAT(type, idx, first) __attribute__ ((format(type, idx, first)))
|
||||
#else
|
||||
# define ZEND_ATTRIBUTE_PTR_FORMAT(type, idx, first)
|
||||
@@ -250,7 +250,7 @@ char *alloca ();
|
||||
#define INTERNAL_FUNCTION_PARAMETERS int ht, zval *return_value, zval **return_value_ptr, zval *this_ptr, int return_value_used TSRMLS_DC
|
||||
#define INTERNAL_FUNCTION_PARAM_PASSTHRU ht, return_value, return_value_ptr, this_ptr, return_value_used TSRMLS_CC
|
||||
|
||||
#if defined(__GNUC__) && !defined(__INTEL_COMPILER) && !defined(DARWIN)
|
||||
#if defined(__GNUC__) && !defined(__INTEL_COMPILER) && !defined(DARWIN) && !defined(__hpux) && !defined(_AIX)
|
||||
# define ZEND_VM_ALWAYS_INLINE __attribute__ ((always_inline))
|
||||
void zend_error_noreturn(int type, const char *format, ...) __attribute__ ((noreturn));
|
||||
#else
|
||||
@@ -279,16 +279,8 @@ typedef struct _zend_object {
|
||||
HashTable *guards; /* protects from __get/__set ... recursion */
|
||||
} zend_object;
|
||||
|
||||
typedef unsigned int zend_object_handle;
|
||||
typedef struct _zend_object_value zend_object_value;
|
||||
|
||||
#include "zend_object_handlers.h"
|
||||
|
||||
struct _zend_object_value {
|
||||
zend_object_handle handle;
|
||||
zend_object_handlers *handlers;
|
||||
};
|
||||
|
||||
typedef union _zvalue_value {
|
||||
long lval; /* long value */
|
||||
double dval; /* double value */
|
||||
|
||||
+184
-86
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
@@ -271,7 +271,7 @@ ZEND_API int zend_get_object_classname(zval *object, char **class_name, zend_uin
|
||||
}
|
||||
|
||||
|
||||
static char *zend_parse_arg_impl(zval **arg, va_list *va, char **spec TSRMLS_DC)
|
||||
static char *zend_parse_arg_impl(int arg_num, zval **arg, va_list *va, char **spec TSRMLS_DC)
|
||||
{
|
||||
char *spec_walk = *spec;
|
||||
char c = *spec_walk++;
|
||||
@@ -445,6 +445,21 @@ static char *zend_parse_arg_impl(zval **arg, va_list *va, char **spec TSRMLS_DC)
|
||||
}
|
||||
break;
|
||||
|
||||
case 'h':
|
||||
{
|
||||
HashTable **p = va_arg(*va, HashTable **);
|
||||
if (Z_TYPE_PP(arg) != IS_ARRAY) {
|
||||
if (Z_TYPE_PP(arg) == IS_NULL && return_null) {
|
||||
*p = NULL;
|
||||
} else {
|
||||
return "array";
|
||||
}
|
||||
} else {
|
||||
*p = Z_ARRVAL_PP(arg);
|
||||
}
|
||||
}
|
||||
break;
|
||||
|
||||
case 'o':
|
||||
{
|
||||
zval **p = va_arg(*va, zval **);
|
||||
@@ -477,6 +492,41 @@ static char *zend_parse_arg_impl(zval **arg, va_list *va, char **spec TSRMLS_DC)
|
||||
}
|
||||
break;
|
||||
|
||||
case 'C':
|
||||
{
|
||||
zend_class_entry **lookup, **pce = va_arg(*va, zend_class_entry **);
|
||||
zend_class_entry *ce_base = *pce;
|
||||
|
||||
convert_to_string_ex(arg);
|
||||
if (zend_lookup_class(Z_STRVAL_PP(arg), Z_STRLEN_PP(arg), &lookup TSRMLS_CC) == FAILURE) {
|
||||
*pce = NULL;
|
||||
} else {
|
||||
*pce = *lookup;
|
||||
}
|
||||
if (ce_base) {
|
||||
if ((!*pce || !instanceof_function(*pce, ce_base TSRMLS_CC)) && !return_null) {
|
||||
char *space;
|
||||
char *class_name = get_active_class_name(&space TSRMLS_CC);
|
||||
zend_error(E_WARNING, "%s%s%s() expects parameter %d to be a class name derived from %s, '%s' given",
|
||||
class_name, space, get_active_function_name(TSRMLS_C),
|
||||
arg_num, ce_base->name, Z_STRVAL_PP(arg));
|
||||
*pce = NULL;
|
||||
return "";
|
||||
}
|
||||
}
|
||||
if (!*pce && !return_null) {
|
||||
char *space;
|
||||
char *class_name = get_active_class_name(&space TSRMLS_CC);
|
||||
zend_error(E_WARNING, "%s%s%s() expects parameter %d to be a valid class name, '%s' given",
|
||||
class_name, space, get_active_function_name(TSRMLS_C),
|
||||
arg_num, Z_STRVAL_PP(arg));
|
||||
return "";
|
||||
}
|
||||
break;
|
||||
|
||||
}
|
||||
break;
|
||||
|
||||
case 'z':
|
||||
{
|
||||
zval **p = va_arg(*va, zval **);
|
||||
@@ -510,7 +560,7 @@ static int zend_parse_arg(int arg_num, zval **arg, va_list *va, char **spec, int
|
||||
{
|
||||
char *expected_type = NULL;
|
||||
|
||||
expected_type = zend_parse_arg_impl(arg, va, spec TSRMLS_CC);
|
||||
expected_type = zend_parse_arg_impl(arg_num, arg, va, spec TSRMLS_CC);
|
||||
if (expected_type) {
|
||||
if (!quiet) {
|
||||
char *space;
|
||||
@@ -545,6 +595,7 @@ static int zend_parse_va_args(int num_args, char *type_spec, va_list *va, int fl
|
||||
case 'r': case 'a':
|
||||
case 'o': case 'O':
|
||||
case 'z': case 'Z':
|
||||
case 'C': case 'h':
|
||||
max_num_args++;
|
||||
break;
|
||||
|
||||
@@ -755,22 +806,27 @@ ZEND_API void zend_merge_properties(zval *obj, HashTable *properties, int destro
|
||||
|
||||
ZEND_API void zend_update_class_constants(zend_class_entry *class_type TSRMLS_DC)
|
||||
{
|
||||
if (!class_type->constants_updated || !class_type->static_members) {
|
||||
if (!class_type->constants_updated || !CE_STATIC_MEMBERS(class_type)) {
|
||||
zend_class_entry **scope = EG(in_execution)?&EG(scope):&CG(active_class_entry);
|
||||
zend_class_entry *old_scope = *scope;
|
||||
|
||||
*scope = class_type;
|
||||
zend_hash_apply_with_argument(&class_type->constants_table, (apply_func_arg_t) zval_update_constant, (void*)1 TSRMLS_CC);
|
||||
zend_hash_apply_with_argument(&class_type->default_properties, (apply_func_arg_t) zval_update_constant, (void *) 1 TSRMLS_CC);
|
||||
|
||||
if (!class_type->static_members) {
|
||||
if (!CE_STATIC_MEMBERS(class_type)) {
|
||||
HashPosition pos;
|
||||
zval **p;
|
||||
|
||||
if (class_type->parent) {
|
||||
zend_update_class_constants(class_type->parent TSRMLS_CC);
|
||||
}
|
||||
#if ZTS
|
||||
ALLOC_HASHTABLE(CG(static_members)[(long)(class_type->static_members)]);
|
||||
#else
|
||||
ALLOC_HASHTABLE(class_type->static_members);
|
||||
zend_hash_init(class_type->static_members, 0, NULL, ZVAL_PTR_DTOR, 0);
|
||||
#endif
|
||||
zend_hash_init(CE_STATIC_MEMBERS(class_type), 0, NULL, ZVAL_PTR_DTOR, 0);
|
||||
|
||||
zend_hash_internal_pointer_reset_ex(&class_type->default_static_members, &pos);
|
||||
while (zend_hash_get_current_data_ex(&class_type->default_static_members, (void**)&p, &pos) == SUCCESS) {
|
||||
@@ -784,10 +840,10 @@ ZEND_API void zend_update_class_constants(zend_class_entry *class_type TSRMLS_DC
|
||||
class_type->parent &&
|
||||
zend_hash_find(&class_type->parent->default_static_members, str_index, str_length, (void**)&q) == SUCCESS &&
|
||||
*p == *q &&
|
||||
zend_hash_find(class_type->parent->static_members, str_index, str_length, (void**)&q) == SUCCESS) {
|
||||
zend_hash_find(CE_STATIC_MEMBERS(class_type->parent), str_index, str_length, (void**)&q) == SUCCESS) {
|
||||
(*q)->refcount++;
|
||||
(*q)->is_ref = 1;
|
||||
zend_hash_add(class_type->static_members, str_index, str_length, (void**)q, sizeof(zval*), NULL);
|
||||
zend_hash_add(CE_STATIC_MEMBERS(class_type), str_index, str_length, (void**)q, sizeof(zval*), NULL);
|
||||
} else {
|
||||
zval *q;
|
||||
|
||||
@@ -795,12 +851,12 @@ ZEND_API void zend_update_class_constants(zend_class_entry *class_type TSRMLS_DC
|
||||
*q = **p;
|
||||
INIT_PZVAL(q);
|
||||
zval_copy_ctor(q);
|
||||
zend_hash_add(class_type->static_members, str_index, str_length, (void**)&q, sizeof(zval*), NULL);
|
||||
zend_hash_add(CE_STATIC_MEMBERS(class_type), str_index, str_length, (void**)&q, sizeof(zval*), NULL);
|
||||
}
|
||||
zend_hash_move_forward_ex(&class_type->default_static_members, &pos);
|
||||
}
|
||||
}
|
||||
zend_hash_apply_with_argument(class_type->static_members, (apply_func_arg_t) zval_update_constant, (void *) 1 TSRMLS_CC);
|
||||
zend_hash_apply_with_argument(CE_STATIC_MEMBERS(class_type), (apply_func_arg_t) zval_update_constant, (void *) 1 TSRMLS_CC);
|
||||
|
||||
*scope = old_scope;
|
||||
class_type->constants_updated = 1;
|
||||
@@ -1490,8 +1546,8 @@ ZEND_API int zend_register_functions(zend_class_entry *scope, zend_function_entr
|
||||
zend_function *ctor = NULL, *dtor = NULL, *clone = NULL, *__get = NULL, *__set = NULL, *__unset = NULL, *__isset = NULL, *__call = NULL;
|
||||
char *lowercase_name;
|
||||
int fname_len;
|
||||
char *lc_class_name;
|
||||
int class_name_len;
|
||||
char *lc_class_name = NULL;
|
||||
int class_name_len = 0;
|
||||
|
||||
if (type==MODULE_PERSISTENT) {
|
||||
error_type = E_CORE_WARNING;
|
||||
@@ -1534,8 +1590,10 @@ ZEND_API int zend_register_functions(zend_class_entry *scope, zend_function_entr
|
||||
}
|
||||
if (ptr->flags) {
|
||||
if (!(ptr->flags & ZEND_ACC_PPP_MASK)) {
|
||||
zend_error(error_type, "Invalid access level for %s%s%s() - access must be exactly one of public, protected or private", scope ? scope->name : "", scope ? "::" : "", ptr->fname);
|
||||
internal_function->fn_flags = ZEND_ACC_PUBLIC;
|
||||
if (ptr->flags != ZEND_ACC_DEPRECATED || scope) {
|
||||
zend_error(error_type, "Invalid access level for %s%s%s() - access must be exactly one of public, protected or private", scope ? scope->name : "", scope ? "::" : "", ptr->fname);
|
||||
}
|
||||
internal_function->fn_flags = ZEND_ACC_PUBLIC | ptr->flags;
|
||||
} else {
|
||||
internal_function->fn_flags = ptr->flags;
|
||||
}
|
||||
@@ -1797,11 +1855,7 @@ int module_registry_cleanup(zend_module_entry *module TSRMLS_DC)
|
||||
|
||||
int module_registry_unload_temp(zend_module_entry *module TSRMLS_DC)
|
||||
{
|
||||
switch (module->type) {
|
||||
case MODULE_TEMPORARY:
|
||||
return 1;
|
||||
}
|
||||
return 0;
|
||||
return (module->type == MODULE_TEMPORARY) ? ZEND_HASH_APPLY_REMOVE : ZEND_HASH_APPLY_STOP;
|
||||
}
|
||||
|
||||
|
||||
@@ -1970,16 +2024,101 @@ ZEND_API int zend_disable_class(char *class_name, uint class_name_length TSRMLS_
|
||||
return 1;
|
||||
}
|
||||
|
||||
static int zend_is_callable_check_func(int check_flags, zval ***zobj_ptr_ptr, zend_class_entry *ce_org, zval *callable, zend_class_entry **ce_ptr, zend_function **fptr_ptr TSRMLS_DC)
|
||||
{
|
||||
int retval;
|
||||
char *lcname, *lmname, *colon;
|
||||
int clen, mlen;
|
||||
zend_function *fptr;
|
||||
zend_class_entry **pce;
|
||||
HashTable *ftable;
|
||||
|
||||
*ce_ptr = NULL;
|
||||
*fptr_ptr = NULL;
|
||||
|
||||
if ((colon = strstr(Z_STRVAL_P(callable), "::")) != NULL) {
|
||||
clen = colon - Z_STRVAL_P(callable);
|
||||
mlen = Z_STRLEN_P(callable) - clen - 2;
|
||||
lcname = zend_str_tolower_dup(Z_STRVAL_P(callable), clen);
|
||||
/* caution: lcname is not '\0' terminated */
|
||||
if (clen == sizeof("self") - 1 && memcmp(lcname, "self", sizeof("self") - 1) == 0) {
|
||||
*ce_ptr = EG(scope);
|
||||
} else if (clen == sizeof("parent") - 1 && memcmp(lcname, "parent", sizeof("parent") - 1) == 0 && EG(active_op_array)->scope) {
|
||||
*ce_ptr = EG(scope) ? EG(scope)->parent : NULL;
|
||||
} else if (zend_lookup_class(Z_STRVAL_P(callable), clen, &pce TSRMLS_CC) == SUCCESS) {
|
||||
*ce_ptr = *pce;
|
||||
}
|
||||
efree(lcname);
|
||||
if (!*ce_ptr) {
|
||||
return 0;
|
||||
}
|
||||
ftable = &(*ce_ptr)->function_table;
|
||||
if (ce_org && !instanceof_function(ce_org, *ce_ptr TSRMLS_CC)) {
|
||||
return 0;
|
||||
}
|
||||
lmname = zend_str_tolower_dup(Z_STRVAL_P(callable) + clen + 2, mlen);
|
||||
} else {
|
||||
mlen = Z_STRLEN_P(callable);
|
||||
lmname = zend_str_tolower_dup(Z_STRVAL_P(callable), mlen);
|
||||
if (ce_org) {
|
||||
ftable = &ce_org->function_table;
|
||||
*ce_ptr = ce_org;
|
||||
} else {
|
||||
ftable = EG(function_table);
|
||||
}
|
||||
}
|
||||
|
||||
retval = zend_hash_find(ftable, lmname, mlen+1, (void**)&fptr) == SUCCESS ? 1 : 0;
|
||||
|
||||
if (!retval) {
|
||||
if (*zobj_ptr_ptr && *ce_ptr && (*ce_ptr)->__call != 0) {
|
||||
retval = (*ce_ptr)->__call != NULL;
|
||||
*fptr_ptr = (*ce_ptr)->__call;
|
||||
}
|
||||
} else {
|
||||
*fptr_ptr = fptr;
|
||||
if (*ce_ptr) {
|
||||
if (!*zobj_ptr_ptr && !(fptr->common.fn_flags & ZEND_ACC_STATIC)) {
|
||||
if ((check_flags & IS_CALLABLE_CHECK_IS_STATIC) != 0) {
|
||||
retval = 0;
|
||||
} else {
|
||||
if (EG(This) && instanceof_function(Z_OBJCE_P(EG(This)), *ce_ptr TSRMLS_CC)) {
|
||||
*zobj_ptr_ptr = &EG(This);
|
||||
zend_error(E_STRICT, "Non-static method %s::%s() cannot be called statically, assuming $this from compatible context %s", (*ce_ptr)->name, fptr->common.function_name, Z_OBJCE_P(EG(This))->name);
|
||||
} else {
|
||||
zend_error(E_STRICT, "Non-static method %s::%s() cannot be called statically", (*ce_ptr)->name, fptr->common.function_name);
|
||||
}
|
||||
}
|
||||
}
|
||||
if (retval && (check_flags & IS_CALLABLE_CHECK_NO_ACCESS) == 0) {
|
||||
if (fptr->op_array.fn_flags & ZEND_ACC_PRIVATE) {
|
||||
if (!zend_check_private(fptr, *zobj_ptr_ptr ? Z_OBJCE_PP(*zobj_ptr_ptr) : EG(scope), lmname, mlen TSRMLS_CC)) {
|
||||
retval = 0;
|
||||
}
|
||||
} else if ((fptr->common.fn_flags & ZEND_ACC_PROTECTED)) {
|
||||
if (!zend_check_protected(fptr->common.scope, EG(scope))) {
|
||||
retval = 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
efree(lmname);
|
||||
return retval;
|
||||
}
|
||||
|
||||
ZEND_API zend_bool zend_is_callable_ex(zval *callable, uint check_flags, char **callable_name, int *callable_name_len, zend_class_entry **ce_ptr, zend_function **fptr_ptr, zval ***zobj_ptr_ptr TSRMLS_DC)
|
||||
{
|
||||
char *lcname, *lmname, *colon;
|
||||
char *lcname;
|
||||
zend_bool retval = 0;
|
||||
int callable_name_len_local, clen, mlen;
|
||||
int callable_name_len_local;
|
||||
zend_class_entry *ce_local, **pce;
|
||||
zend_function *fptr_local;
|
||||
zval **zobj_ptr_local;
|
||||
HashTable *ftable;
|
||||
|
||||
if (callable_name) {
|
||||
*callable_name = NULL;
|
||||
}
|
||||
if (callable_name_len == NULL) {
|
||||
callable_name_len = &callable_name_len_local;
|
||||
}
|
||||
@@ -2006,33 +2145,7 @@ ZEND_API zend_bool zend_is_callable_ex(zval *callable, uint check_flags, char **
|
||||
return 1;
|
||||
}
|
||||
|
||||
if ((colon = strstr(Z_STRVAL_P(callable), "::")) != NULL) {
|
||||
clen = colon - Z_STRVAL_P(callable);
|
||||
mlen = Z_STRLEN_P(callable) - clen - 2;
|
||||
lcname = estrndup(Z_STRVAL_P(callable), clen);
|
||||
lcname[clen] = '\0';
|
||||
lmname = zend_str_tolower_dup(Z_STRVAL_P(callable) + clen + 2, mlen);
|
||||
if (zend_lookup_class(lcname, clen, &pce TSRMLS_CC) == FAILURE) {
|
||||
efree(lcname);
|
||||
efree(lmname);
|
||||
return 0;
|
||||
}
|
||||
efree(lcname);
|
||||
*ce_ptr = *pce;
|
||||
ftable = &(*ce_ptr)->function_table;
|
||||
} else {
|
||||
mlen = Z_STRLEN_P(callable);
|
||||
lmname = zend_str_tolower_dup(Z_STRVAL_P(callable), mlen);
|
||||
ftable = EG(function_table);
|
||||
}
|
||||
|
||||
if (zend_hash_find(ftable, lmname, mlen+1, (void**)fptr_ptr) == SUCCESS) {
|
||||
retval = 1;
|
||||
}
|
||||
if (*ce_ptr && *fptr_ptr && !((*fptr_ptr)->common.fn_flags & ZEND_ACC_STATIC)) {
|
||||
retval = 0;
|
||||
}
|
||||
efree(lmname);
|
||||
retval = zend_is_callable_check_func(check_flags|IS_CALLABLE_CHECK_IS_STATIC, zobj_ptr_ptr, NULL, callable, ce_ptr, fptr_ptr TSRMLS_CC);
|
||||
break;
|
||||
|
||||
case IS_ARRAY:
|
||||
@@ -2061,21 +2174,18 @@ ZEND_API zend_bool zend_is_callable_ex(zval *callable, uint check_flags, char **
|
||||
}
|
||||
|
||||
if (check_flags & IS_CALLABLE_CHECK_SYNTAX_ONLY) {
|
||||
*ce_ptr = ce;
|
||||
return 1;
|
||||
}
|
||||
|
||||
if (zend_lookup_class(Z_STRVAL_PP(obj), Z_STRLEN_PP(obj), &pce TSRMLS_CC) == SUCCESS) {
|
||||
lcname = zend_str_tolower_dup(Z_STRVAL_PP(obj), Z_STRLEN_PP(obj));
|
||||
if (Z_STRLEN_PP(obj) == sizeof("self") - 1 && memcmp(lcname, "self", sizeof("self")) == 0) {
|
||||
ce = EG(active_op_array)->scope;
|
||||
} else if (Z_STRLEN_PP(obj) == sizeof("parent") - 1 && memcmp(lcname, "parent", sizeof("parent")) == 0 && EG(active_op_array)->scope) {
|
||||
ce = EG(active_op_array)->scope->parent;
|
||||
} else if (zend_lookup_class(Z_STRVAL_PP(obj), Z_STRLEN_PP(obj), &pce TSRMLS_CC) == SUCCESS) {
|
||||
ce = *pce;
|
||||
} else if (EG(active_op_array)) {
|
||||
lcname = zend_str_tolower_dup(Z_STRVAL_PP(obj), Z_STRLEN_PP(obj));
|
||||
if (Z_STRLEN_PP(obj) == sizeof("self") - 1 && memcmp(lcname, "self", sizeof("self")) == 0) {
|
||||
ce = EG(active_op_array)->scope;
|
||||
} else if (Z_STRLEN_PP(obj) == sizeof("parent") - 1 && memcmp(lcname, "parent", sizeof("parent")) == 0 && EG(active_op_array)->scope) {
|
||||
ce = EG(active_op_array)->scope->parent;
|
||||
}
|
||||
efree(lcname);
|
||||
}
|
||||
efree(lcname);
|
||||
} else {
|
||||
ce = Z_OBJCE_PP(obj); /* TBFixed: what if it's overloaded? */
|
||||
|
||||
@@ -2100,38 +2210,12 @@ ZEND_API zend_bool zend_is_callable_ex(zval *callable, uint check_flags, char **
|
||||
}
|
||||
|
||||
if (ce) {
|
||||
zend_function *fbc;
|
||||
|
||||
lcname = zend_str_tolower_dup(Z_STRVAL_PP(method), Z_STRLEN_PP(method));
|
||||
if (zend_hash_find(&ce->function_table, lcname, Z_STRLEN_PP(method)+1, (void **)&fbc) == SUCCESS) {
|
||||
retval = 1;
|
||||
if ((check_flags & IS_CALLABLE_CHECK_NO_ACCESS) == 0) {
|
||||
if (fbc->op_array.fn_flags & ZEND_ACC_PRIVATE) {
|
||||
if (!zend_check_private(fbc, (Z_TYPE_PP(obj) == IS_STRING)?EG(scope):(*obj)->value.obj.handlers->get_class_entry(*obj TSRMLS_CC), lcname, Z_STRLEN_PP(method) TSRMLS_CC)) {
|
||||
retval = 0;
|
||||
}
|
||||
} else if ((fbc->common.fn_flags & ZEND_ACC_PROTECTED)) {
|
||||
if (!zend_check_protected(fbc->common.scope, EG(scope))) {
|
||||
retval = 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
*fptr_ptr = fbc;
|
||||
}
|
||||
/* check for __call too */
|
||||
if (retval == 0 && *zobj_ptr_ptr && ce->__call != 0) {
|
||||
retval = 1;
|
||||
*fptr_ptr = ce->__call;
|
||||
}
|
||||
efree(lcname);
|
||||
retval = zend_is_callable_check_func(check_flags, zobj_ptr_ptr, ce, *method, ce_ptr, fptr_ptr TSRMLS_CC);
|
||||
}
|
||||
} else if (callable_name) {
|
||||
*callable_name = estrndup("Array", sizeof("Array")-1);
|
||||
*callable_name_len = sizeof("Array") - 1;
|
||||
}
|
||||
if ((check_flags & IS_CALLABLE_CHECK_IS_STATIC) != 0 && !*zobj_ptr_ptr && (!*fptr_ptr || !((*fptr_ptr)->common.fn_flags & ZEND_ACC_STATIC))) {
|
||||
retval = 0;
|
||||
}
|
||||
*ce_ptr = ce;
|
||||
}
|
||||
break;
|
||||
@@ -2359,6 +2443,20 @@ ZEND_API int zend_declare_class_constant(zend_class_entry *ce, char *name, size_
|
||||
return zend_hash_update(&ce->constants_table, name, name_length+1, &value, sizeof(zval *), NULL);
|
||||
}
|
||||
|
||||
ZEND_API int zend_declare_class_constant_null(zend_class_entry *ce, char *name, size_t name_length TSRMLS_DC)
|
||||
{
|
||||
zval *constant;
|
||||
|
||||
if (ce->type & ZEND_INTERNAL_CLASS) {
|
||||
constant = malloc(sizeof(zval));
|
||||
} else {
|
||||
ALLOC_ZVAL(constant);
|
||||
}
|
||||
ZVAL_NULL(constant);
|
||||
INIT_PZVAL(constant);
|
||||
return zend_declare_class_constant(ce, name, name_length, constant TSRMLS_CC);
|
||||
}
|
||||
|
||||
ZEND_API int zend_declare_class_constant_long(zend_class_entry *ce, char *name, size_t name_length, long value TSRMLS_DC)
|
||||
{
|
||||
zval *constant;
|
||||
|
||||
+12
-1
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
@@ -50,7 +50,9 @@ typedef struct _zend_function_entry {
|
||||
|
||||
#define ZEND_NAMED_FE(zend_name, name, arg_info) ZEND_FENTRY(zend_name, name, arg_info, 0)
|
||||
#define ZEND_FE(name, arg_info) ZEND_FENTRY(name, ZEND_FN(name), arg_info, 0)
|
||||
#define ZEND_DEP_FE(name, arg_info) ZEND_FENTRY(name, ZEND_FN(name), arg_info, ZEND_ACC_DEPRECATED)
|
||||
#define ZEND_FALIAS(name, alias, arg_info) ZEND_FENTRY(name, ZEND_FN(alias), arg_info, 0)
|
||||
#define ZEND_DEP_FALIAS(name, alias, arg_info) ZEND_FENTRY(name, ZEND_FN(alias), arg_info, ZEND_ACC_DEPRECATED)
|
||||
#define ZEND_ME(classname, name, arg_info, flags) ZEND_FENTRY(name, ZEND_FN(classname##_##name), arg_info, flags)
|
||||
#define ZEND_ABSTRACT_ME(classname, name, arg_info) ZEND_FENTRY(name, NULL, arg_info, ZEND_ACC_PUBLIC|ZEND_ACC_ABSTRACT)
|
||||
#define ZEND_MALIAS(classname, name, alias, arg_info, flags) \
|
||||
@@ -146,6 +148,12 @@ typedef struct _zend_function_entry {
|
||||
#define INIT_OVERLOADED_CLASS_ENTRY(class_container, class_name, functions, handle_fcall, handle_propget, handle_propset) \
|
||||
INIT_OVERLOADED_CLASS_ENTRY_EX(class_container, class_name, functions, handle_fcall, handle_propget, handle_propset, NULL, NULL)
|
||||
|
||||
#ifdef ZTS
|
||||
# define CE_STATIC_MEMBERS(ce) (((ce)->type==ZEND_USER_CLASS)?(ce)->static_members:CG(static_members)[(long)(ce)->static_members])
|
||||
#else
|
||||
# define CE_STATIC_MEMBERS(ce) ((ce)->static_members)
|
||||
#endif
|
||||
|
||||
int zend_next_free_module(void);
|
||||
|
||||
BEGIN_EXTERN_C()
|
||||
@@ -198,6 +206,8 @@ ZEND_API void zend_wrong_param_count(TSRMLS_D);
|
||||
#define IS_CALLABLE_CHECK_NO_ACCESS (1<<1)
|
||||
#define IS_CALLABLE_CHECK_IS_STATIC (1<<2)
|
||||
|
||||
#define IS_CALLABLE_STRICT (IS_CALLABLE_CHECK_IS_STATIC)
|
||||
|
||||
ZEND_API zend_bool zend_is_callable_ex(zval *callable, uint check_flags, char **callable_name, int *callable_name_len, zend_class_entry **ce_ptr, zend_function **fptr_ptr, zval ***zobj_ptr_ptr TSRMLS_DC);
|
||||
ZEND_API zend_bool zend_is_callable(zval *callable, uint check_flags, char **callable_name);
|
||||
ZEND_API zend_bool zend_make_callable(zval *callable, char **callable_name TSRMLS_DC);
|
||||
@@ -213,6 +223,7 @@ ZEND_API int zend_declare_property_string(zend_class_entry *ce, char *name, int
|
||||
ZEND_API int zend_declare_property_stringl(zend_class_entry *ce, char *name, int name_length, char *value, int value_len, int access_type TSRMLS_DC);
|
||||
|
||||
ZEND_API int zend_declare_class_constant(zend_class_entry *ce, char *name, size_t name_length, zval *value TSRMLS_DC);
|
||||
ZEND_API int zend_declare_class_constant_null(zend_class_entry *ce, char *name, size_t name_length TSRMLS_DC);
|
||||
ZEND_API int zend_declare_class_constant_long(zend_class_entry *ce, char *name, size_t name_length, long value TSRMLS_DC);
|
||||
ZEND_API int zend_declare_class_constant_bool(zend_class_entry *ce, char *name, size_t name_length, zend_bool value TSRMLS_DC);
|
||||
ZEND_API int zend_declare_class_constant_double(zend_class_entry *ce, char *name, size_t name_length, double value TSRMLS_DC);
|
||||
|
||||
+27
-4
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
@@ -72,7 +72,15 @@ static long mem_block_end_magic = MEM_BLOCK_END_MAGIC;
|
||||
#define CHECK_MEMORY_LIMIT(s, rs) _CHECK_MEMORY_LIMIT(s, rs, NULL, 0)
|
||||
# endif
|
||||
|
||||
#define _CHECK_MEMORY_LIMIT(s, rs, file, lineno) { AG(allocated_memory) += rs;\
|
||||
#define _CHECK_MEMORY_LIMIT(s, rs, file, lineno) { if ((ssize_t)(rs) > (ssize_t)(INT_MAX - AG(allocated_memory))) { \
|
||||
if (file) { \
|
||||
fprintf(stderr, "Integer overflow in memory_limit check detected at %s:%d\n", file, lineno); \
|
||||
} else { \
|
||||
fprintf(stderr, "Integer overflow in memory_limit check detected\n"); \
|
||||
} \
|
||||
exit(1); \
|
||||
} \
|
||||
AG(allocated_memory) += rs;\
|
||||
if (AG(memory_limit)<AG(allocated_memory)) {\
|
||||
int php_mem_limit = AG(memory_limit); \
|
||||
AG(allocated_memory) -= rs; \
|
||||
@@ -127,7 +135,7 @@ static long mem_block_end_magic = MEM_BLOCK_END_MAGIC;
|
||||
#endif
|
||||
|
||||
#define DECLARE_CACHE_VARS() \
|
||||
unsigned int real_size; \
|
||||
size_t real_size; \
|
||||
unsigned int cache_index
|
||||
|
||||
#define REAL_SIZE(size) ((size+7) & ~0x7)
|
||||
@@ -142,12 +150,16 @@ static long mem_block_end_magic = MEM_BLOCK_END_MAGIC;
|
||||
|
||||
ZEND_API void *_emalloc(size_t size ZEND_FILE_LINE_DC ZEND_FILE_LINE_ORIG_DC)
|
||||
{
|
||||
zend_mem_header *p;
|
||||
zend_mem_header *p = NULL;
|
||||
DECLARE_CACHE_VARS();
|
||||
TSRMLS_FETCH();
|
||||
|
||||
CALCULATE_REAL_SIZE_AND_CACHE_INDEX(size);
|
||||
|
||||
if (size > INT_MAX || SIZE < size) {
|
||||
goto emalloc_error;
|
||||
}
|
||||
|
||||
#if !ZEND_DISABLE_MEMORY_CACHE
|
||||
if ((CACHE_INDEX < MAX_CACHED_MEMORY) && (AG(cache_count)[CACHE_INDEX] > 0)) {
|
||||
p = AG(cache)[CACHE_INDEX][--AG(cache_count)[CACHE_INDEX]];
|
||||
@@ -184,6 +196,8 @@ ZEND_API void *_emalloc(size_t size ZEND_FILE_LINE_DC ZEND_FILE_LINE_ORIG_DC)
|
||||
}
|
||||
#endif
|
||||
|
||||
emalloc_error:
|
||||
|
||||
HANDLE_BLOCK_INTERRUPTIONS();
|
||||
|
||||
if (!p) {
|
||||
@@ -357,6 +371,13 @@ ZEND_API void *_erealloc(void *ptr, size_t size, int allow_failure ZEND_FILE_LIN
|
||||
CALCULATE_REAL_SIZE_AND_CACHE_INDEX(size);
|
||||
|
||||
HANDLE_BLOCK_INTERRUPTIONS();
|
||||
|
||||
if (size > INT_MAX || SIZE < size) {
|
||||
REMOVE_POINTER_FROM_LIST(p);
|
||||
p = NULL;
|
||||
goto erealloc_error;
|
||||
}
|
||||
|
||||
#if MEMORY_LIMIT
|
||||
CHECK_MEMORY_LIMIT(size - p->size, SIZE - REAL_SIZE(p->size));
|
||||
if (AG(allocated_memory) > AG(allocated_memory_peak)) {
|
||||
@@ -365,6 +386,7 @@ ZEND_API void *_erealloc(void *ptr, size_t size, int allow_failure ZEND_FILE_LIN
|
||||
#endif
|
||||
REMOVE_POINTER_FROM_LIST(p);
|
||||
p = (zend_mem_header *) ZEND_DO_REALLOC(p, sizeof(zend_mem_header)+MEM_HEADER_PADDING+SIZE+END_MAGIC_SIZE);
|
||||
erealloc_error:
|
||||
if (!p) {
|
||||
if (!allow_failure) {
|
||||
fprintf(stderr,"FATAL: erealloc(): Unable to allocate %ld bytes\n", (long) size);
|
||||
@@ -558,6 +580,7 @@ ZEND_API void shutdown_memory_manager(int silent, int full_shutdown TSRMLS_DC)
|
||||
|
||||
grand_total_leaks++;
|
||||
if (!silent) {
|
||||
zend_message_dispatcher(ZMSG_LOG_SCRIPT_NAME, NULL);
|
||||
zend_message_dispatcher(ZMSG_MEMORY_LEAK_DETECTED, t);
|
||||
}
|
||||
t->reported = 1;
|
||||
|
||||
+2
-1
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
@@ -125,6 +125,7 @@ ZEND_API char *_estrndup(const char *s, unsigned int length ZEND_FILE_LINE_DC ZE
|
||||
|
||||
#else
|
||||
|
||||
#undef _GNU_SOURCE
|
||||
#define _GNU_SOURCE
|
||||
#include <string.h>
|
||||
#undef _GNU_SOURCE
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
@@ -40,6 +40,14 @@ ZEND_BEGIN_ARG_INFO(fourth_arg_force_ref, 0)
|
||||
ZEND_ARG_PASS_INFO(1)
|
||||
ZEND_END_ARG_INFO();
|
||||
|
||||
ZEND_BEGIN_ARG_INFO(fifth_arg_force_ref, 0)
|
||||
ZEND_ARG_PASS_INFO(0)
|
||||
ZEND_ARG_PASS_INFO(0)
|
||||
ZEND_ARG_PASS_INFO(0)
|
||||
ZEND_ARG_PASS_INFO(0)
|
||||
ZEND_ARG_PASS_INFO(1)
|
||||
ZEND_END_ARG_INFO();
|
||||
|
||||
ZEND_BEGIN_ARG_INFO(all_args_by_ref, 1)
|
||||
ZEND_END_ARG_INFO();
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
@@ -314,6 +314,12 @@ ZEND_FUNCTION(strncmp)
|
||||
convert_to_string_ex(s1);
|
||||
convert_to_string_ex(s2);
|
||||
convert_to_long_ex(s3);
|
||||
|
||||
if (Z_LVAL_PP(s3) < 0) {
|
||||
zend_error(E_WARNING, "Length must be greater than or equal to 0");
|
||||
RETURN_FALSE;
|
||||
}
|
||||
|
||||
RETURN_LONG(zend_binary_zval_strncmp(*s1, *s2, *s3));
|
||||
}
|
||||
/* }}} */
|
||||
@@ -347,6 +353,12 @@ ZEND_FUNCTION(strncasecmp)
|
||||
convert_to_string_ex(s1);
|
||||
convert_to_string_ex(s2);
|
||||
convert_to_long_ex(s3);
|
||||
|
||||
if (Z_LVAL_PP(s3) < 0) {
|
||||
zend_error(E_WARNING, "Length must be greater than or equal to 0");
|
||||
RETURN_FALSE;
|
||||
}
|
||||
|
||||
RETURN_LONG(zend_binary_zval_strncasecmp(*s1, *s2, *s3));
|
||||
}
|
||||
/* }}} */
|
||||
@@ -738,7 +750,7 @@ ZEND_FUNCTION(get_class_vars)
|
||||
array_init(return_value);
|
||||
add_class_vars(*pce, &(*pce)->default_properties, return_value TSRMLS_CC);
|
||||
zend_update_class_constants(*pce TSRMLS_CC);
|
||||
add_class_vars(*pce, (*pce)->static_members, return_value TSRMLS_CC);
|
||||
add_class_vars(*pce, CE_STATIC_MEMBERS(*pce), return_value TSRMLS_CC);
|
||||
}
|
||||
}
|
||||
/* }}} */
|
||||
@@ -768,11 +780,16 @@ ZEND_FUNCTION(get_object_vars)
|
||||
RETURN_FALSE;
|
||||
}
|
||||
|
||||
properties = Z_OBJ_HT_PP(obj)->get_properties(*obj TSRMLS_CC);
|
||||
|
||||
if (properties == NULL) {
|
||||
RETURN_FALSE;
|
||||
}
|
||||
|
||||
instanceof = EG(This) && instanceof_function(Z_OBJCE_P(EG(This)), Z_OBJCE_PP(obj) TSRMLS_CC);
|
||||
|
||||
array_init(return_value);
|
||||
|
||||
properties = Z_OBJ_HT_PP(obj)->get_properties(*obj TSRMLS_CC);
|
||||
zend_hash_internal_pointer_reset_ex(properties, &pos);
|
||||
|
||||
while (zend_hash_get_current_data_ex(properties, (void **) &value, &pos) == SUCCESS) {
|
||||
@@ -1693,8 +1710,6 @@ ZEND_FUNCTION(debug_print_backtrace)
|
||||
}
|
||||
}
|
||||
|
||||
array_init(return_value);
|
||||
|
||||
while (ptr) {
|
||||
char *free_class_name = NULL;
|
||||
|
||||
@@ -1801,7 +1816,11 @@ ZEND_FUNCTION(debug_print_backtrace)
|
||||
debug_print_backtrace_args(arg_array TSRMLS_CC);
|
||||
zval_ptr_dtor(&arg_array);
|
||||
}
|
||||
zend_printf(") called at [%s:%d]\n", filename, lineno);
|
||||
if (filename) {
|
||||
zend_printf(") called at [%s:%d]\n", filename, lineno);
|
||||
} else {
|
||||
ZEND_PUTS(")\n");
|
||||
}
|
||||
include_filename = filename;
|
||||
ptr = skip->prev_execute_data;
|
||||
++indent;
|
||||
@@ -1813,7 +1832,7 @@ ZEND_FUNCTION(debug_print_backtrace)
|
||||
|
||||
/* }}} */
|
||||
|
||||
ZEND_API void zend_fetch_debug_backtrace(zval *return_value, int skip_last TSRMLS_DC)
|
||||
ZEND_API void zend_fetch_debug_backtrace(zval *return_value, int skip_last, int provide_object TSRMLS_DC)
|
||||
{
|
||||
zend_execute_data *ptr, *skip;
|
||||
int lineno;
|
||||
@@ -1913,6 +1932,11 @@ ZEND_API void zend_fetch_debug_backtrace(zval *return_value, int skip_last TSRML
|
||||
add_assoc_string_ex(stack_frame, "class", sizeof("class"), class_name, dup);
|
||||
|
||||
}
|
||||
if (provide_object) {
|
||||
add_assoc_zval_ex(stack_frame, "object", sizeof("object"), ptr->object);
|
||||
ptr->object->refcount++;
|
||||
}
|
||||
|
||||
add_assoc_string_ex(stack_frame, "type", sizeof("type"), "->", 1);
|
||||
} else if (ptr->function_state.function->common.scope) {
|
||||
add_assoc_string_ex(stack_frame, "class", sizeof("class"), ptr->function_state.function->common.scope->name, 1);
|
||||
@@ -1994,7 +2018,7 @@ ZEND_FUNCTION(debug_backtrace)
|
||||
ZEND_WRONG_PARAM_COUNT();
|
||||
}
|
||||
|
||||
zend_fetch_debug_backtrace(return_value, 1 TSRMLS_CC);
|
||||
zend_fetch_debug_backtrace(return_value, 1, 1 TSRMLS_CC);
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
@@ -25,7 +25,7 @@
|
||||
int zend_startup_builtin_functions(TSRMLS_D);
|
||||
|
||||
BEGIN_EXTERN_C()
|
||||
ZEND_API void zend_fetch_debug_backtrace(zval *return_value, int skip_last TSRMLS_DC);
|
||||
ZEND_API void zend_fetch_debug_backtrace(zval *return_value, int skip_last, int provide_object TSRMLS_DC);
|
||||
END_EXTERN_C()
|
||||
|
||||
#endif /* ZEND_BUILTIN_FUNCTIONS_H */
|
||||
|
||||
+71
-14
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
@@ -154,6 +154,7 @@ void zend_init_compiler_data_structures(TSRMLS_D)
|
||||
|
||||
void init_compiler(TSRMLS_D)
|
||||
{
|
||||
CG(active_op_array) = NULL;
|
||||
zend_init_compiler_data_structures(TSRMLS_C);
|
||||
zend_init_rsrc_list(TSRMLS_C);
|
||||
zend_hash_init(&CG(filenames_table), 5, NULL, (dtor_func_t) free_estring, 0);
|
||||
@@ -1730,12 +1731,14 @@ void zend_do_mark_last_catch(znode *first_catch, znode *last_additional_catch TS
|
||||
} else {
|
||||
CG(active_op_array)->opcodes[last_additional_catch->u.opline_num].op1.u.EA.type = 1;
|
||||
}
|
||||
DEC_BPC(CG(active_op_array));
|
||||
}
|
||||
|
||||
|
||||
void zend_do_try(znode *try_token TSRMLS_DC)
|
||||
{
|
||||
try_token->u.opline_num = zend_add_try_element(get_next_op_number(CG(active_op_array)) TSRMLS_CC);
|
||||
INC_BPC(CG(active_op_array));
|
||||
}
|
||||
|
||||
|
||||
@@ -1839,6 +1842,12 @@ static void do_inherit_parent_constructor(zend_class_entry *ce)
|
||||
ce->destructor = ce->parent->destructor;
|
||||
}
|
||||
if (ce->constructor) {
|
||||
if (ce->parent->constructor && ce->parent->constructor->common.fn_flags & ZEND_ACC_FINAL) {
|
||||
zend_error(E_ERROR, "Cannot override final %s::%s() with %s::%s()",
|
||||
ce->parent->name, ce->parent->constructor->common.function_name,
|
||||
ce->name, ce->constructor->common.function_name
|
||||
);
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -2088,7 +2097,9 @@ static zend_bool do_inherit_property_access_check(HashTable *target_ht, zend_pro
|
||||
|
||||
if (parent_ce->type != ce->type) {
|
||||
/* User class extends internal class */
|
||||
ht = parent_ce->static_members;
|
||||
TSRMLS_FETCH();
|
||||
|
||||
ht = CE_STATIC_MEMBERS(parent_ce);
|
||||
} else {
|
||||
ht = &parent_ce->default_static_members;
|
||||
}
|
||||
@@ -2194,7 +2205,7 @@ ZEND_API void zend_do_inheritance(zend_class_entry *ce, zend_class_entry *parent
|
||||
if (parent_ce->type != ce->type) {
|
||||
/* User class extends internal class */
|
||||
zend_update_class_constants(parent_ce TSRMLS_CC);
|
||||
zend_hash_merge(&ce->default_static_members, parent_ce->static_members, (void (*)(void *)) inherit_static_prop, NULL, sizeof(zval *), 0);
|
||||
zend_hash_merge(&ce->default_static_members, CE_STATIC_MEMBERS(parent_ce), (void (*)(void *)) inherit_static_prop, NULL, sizeof(zval *), 0);
|
||||
} else {
|
||||
zend_hash_merge(&ce->default_static_members, &parent_ce->default_static_members, (void (*)(void *)) inherit_static_prop, NULL, sizeof(zval *), 0);
|
||||
}
|
||||
@@ -2930,13 +2941,7 @@ void zend_do_declare_class_constant(znode *var_name, znode *value TSRMLS_DC)
|
||||
}
|
||||
|
||||
ALLOC_ZVAL(property);
|
||||
|
||||
if (value) {
|
||||
*property = value->u.constant;
|
||||
} else {
|
||||
INIT_PZVAL(property);
|
||||
property->type = IS_NULL;
|
||||
}
|
||||
*property = value->u.constant;
|
||||
|
||||
if (zend_hash_add(&CG(active_class_entry)->constants_table, var_name->u.constant.value.str.val, var_name->u.constant.value.str.len+1, &property, sizeof(zval *), NULL)==FAILURE) {
|
||||
FREE_ZVAL(property);
|
||||
@@ -3085,6 +3090,33 @@ void zend_do_end_new_object(znode *result, znode *new_token, znode *argument_lis
|
||||
*result = CG(active_op_array)->opcodes[new_token->u.opline_num].result;
|
||||
}
|
||||
|
||||
static int zend_constant_ct_subst(znode *result, zval *const_name TSRMLS_DC)
|
||||
{
|
||||
zend_constant *c = NULL;
|
||||
|
||||
if (zend_hash_find(EG(zend_constants), Z_STRVAL_P(const_name), Z_STRLEN_P(const_name)+1, (void **) &c) == FAILURE) {
|
||||
char *lookup_name = zend_str_tolower_dup(Z_STRVAL_P(const_name), Z_STRLEN_P(const_name));
|
||||
|
||||
if (zend_hash_find(EG(zend_constants), lookup_name, Z_STRLEN_P(const_name)+1, (void **) &c)==SUCCESS) {
|
||||
if ((c->flags & CONST_CS) && memcmp(c->name, Z_STRVAL_P(const_name), Z_STRLEN_P(const_name))!=0) {
|
||||
c = NULL;
|
||||
}
|
||||
} else {
|
||||
c = NULL;
|
||||
}
|
||||
efree(lookup_name);
|
||||
}
|
||||
if (c && (c->flags & CONST_CT_SUBST)) {
|
||||
zval_dtor(const_name);
|
||||
result->op_type = IS_CONST;
|
||||
result->u.constant = c->value;
|
||||
zval_copy_ctor(&result->u.constant);
|
||||
INIT_PZVAL(&result->u.constant);
|
||||
return 1;
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
void zend_do_fetch_constant(znode *result, znode *constant_container, znode *constant_name, int mode TSRMLS_DC)
|
||||
{
|
||||
switch (mode) {
|
||||
@@ -3092,13 +3124,15 @@ void zend_do_fetch_constant(znode *result, znode *constant_container, znode *con
|
||||
if (constant_container) {
|
||||
zend_do_fetch_class_name(NULL, constant_container, constant_name TSRMLS_CC);
|
||||
*result = *constant_container;
|
||||
} else {
|
||||
result->u.constant.type = IS_CONSTANT;
|
||||
} else if (!zend_constant_ct_subst(result, &constant_name->u.constant TSRMLS_CC)) {
|
||||
*result = *constant_name;
|
||||
result->u.constant.type = IS_CONSTANT;
|
||||
}
|
||||
result->u.constant.type = IS_CONSTANT;
|
||||
break;
|
||||
case ZEND_RT:
|
||||
{
|
||||
if (constant_container ||
|
||||
!zend_constant_ct_subst(result, &constant_name->u.constant TSRMLS_CC)) {
|
||||
zend_op *opline = get_next_op(CG(active_op_array) TSRMLS_CC);
|
||||
|
||||
opline->opcode = ZEND_FETCH_CONSTANT;
|
||||
@@ -3217,6 +3251,9 @@ void zend_do_add_static_array_element(znode *result, znode *offset, znode *expr)
|
||||
case IS_DOUBLE:
|
||||
zend_hash_index_update(result->u.constant.value.ht, (long)offset->u.constant.value.dval, &element, sizeof(zval *), NULL);
|
||||
break;
|
||||
case IS_CONSTANT_ARRAY:
|
||||
zend_error(E_ERROR, "Illegal offset type");
|
||||
break;
|
||||
}
|
||||
} else {
|
||||
zend_hash_next_index_insert(result->u.constant.value.ht, &element, sizeof(zval *), NULL);
|
||||
@@ -3745,6 +3782,8 @@ void zend_do_declare_stmt(znode *var, znode *val TSRMLS_DC)
|
||||
}
|
||||
efree(val->u.constant.value.str.val);
|
||||
#endif /* ZEND_MULTIBYTE */
|
||||
} else {
|
||||
zval_dtor(&val->u.constant);
|
||||
}
|
||||
zval_dtor(&var->u.constant);
|
||||
}
|
||||
@@ -3996,6 +4035,8 @@ again:
|
||||
case T_END_HEREDOC:
|
||||
efree(zendlval->u.constant.value.str.val);
|
||||
break;
|
||||
case EOF:
|
||||
return EOF;
|
||||
}
|
||||
|
||||
INIT_PZVAL(&zendlval->u.constant);
|
||||
@@ -4022,7 +4063,23 @@ ZEND_API void zend_initialize_class_data(zend_class_entry *ce, zend_bool nullify
|
||||
zend_hash_init_ex(&ce->constants_table, 0, NULL, zval_ptr_dtor_func, persistent_hashes, 0);
|
||||
zend_hash_init_ex(&ce->function_table, 0, NULL, ZEND_FUNCTION_DTOR, persistent_hashes, 0);
|
||||
|
||||
ce->static_members = (ce->type == ZEND_INTERNAL_CLASS) ? NULL : &ce->default_static_members;
|
||||
if (ce->type == ZEND_INTERNAL_CLASS) {
|
||||
#ifdef ZTS
|
||||
int n = zend_hash_num_elements(CG(class_table));
|
||||
|
||||
if (CG(static_members) && n >= CG(last_static_member)) {
|
||||
/* Support for run-time declaration: dl() */
|
||||
CG(last_static_member) = n+1;
|
||||
CG(static_members) = realloc(CG(static_members), (n+1)*sizeof(HashTable*));
|
||||
CG(static_members)[n] = NULL;
|
||||
}
|
||||
ce->static_members = (HashTable*)n;
|
||||
#else
|
||||
ce->static_members = NULL;
|
||||
#endif
|
||||
} else {
|
||||
ce->static_members = &ce->default_static_members;
|
||||
}
|
||||
|
||||
if (nullify_handlers) {
|
||||
ce->constructor = NULL;
|
||||
|
||||
+5
-1
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
@@ -136,6 +136,9 @@ typedef struct _zend_try_catch_element {
|
||||
/* shadow of parent's private method/property */
|
||||
#define ZEND_ACC_SHADOW 0x20000
|
||||
|
||||
/* deprecation flag */
|
||||
#define ZEND_ACC_DEPRECATED 0x40000
|
||||
|
||||
char *zend_visibility_string(zend_uint fn_flags);
|
||||
|
||||
|
||||
@@ -514,6 +517,7 @@ ZEND_API void zend_destroy_file_handle(zend_file_handle *file_handle TSRMLS_DC);
|
||||
ZEND_API void zend_file_handle_dtor(zend_file_handle *fh);
|
||||
ZEND_API int zend_cleanup_class_data(zend_class_entry **pce TSRMLS_DC);
|
||||
ZEND_API int zend_cleanup_function_data(zend_function *function TSRMLS_DC);
|
||||
ZEND_API int zend_cleanup_function_data_full(zend_function *function TSRMLS_DC);
|
||||
|
||||
ZEND_API void destroy_zend_function(zend_function *function TSRMLS_DC);
|
||||
ZEND_API void zend_function_dtor(zend_function *function);
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
+6
-15
@@ -2,10 +2,10 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
| available through the world-wide-web at the following url: |
|
||||
| http://www.zend.com/license/2_00.txt. |
|
||||
| If you did not receive a copy of the Zend license and are unable to |
|
||||
@@ -23,8 +23,9 @@
|
||||
#define ZEND_CONFIG_W32_H
|
||||
|
||||
#define USE_ZEND_ALLOC 1
|
||||
#define HAVE_ALLOCA 1
|
||||
#define HAVE_LIMITS_H 1
|
||||
|
||||
#include <../main/config.w32.h>
|
||||
|
||||
#define _CRTDBG_MAP_ALLOC
|
||||
|
||||
#include <malloc.h>
|
||||
@@ -44,19 +45,9 @@
|
||||
typedef unsigned long ulong;
|
||||
typedef unsigned int uint;
|
||||
|
||||
#undef HAVE_KILL
|
||||
#define HAVE_GETPID 1
|
||||
/* #define HAVE_ALLOCA_H 1 */
|
||||
#define HAVE_MEMCPY 1
|
||||
#define HAVE_STRDUP 1
|
||||
#define HAVE_SYS_TYPES_H 1
|
||||
#define HAVE_STDIOSTR_H 1
|
||||
#define HAVE_CLASS_ISTDIOSTREAM
|
||||
#define istdiostream stdiostream
|
||||
#define HAVE_STDARG_H 1
|
||||
#define HAVE_SNPRINTF 1
|
||||
#define HAVE_VSNPRINTF 1
|
||||
#define HAVE_STRCOLL 1
|
||||
|
||||
#define snprintf _snprintf
|
||||
#define vsnprintf _vsnprintf
|
||||
@@ -87,7 +78,7 @@ typedef unsigned int uint;
|
||||
#define ZEND_DLEXPORT __declspec(dllexport)
|
||||
#define ZEND_DLIMPORT __declspec(dllimport)
|
||||
|
||||
/* 0x00200000L is MB_SERVICE_NOTIFICATION, which is only supported under Windows NT
|
||||
/* 0x00200000L is MB_SERVICE_NOTIFICATION, which is only supported under Windows NT
|
||||
* (and requires _WIN32_WINNT to be defined, which prevents the resulting executable
|
||||
* from running under Windows 9x
|
||||
* Windows 9x should silently ignore it, so it's being used here directly
|
||||
|
||||
+19
-16
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
@@ -55,11 +55,13 @@ void zend_copy_constants(HashTable *target, HashTable *source)
|
||||
|
||||
static int clean_non_persistent_constant(zend_constant *c TSRMLS_DC)
|
||||
{
|
||||
if (c->flags & CONST_PERSISTENT) {
|
||||
return EG(full_tables_cleanup) ? 0 : ZEND_HASH_APPLY_STOP;
|
||||
} else {
|
||||
return EG(full_tables_cleanup) ? 1 : ZEND_HASH_APPLY_REMOVE;
|
||||
}
|
||||
return (c->flags & CONST_PERSISTENT) ? ZEND_HASH_APPLY_STOP : ZEND_HASH_APPLY_REMOVE;
|
||||
}
|
||||
|
||||
|
||||
static int clean_non_persistent_constant_full(zend_constant *c TSRMLS_DC)
|
||||
{
|
||||
return (c->flags & CONST_PERSISTENT) ? 0 : 1;
|
||||
}
|
||||
|
||||
|
||||
@@ -112,8 +114,7 @@ void zend_register_standard_constants(TSRMLS_D)
|
||||
{
|
||||
zend_constant c;
|
||||
|
||||
c.value.type = IS_BOOL;
|
||||
c.flags = CONST_PERSISTENT;
|
||||
c.flags = CONST_PERSISTENT | CONST_CT_SUBST;
|
||||
c.module_number = 0;
|
||||
|
||||
c.name = zend_strndup(ZEND_STRL("TRUE"));
|
||||
@@ -128,16 +129,18 @@ void zend_register_standard_constants(TSRMLS_D)
|
||||
c.value.type = IS_BOOL;
|
||||
zend_register_constant(&c TSRMLS_CC);
|
||||
|
||||
c.name = zend_strndup(ZEND_STRL("NULL"));
|
||||
c.name_len = sizeof("NULL");
|
||||
c.value.type = IS_NULL;
|
||||
zend_register_constant(&c TSRMLS_CC);
|
||||
|
||||
c.flags = CONST_PERSISTENT;
|
||||
|
||||
c.name = zend_strndup(ZEND_STRL("ZEND_THREAD_SAFE"));
|
||||
c.name_len = sizeof("ZEND_THREAD_SAFE");
|
||||
c.value.value.lval = ZTS_V;
|
||||
c.value.type = IS_BOOL;
|
||||
zend_register_constant(&c TSRMLS_CC);
|
||||
|
||||
c.name = zend_strndup(ZEND_STRL("NULL"));
|
||||
c.name_len = sizeof("NULL");
|
||||
c.value.type = IS_NULL;
|
||||
zend_register_constant(&c TSRMLS_CC);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -153,7 +156,7 @@ int zend_shutdown_constants(TSRMLS_D)
|
||||
void clean_non_persistent_constants(TSRMLS_D)
|
||||
{
|
||||
if (EG(full_tables_cleanup)) {
|
||||
zend_hash_apply(EG(zend_constants), (apply_func_t) clean_non_persistent_constant TSRMLS_CC);
|
||||
zend_hash_apply(EG(zend_constants), (apply_func_t) clean_non_persistent_constant_full TSRMLS_CC);
|
||||
} else {
|
||||
zend_hash_reverse_apply(EG(zend_constants), (apply_func_t) clean_non_persistent_constant TSRMLS_CC);
|
||||
}
|
||||
@@ -309,8 +312,8 @@ ZEND_API int zend_register_constant(zend_constant *c TSRMLS_DC)
|
||||
|
||||
if (!(c->flags & CONST_CS)) {
|
||||
/* keep in mind that c->name_len already contains the '\0' */
|
||||
lowercase_name = estrndup(c->name, c->name_len);
|
||||
zend_str_tolower(lowercase_name, c->name_len);
|
||||
lowercase_name = estrndup(c->name, c->name_len-1);
|
||||
zend_str_tolower(lowercase_name, c->name_len-1);
|
||||
name = lowercase_name;
|
||||
} else {
|
||||
name = c->name;
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
@@ -26,6 +26,7 @@
|
||||
|
||||
#define CONST_CS (1<<0) /* Case Sensitive */
|
||||
#define CONST_PERSISTENT (1<<1) /* Persistent */
|
||||
#define CONST_CT_SUBST (2<<1) /* Allow compile-time substitution */
|
||||
|
||||
#define PHP_USER_CONSTANT INT_MAX /* a constant defined in user space */
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
@@ -21,7 +21,6 @@
|
||||
|
||||
#include "zend.h"
|
||||
#include "zend_API.h"
|
||||
#include "zend_reflection_api.h"
|
||||
#include "zend_builtin_functions.h"
|
||||
#include "zend_interfaces.h"
|
||||
#include "zend_exceptions.h"
|
||||
@@ -31,7 +30,6 @@ ZEND_API void zend_register_default_classes(TSRMLS_D)
|
||||
{
|
||||
zend_register_interfaces(TSRMLS_C);
|
||||
zend_register_default_exception(TSRMLS_C);
|
||||
zend_register_reflection_api(TSRMLS_C);
|
||||
zend_register_iterator_wrapper(TSRMLS_C);
|
||||
}
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
+1
-1
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
@@ -23,7 +23,6 @@
|
||||
|
||||
#include "zend.h"
|
||||
#include "zend_API.h"
|
||||
#include "zend_reflection_api.h"
|
||||
#include "zend_builtin_functions.h"
|
||||
#include "zend_interfaces.h"
|
||||
#include "zend_exceptions.h"
|
||||
@@ -92,7 +91,7 @@ static zend_object_value zend_default_exception_new_ex(zend_class_entry *class_t
|
||||
ALLOC_ZVAL(trace);
|
||||
trace->is_ref = 0;
|
||||
trace->refcount = 0;
|
||||
zend_fetch_debug_backtrace(trace, skip_top_traces TSRMLS_CC);
|
||||
zend_fetch_debug_backtrace(trace, skip_top_traces, 0 TSRMLS_CC);
|
||||
|
||||
zend_update_property_string(default_exception_ce, &obj, "file", sizeof("file")-1, zend_get_executed_filename(TSRMLS_C) TSRMLS_CC);
|
||||
zend_update_property_long(default_exception_ce, &obj, "line", sizeof("line")-1, zend_get_executed_lineno(TSRMLS_C) TSRMLS_CC);
|
||||
@@ -132,7 +131,7 @@ ZEND_METHOD(exception, __construct)
|
||||
int argc = ZEND_NUM_ARGS(), message_len;
|
||||
|
||||
if (zend_parse_parameters_ex(ZEND_PARSE_PARAMS_QUIET, argc TSRMLS_CC, "|sl", &message, &message_len, &code) == FAILURE) {
|
||||
zend_error(E_ERROR, "Wrong parameter count for exception([string $exception [, long $code ]])");
|
||||
zend_error(E_ERROR, "Wrong parameters for Exception([string $exception [, long $code ]])");
|
||||
}
|
||||
|
||||
object = getThis();
|
||||
@@ -158,7 +157,7 @@ ZEND_METHOD(error_exception, __construct)
|
||||
int argc = ZEND_NUM_ARGS(), message_len, filename_len;
|
||||
|
||||
if (zend_parse_parameters_ex(ZEND_PARSE_PARAMS_QUIET, argc TSRMLS_CC, "|sllsl", &message, &message_len, &code, &severity, &filename, &filename_len, &lineno) == FAILURE) {
|
||||
zend_error(E_ERROR, "Wrong parameter count for exception([string $exception [, long $code ]])");
|
||||
zend_error(E_ERROR, "Wrong parameters for ErrorException([string $exception [, long $code, [ long $severity, [ string $filename, [ long $lineno ]]]]])");
|
||||
}
|
||||
|
||||
object = getThis();
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
+15
-4
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
@@ -177,8 +177,8 @@ static inline zval *_get_zval_ptr_var(znode *node, temp_variable *Ts, zend_free_
|
||||
should_free->var = ptr;
|
||||
|
||||
if (T->str_offset.str->type != IS_STRING
|
||||
|| ((int)T->str_offset.offset<0)
|
||||
|| (T->str_offset.str->value.str.len <= T->str_offset.offset)) {
|
||||
|| ((int)T->str_offset.offset < 0)
|
||||
|| (T->str_offset.str->value.str.len <= (int)T->str_offset.offset)) {
|
||||
zend_error(E_NOTICE, "Uninitialized string offset: %d", T->str_offset.offset);
|
||||
ptr->value.str.val = STR_EMPTY_ALLOC();
|
||||
ptr->value.str.len = 0;
|
||||
@@ -440,6 +440,7 @@ static inline void make_real_object(zval **object_ptr TSRMLS_DC)
|
||||
SEPARATE_ZVAL(object_ptr);
|
||||
}
|
||||
zend_error(E_STRICT, "Creating default object from empty value");
|
||||
zval_dtor(*object_ptr);
|
||||
object_init(*object_ptr);
|
||||
}
|
||||
}
|
||||
@@ -544,6 +545,16 @@ static inline void zend_assign_to_object(znode *result, zval **object_ptr, znode
|
||||
zval *value = get_zval_ptr(value_op, Ts, &free_value, BP_VAR_R);
|
||||
zval **retval = &T(result->u.var).var.ptr;
|
||||
|
||||
if (*object_ptr == EG(error_zval_ptr)) {
|
||||
FREE_OP(free_op2);
|
||||
if (!RETURN_VALUE_UNUSED(result)) {
|
||||
*retval = EG(uninitialized_zval_ptr);
|
||||
PZVAL_LOCK(*retval);
|
||||
}
|
||||
FREE_OP(free_value);
|
||||
return;
|
||||
}
|
||||
|
||||
make_real_object(object_ptr TSRMLS_CC); /* this should modify object only if it's empty */
|
||||
object = *object_ptr;
|
||||
|
||||
@@ -647,7 +658,7 @@ static inline void zend_assign_to_variable(znode *result, znode *op1, znode *op2
|
||||
zend_error(E_WARNING, "Illegal string offset: %d", T->str_offset.offset);
|
||||
break;
|
||||
}
|
||||
if (T->str_offset.offset >= T->str_offset.str->value.str.len) {
|
||||
if ((int)T->str_offset.offset >= T->str_offset.str->value.str.len) {
|
||||
zend_uint i;
|
||||
|
||||
if (T->str_offset.str->value.str.len==0) {
|
||||
|
||||
+1
-1
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
+113
-41
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
@@ -46,11 +46,12 @@ ZEND_API zend_fcall_info_cache empty_fcall_info_cache = { 0, NULL, NULL, NULL };
|
||||
static WNDCLASS wc;
|
||||
static HWND timeout_window;
|
||||
static HANDLE timeout_thread_event;
|
||||
static HANDLE timeout_thread_handle;
|
||||
static DWORD timeout_thread_id;
|
||||
static int timeout_thread_initialized=0;
|
||||
#endif
|
||||
|
||||
#if ZEND_DEBUG
|
||||
#if 0&&ZEND_DEBUG
|
||||
static void (*original_sigsegv_handler)(int);
|
||||
static void zend_handle_sigsegv(int dummy)
|
||||
{
|
||||
@@ -94,23 +95,27 @@ static void zend_extension_deactivator(zend_extension *extension TSRMLS_DC)
|
||||
}
|
||||
|
||||
|
||||
static int is_not_internal_function(zend_function *function TSRMLS_DC)
|
||||
static int clean_non_persistent_function(zend_function *function TSRMLS_DC)
|
||||
{
|
||||
if (function->type == ZEND_INTERNAL_FUNCTION) {
|
||||
return EG(full_tables_cleanup) ? 0 : ZEND_HASH_APPLY_STOP;
|
||||
} else {
|
||||
return EG(full_tables_cleanup) ? 1 : ZEND_HASH_APPLY_REMOVE;
|
||||
}
|
||||
return (function->type == ZEND_INTERNAL_FUNCTION) ? ZEND_HASH_APPLY_STOP : ZEND_HASH_APPLY_REMOVE;
|
||||
}
|
||||
|
||||
|
||||
static int is_not_internal_class(zend_class_entry **ce TSRMLS_DC)
|
||||
static int clean_non_persistent_function_full(zend_function *function TSRMLS_DC)
|
||||
{
|
||||
if ((*ce)->type == ZEND_INTERNAL_CLASS) {
|
||||
return EG(full_tables_cleanup) ? 0 : ZEND_HASH_APPLY_STOP;
|
||||
} else {
|
||||
return EG(full_tables_cleanup) ? 1 : ZEND_HASH_APPLY_REMOVE;
|
||||
}
|
||||
return (function->type != ZEND_INTERNAL_FUNCTION);
|
||||
}
|
||||
|
||||
|
||||
static int clean_non_persistent_class(zend_class_entry **ce TSRMLS_DC)
|
||||
{
|
||||
return ((*ce)->type == ZEND_INTERNAL_CLASS) ? ZEND_HASH_APPLY_STOP : ZEND_HASH_APPLY_REMOVE;
|
||||
}
|
||||
|
||||
|
||||
static int clean_non_persistent_class_full(zend_class_entry **ce TSRMLS_DC)
|
||||
{
|
||||
return ((*ce)->type != ZEND_INTERNAL_CLASS);
|
||||
}
|
||||
|
||||
|
||||
@@ -250,18 +255,22 @@ void shutdown_executor(TSRMLS_D)
|
||||
So we want first of all to clean up all data and then move to tables destruction.
|
||||
Note that only run-time accessed data need to be cleaned up, pre-defined data can
|
||||
not contain objects and thus are not probelmatic */
|
||||
zend_hash_apply(EG(function_table), (apply_func_t) zend_cleanup_function_data TSRMLS_CC);
|
||||
if (EG(full_tables_cleanup)) {
|
||||
zend_hash_apply(EG(function_table), (apply_func_t) zend_cleanup_function_data_full TSRMLS_CC);
|
||||
} else {
|
||||
zend_hash_reverse_apply(EG(function_table), (apply_func_t) zend_cleanup_function_data TSRMLS_CC);
|
||||
}
|
||||
zend_hash_apply(EG(class_table), (apply_func_t) zend_cleanup_class_data TSRMLS_CC);
|
||||
|
||||
zend_ptr_stack_destroy(&EG(argument_stack));
|
||||
|
||||
/* Destroy all op arrays */
|
||||
if (EG(full_tables_cleanup)) {
|
||||
zend_hash_apply(EG(function_table), (apply_func_t) is_not_internal_function TSRMLS_CC);
|
||||
zend_hash_apply(EG(class_table), (apply_func_t) is_not_internal_class TSRMLS_CC);
|
||||
zend_hash_apply(EG(function_table), (apply_func_t) clean_non_persistent_function_full TSRMLS_CC);
|
||||
zend_hash_apply(EG(class_table), (apply_func_t) clean_non_persistent_class_full TSRMLS_CC);
|
||||
} else {
|
||||
zend_hash_reverse_apply(EG(function_table), (apply_func_t) is_not_internal_function TSRMLS_CC);
|
||||
zend_hash_reverse_apply(EG(class_table), (apply_func_t) is_not_internal_class TSRMLS_CC);
|
||||
zend_hash_reverse_apply(EG(function_table), (apply_func_t) clean_non_persistent_function TSRMLS_CC);
|
||||
zend_hash_reverse_apply(EG(class_table), (apply_func_t) clean_non_persistent_class TSRMLS_CC);
|
||||
}
|
||||
|
||||
while (EG(symtable_cache_ptr)>=EG(symtable_cache)) {
|
||||
@@ -277,7 +286,7 @@ void shutdown_executor(TSRMLS_D)
|
||||
} zend_end_try();
|
||||
|
||||
zend_try {
|
||||
#if ZEND_DEBUG
|
||||
#if 0&&ZEND_DEBUG
|
||||
signal(SIGSEGV, original_sigsegv_handler);
|
||||
#endif
|
||||
|
||||
@@ -481,7 +490,7 @@ ZEND_API int zval_update_constant(zval **pp, void *arg TSRMLS_DC)
|
||||
continue;
|
||||
}
|
||||
|
||||
if (const_value.type == IS_STRING && const_value.value.str.len == str_index_len-1 &&
|
||||
if (const_value.type == IS_STRING && const_value.value.str.len == (int)str_index_len-1 &&
|
||||
!strncmp(const_value.value.str.val, str_index, str_index_len)) {
|
||||
/* constant value is the same as its name */
|
||||
zval_dtor(&const_value);
|
||||
@@ -501,17 +510,9 @@ ZEND_API int zval_update_constant(zval **pp, void *arg TSRMLS_DC)
|
||||
*element = new_val;
|
||||
|
||||
switch (const_value.type) {
|
||||
case IS_STRING: {
|
||||
long lval;
|
||||
double dval;
|
||||
|
||||
if (is_numeric_string(const_value.value.str.val, const_value.value.str.len, &lval, &dval, 0) == IS_LONG) {
|
||||
zend_hash_update_current_key(p->value.ht, HASH_KEY_IS_LONG, NULL, 0, lval);
|
||||
} else {
|
||||
zend_hash_update_current_key(p->value.ht, HASH_KEY_IS_STRING, const_value.value.str.val, const_value.value.str.len+1, 0);
|
||||
}
|
||||
case IS_STRING:
|
||||
zend_symtable_update_current_key(p->value.ht, const_value.value.str.val, const_value.value.str.len+1);
|
||||
break;
|
||||
}
|
||||
case IS_BOOL:
|
||||
case IS_LONG:
|
||||
zend_hash_update_current_key(p->value.ht, HASH_KEY_IS_LONG, NULL, 0, const_value.value.lval);
|
||||
@@ -589,11 +590,14 @@ int zend_call_function(zend_fcall_info *fci, zend_fcall_info_cache *fci_cache TS
|
||||
zend_op **original_opline_ptr;
|
||||
zend_class_entry *current_scope;
|
||||
zend_class_entry *calling_scope = NULL;
|
||||
zend_class_entry *check_scope_or_static = NULL;
|
||||
zval *current_this;
|
||||
zend_execute_data execute_data;
|
||||
zval *method_name;
|
||||
zval *params_array;
|
||||
int call_via_handler = 0;
|
||||
char *fname, *colon;
|
||||
int fname_len;
|
||||
|
||||
if (EG(exception)) {
|
||||
return FAILURE; /* we would result in an instable executor otherwise */
|
||||
@@ -612,6 +616,7 @@ int zend_call_function(zend_fcall_info *fci, zend_fcall_info_cache *fci_cache TS
|
||||
execute_data = *EG(current_execute_data);
|
||||
EX(op_array) = NULL;
|
||||
EX(opline) = NULL;
|
||||
EX(object) = NULL;
|
||||
} else {
|
||||
/* This only happens when we're called outside any execute()'s
|
||||
* It shouldn't be strictly necessary to NULL execute_data out,
|
||||
@@ -667,6 +672,7 @@ int zend_call_function(zend_fcall_info *fci, zend_fcall_info_cache *fci_cache TS
|
||||
ce = &(EG(active_op_array)->scope);
|
||||
found = (*ce != NULL?SUCCESS:FAILURE);
|
||||
fci->object_pp = EG(This)?&EG(This):NULL;
|
||||
EX(object) = EG(This);
|
||||
} else if (strcmp(Z_STRVAL_PP(fci->object_pp), "parent") == 0 && EG(active_op_array)) {
|
||||
|
||||
if (!EG(active_op_array)->scope) {
|
||||
@@ -678,6 +684,7 @@ int zend_call_function(zend_fcall_info *fci, zend_fcall_info_cache *fci_cache TS
|
||||
ce = &(EG(active_op_array)->scope->parent);
|
||||
found = (*ce != NULL?SUCCESS:FAILURE);
|
||||
fci->object_pp = EG(This)?&EG(This):NULL;
|
||||
EX(object) = EG(This);
|
||||
} else {
|
||||
zend_class_entry *scope;
|
||||
scope = EG(active_op_array) ? EG(active_op_array)->scope : NULL;
|
||||
@@ -690,6 +697,7 @@ int zend_call_function(zend_fcall_info *fci, zend_fcall_info_cache *fci_cache TS
|
||||
instanceof_function(Z_OBJCE_P(EG(This)), scope TSRMLS_CC) &&
|
||||
instanceof_function(scope, *ce TSRMLS_CC)) {
|
||||
fci->object_pp = &EG(This);
|
||||
EX(object) = EG(This);
|
||||
} else {
|
||||
fci->object_pp = NULL;
|
||||
}
|
||||
@@ -713,30 +721,67 @@ int zend_call_function(zend_fcall_info *fci, zend_fcall_info_cache *fci_cache TS
|
||||
return FAILURE;
|
||||
}
|
||||
|
||||
fname = Z_STRVAL_P(fci->function_name);
|
||||
fname_len = Z_STRLEN_P(fci->function_name);
|
||||
if (calling_scope && (colon = strstr(fname, "::")) != NULL) {
|
||||
int clen = colon - fname;
|
||||
int mlen = fname_len - clen - 2;
|
||||
zend_class_entry **pce, *ce_child = NULL;
|
||||
if (zend_lookup_class(fname, clen, &pce TSRMLS_CC) == SUCCESS) {
|
||||
ce_child = *pce;
|
||||
} else {
|
||||
char *lcname = zend_str_tolower_dup(fname, clen);
|
||||
/* caution: lcname is not '\0' terminated */
|
||||
if (calling_scope) {
|
||||
if (clen == sizeof("self") - 1 && memcmp(lcname, "self", sizeof("self") - 1) == 0) {
|
||||
ce_child = EG(active_op_array) ? EG(active_op_array)->scope : NULL;
|
||||
} else if (clen == sizeof("parent") - 1 && memcmp(lcname, "parent", sizeof("parent") - 1) == 0 && EG(active_op_array)->scope) {
|
||||
ce_child = EG(active_op_array) && EG(active_op_array)->scope ? EG(scope)->parent : NULL;
|
||||
}
|
||||
}
|
||||
efree(lcname);
|
||||
}
|
||||
if (!ce_child) {
|
||||
zend_error(E_ERROR, "Cannot call method %s() or method does not exist", fname);
|
||||
return FAILURE;
|
||||
}
|
||||
check_scope_or_static = calling_scope;
|
||||
fci->function_table = &ce_child->function_table;
|
||||
calling_scope = ce_child;
|
||||
fname = fname + clen + 2;
|
||||
fname_len = mlen;
|
||||
}
|
||||
|
||||
if (fci->object_pp) {
|
||||
if (Z_OBJ_HT_PP(fci->object_pp)->get_method == NULL) {
|
||||
zend_error(E_ERROR, "Object does not support method calls");
|
||||
}
|
||||
EX(function_state).function =
|
||||
Z_OBJ_HT_PP(fci->object_pp)->get_method(fci->object_pp, Z_STRVAL_P(fci->function_name), Z_STRLEN_P(fci->function_name) TSRMLS_CC);
|
||||
Z_OBJ_HT_PP(fci->object_pp)->get_method(fci->object_pp, fname, fname_len TSRMLS_CC);
|
||||
if (EX(function_state).function && calling_scope != EX(function_state).function->common.scope) {
|
||||
char *function_name_lc = zend_str_tolower_dup(Z_STRVAL_P(fci->function_name), Z_STRLEN_P(fci->function_name));
|
||||
if (zend_hash_find(&calling_scope->function_table, function_name_lc, fci->function_name->value.str.len+1, (void **) &EX(function_state).function)==FAILURE) {
|
||||
char *function_name_lc = zend_str_tolower_dup(fname, fname_len);
|
||||
if (zend_hash_find(&calling_scope->function_table, function_name_lc, fname_len+1, (void **) &EX(function_state).function)==FAILURE) {
|
||||
efree(function_name_lc);
|
||||
zend_error(E_ERROR, "Cannot call method %s::%s() or method does not exist", calling_scope->name, Z_STRVAL_P(fci->function_name));
|
||||
zend_error(E_ERROR, "Cannot call method %s::%s() or method does not exist", calling_scope->name, fname);
|
||||
}
|
||||
efree(function_name_lc);
|
||||
}
|
||||
} else if (calling_scope) {
|
||||
char *function_name_lc = zend_str_tolower_dup(Z_STRVAL_P(fci->function_name), Z_STRLEN_P(fci->function_name));
|
||||
char *function_name_lc = zend_str_tolower_dup(fname, fname_len);
|
||||
|
||||
EX(function_state).function =
|
||||
zend_std_get_static_method(calling_scope, function_name_lc, Z_STRLEN_P(fci->function_name) TSRMLS_CC);
|
||||
zend_std_get_static_method(calling_scope, function_name_lc, fname_len TSRMLS_CC);
|
||||
efree(function_name_lc);
|
||||
if (check_scope_or_static && EX(function_state).function
|
||||
&& !(EX(function_state).function->common.fn_flags & ZEND_ACC_STATIC)
|
||||
&& !instanceof_function(check_scope_or_static, calling_scope TSRMLS_CC)) {
|
||||
zend_error(E_ERROR, "Cannot call method %s() of class %s which is not a derived from %s", fname, calling_scope->name, check_scope_or_static->name);
|
||||
return 0;
|
||||
}
|
||||
} else {
|
||||
char *function_name_lc = zend_str_tolower_dup(Z_STRVAL_P(fci->function_name), Z_STRLEN_P(fci->function_name));
|
||||
char *function_name_lc = zend_str_tolower_dup(fname, fname_len);
|
||||
|
||||
if (zend_hash_find(fci->function_table, function_name_lc, fci->function_name->value.str.len+1, (void **) &EX(function_state).function)==FAILURE) {
|
||||
if (zend_hash_find(fci->function_table, function_name_lc, fname_len+1, (void **) &EX(function_state).function)==FAILURE) {
|
||||
EX(function_state).function = NULL;
|
||||
}
|
||||
efree(function_name_lc);
|
||||
@@ -769,6 +814,19 @@ int zend_call_function(zend_fcall_info *fci, zend_fcall_info_cache *fci_cache TS
|
||||
EX(function_state).function = fci_cache->function_handler;
|
||||
calling_scope = fci_cache->calling_scope;
|
||||
fci->object_pp = fci_cache->object_pp;
|
||||
EX(object) = fci->object_pp ? *fci->object_pp : NULL;
|
||||
}
|
||||
|
||||
if (EX(function_state).function->common.fn_flags & (ZEND_ACC_ABSTRACT|ZEND_ACC_DEPRECATED)) {
|
||||
if (EX(function_state).function->common.fn_flags & ZEND_ACC_ABSTRACT) {
|
||||
zend_error_noreturn(E_ERROR, "Cannot call abstract method %s::%s()", EX(function_state).function->common.scope->name, EX(function_state).function->common.function_name);
|
||||
}
|
||||
if (EX(function_state).function->common.fn_flags & ZEND_ACC_DEPRECATED) {
|
||||
zend_error(E_STRICT, "Function %s%s%s() is deprecated",
|
||||
EX(function_state).function->common.scope ? EX(function_state).function->common.scope->name : "",
|
||||
EX(function_state).function->common.scope ? "::" : "",
|
||||
EX(function_state).function->common.function_name);
|
||||
}
|
||||
}
|
||||
|
||||
for (i=0; i<fci->param_count; i++) {
|
||||
@@ -920,7 +978,7 @@ ZEND_API int zend_lookup_class_ex(char *name, int name_length, int use_autoload,
|
||||
zval **args[1];
|
||||
zval autoload_function;
|
||||
zval *class_name_ptr;
|
||||
zval *retval_ptr;
|
||||
zval *retval_ptr = NULL;
|
||||
int retval;
|
||||
char *lc_name;
|
||||
zval *exception;
|
||||
@@ -1003,6 +1061,8 @@ ZEND_API int zend_lookup_class_ex(char *name, int name_length, int use_autoload,
|
||||
}
|
||||
if (!EG(exception)) {
|
||||
EG(exception) = exception;
|
||||
}
|
||||
if (retval_ptr) {
|
||||
zval_ptr_dtor(&retval_ptr);
|
||||
}
|
||||
|
||||
@@ -1115,6 +1175,8 @@ void execute_new_code(TSRMLS_D)
|
||||
INIT_ZVAL(ret_opline->op1.u.constant);
|
||||
SET_UNUSED(ret_opline->op2);
|
||||
|
||||
zend_do_handle_exception(TSRMLS_C);
|
||||
|
||||
if (!CG(active_op_array)->start_op) {
|
||||
CG(active_op_array)->start_op = CG(active_op_array)->opcodes;
|
||||
}
|
||||
@@ -1153,7 +1215,11 @@ void execute_new_code(TSRMLS_D)
|
||||
zval_ptr_dtor(&local_retval);
|
||||
}
|
||||
|
||||
CG(active_op_array)->last--; /* get rid of that ZEND_RETURN */
|
||||
if (EG(exception)) {
|
||||
zend_exception_error(EG(exception) TSRMLS_CC);
|
||||
}
|
||||
|
||||
CG(active_op_array)->last -= 2; /* get rid of that ZEND_RETURN and ZEND_HANDLE_EXCEPTION */
|
||||
CG(active_op_array)->start_op = CG(active_op_array)->opcodes+CG(active_op_array)->last;
|
||||
}
|
||||
|
||||
@@ -1249,6 +1315,7 @@ static unsigned __stdcall timeout_thread_proc(void *pArgs)
|
||||
}
|
||||
DestroyWindow(timeout_window);
|
||||
UnregisterClass(wc.lpszClassName, NULL);
|
||||
SetEvent(timeout_thread_handle);
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -1256,6 +1323,7 @@ static unsigned __stdcall timeout_thread_proc(void *pArgs)
|
||||
void zend_init_timeout_thread()
|
||||
{
|
||||
timeout_thread_event = CreateEvent(NULL, FALSE, FALSE, NULL);
|
||||
timeout_thread_handle = CreateEvent(NULL, FALSE, FALSE, NULL);
|
||||
_beginthreadex(NULL, 0, timeout_thread_proc, NULL, 0, &timeout_thread_id);
|
||||
WaitForSingleObject(timeout_thread_event, INFINITE);
|
||||
}
|
||||
@@ -1267,6 +1335,10 @@ void zend_shutdown_timeout_thread()
|
||||
return;
|
||||
}
|
||||
PostThreadMessage(timeout_thread_id, WM_QUIT, 0, 0);
|
||||
|
||||
/* Wait for thread termination */
|
||||
WaitForSingleObject(timeout_thread_handle, 5000);
|
||||
CloseHandle(timeout_thread_handle);
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
+6
-1
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
@@ -144,6 +144,11 @@ struct _zend_compiler_globals {
|
||||
zend_encoding_converter encoding_converter;
|
||||
zend_encoding_oddlen encoding_oddlen;
|
||||
#endif /* ZEND_MULTIBYTE */
|
||||
|
||||
#ifdef ZTS
|
||||
HashTable **static_members;
|
||||
int last_static_member;
|
||||
#endif
|
||||
};
|
||||
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
+17
-19
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
@@ -102,14 +102,14 @@ ZEND_API ulong zend_hash_func(char *arKey, uint nKeyLength)
|
||||
|
||||
#define UPDATE_DATA(ht, p, pData, nDataSize) \
|
||||
if (nDataSize == sizeof(void*)) { \
|
||||
if (!(p)->pDataPtr) { \
|
||||
pefree_rel((p)->pData, (ht)->persistent); \
|
||||
if ((p)->pData != &(p)->pDataPtr) { \
|
||||
pefree_rel((p)->pData, (ht)->persistent); \
|
||||
} \
|
||||
memcpy(&(p)->pDataPtr, pData, sizeof(void *)); \
|
||||
(p)->pData = &(p)->pDataPtr; \
|
||||
} else { \
|
||||
if ((p)->pDataPtr) { \
|
||||
(p)->pData = (void *) pemalloc_rel(nDataSize, (ht)->persistent); \
|
||||
if ((p)->pData == &(p)->pDataPtr) { \
|
||||
(p)->pData = (void *) pemalloc_rel(nDataSize, (ht)->persistent); \
|
||||
(p)->pDataPtr=NULL; \
|
||||
} else { \
|
||||
(p)->pData = (void *) perealloc_rel((p)->pData, nDataSize, (ht)->persistent); \
|
||||
@@ -123,9 +123,9 @@ ZEND_API ulong zend_hash_func(char *arKey, uint nKeyLength)
|
||||
memcpy(&(p)->pDataPtr, pData, sizeof(void *)); \
|
||||
(p)->pData = &(p)->pDataPtr; \
|
||||
} else { \
|
||||
(p)->pData = (void *) pemalloc_rel(nDataSize, (ht)->persistent); \
|
||||
(p)->pData = (void *) pemalloc_rel(nDataSize, (ht)->persistent);\
|
||||
if (!(p)->pData) { \
|
||||
pefree_rel(p, (ht)->persistent); \
|
||||
pefree_rel(p, (ht)->persistent); \
|
||||
return FAILURE; \
|
||||
} \
|
||||
memcpy((p)->pData, pData, nDataSize); \
|
||||
@@ -461,8 +461,10 @@ ZEND_API int zend_hash_del_key_or_index(HashTable *ht, char *arKey, uint nKeyLen
|
||||
|
||||
p = ht->arBuckets[nIndex];
|
||||
while (p != NULL) {
|
||||
if ((p->h == h) && ((p->nKeyLength == 0) || /* Numeric index */
|
||||
((p->nKeyLength == nKeyLength) && (!memcmp(p->arKey, arKey, nKeyLength))))) {
|
||||
if ((p->h == h)
|
||||
&& (p->nKeyLength == nKeyLength)
|
||||
&& ((p->nKeyLength == 0) /* Numeric index (short circuits the memcmp() check) */
|
||||
|| !memcmp(p->arKey, arKey, nKeyLength))) { /* String index */
|
||||
HANDLE_BLOCK_INTERRUPTIONS();
|
||||
if (p == ht->arBuckets[nIndex]) {
|
||||
ht->arBuckets[nIndex] = p->pNext;
|
||||
@@ -489,7 +491,7 @@ ZEND_API int zend_hash_del_key_or_index(HashTable *ht, char *arKey, uint nKeyLen
|
||||
if (ht->pDestructor) {
|
||||
ht->pDestructor(p->pData);
|
||||
}
|
||||
if (!p->pDataPtr) {
|
||||
if (p->pData != &p->pDataPtr) {
|
||||
pefree(p->pData, ht->persistent);
|
||||
}
|
||||
pefree(p, ht->persistent);
|
||||
@@ -518,7 +520,7 @@ ZEND_API void zend_hash_destroy(HashTable *ht)
|
||||
if (ht->pDestructor) {
|
||||
ht->pDestructor(q->pData);
|
||||
}
|
||||
if (!q->pDataPtr && q->pData) {
|
||||
if (q->pData != &q->pDataPtr) {
|
||||
pefree(q->pData, ht->persistent);
|
||||
}
|
||||
pefree(q, ht->persistent);
|
||||
@@ -544,7 +546,7 @@ ZEND_API void zend_hash_clean(HashTable *ht)
|
||||
if (ht->pDestructor) {
|
||||
ht->pDestructor(q->pData);
|
||||
}
|
||||
if (!q->pDataPtr && q->pData) {
|
||||
if (q->pData != &q->pDataPtr) {
|
||||
pefree(q->pData, ht->persistent);
|
||||
}
|
||||
pefree(q, ht->persistent);
|
||||
@@ -573,7 +575,7 @@ static Bucket *zend_hash_apply_deleter(HashTable *ht, Bucket *p)
|
||||
if (ht->pDestructor) {
|
||||
ht->pDestructor(p->pData);
|
||||
}
|
||||
if (!p->pDataPtr) {
|
||||
if (p->pData != &p->pDataPtr) {
|
||||
pefree(p->pData, ht->persistent);
|
||||
}
|
||||
retval = p->pListNext;
|
||||
@@ -732,11 +734,7 @@ ZEND_API void zend_hash_reverse_apply(HashTable *ht, apply_func_t apply_func TSR
|
||||
q = p;
|
||||
p = p->pListLast;
|
||||
if (result & ZEND_HASH_APPLY_REMOVE) {
|
||||
if (q->nKeyLength>0) {
|
||||
zend_hash_del(ht, q->arKey, q->nKeyLength);
|
||||
} else {
|
||||
zend_hash_index_del(ht, q->h);
|
||||
}
|
||||
zend_hash_apply_deleter(ht, q);
|
||||
}
|
||||
if (result & ZEND_HASH_APPLY_STOP) {
|
||||
break;
|
||||
@@ -1259,7 +1257,7 @@ ZEND_API int zend_hash_sort(HashTable *ht, sort_func_t sort_func,
|
||||
|
||||
ZEND_API int zend_hash_compare(HashTable *ht1, HashTable *ht2, compare_func_t compar, zend_bool ordered TSRMLS_DC)
|
||||
{
|
||||
Bucket *p1, *p2;
|
||||
Bucket *p1, *p2 = NULL;
|
||||
int result;
|
||||
void *pData2;
|
||||
|
||||
|
||||
+7
-1
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
@@ -353,6 +353,12 @@ static inline int zend_symtable_exists(HashTable *ht, char *arKey, uint nKeyLeng
|
||||
return zend_hash_exists(ht, arKey, nKeyLength);
|
||||
}
|
||||
|
||||
static inline int zend_symtable_update_current_key(HashTable *ht, char *arKey, uint nKeyLength)
|
||||
{
|
||||
HANDLE_NUMERIC(arKey, nKeyLength, zend_hash_update_current_key(ht, HASH_KEY_IS_LONG, NULL, 0, idx));
|
||||
return zend_hash_update_current_key(ht, HASH_KEY_IS_STRING, arKey, nKeyLength, 0);
|
||||
}
|
||||
|
||||
#endif /* ZEND_HASH_H */
|
||||
|
||||
/*
|
||||
|
||||
+19
-19
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
@@ -94,7 +94,7 @@ ZEND_API void zend_highlight(zend_syntax_highlighter_ini *syntax_highlighter_ini
|
||||
int token_type;
|
||||
char *last_color = syntax_highlighter_ini->highlight_html;
|
||||
char *next_color;
|
||||
int in_string=0, post_heredoc = 0;
|
||||
int in_string=0;
|
||||
|
||||
zend_printf("<code>");
|
||||
zend_printf("<span style=\"color: %s\">\n", last_color);
|
||||
@@ -151,19 +151,16 @@ ZEND_API void zend_highlight(zend_syntax_highlighter_ini *syntax_highlighter_ini
|
||||
switch (token_type) {
|
||||
case T_END_HEREDOC:
|
||||
zend_html_puts(token.value.str.val, token.value.str.len TSRMLS_CC);
|
||||
post_heredoc = 1;
|
||||
break;
|
||||
default:
|
||||
zend_html_puts(LANG_SCNG(yy_text), LANG_SCNG(yy_leng) TSRMLS_CC);
|
||||
if (post_heredoc) {
|
||||
zend_html_putc('\n');
|
||||
post_heredoc = 0;
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
if (token.type == IS_STRING) {
|
||||
switch (token_type) {
|
||||
case EOF:
|
||||
goto done;
|
||||
case T_OPEN_TAG:
|
||||
case T_OPEN_TAG_WITH_ECHO:
|
||||
case T_CLOSE_TAG:
|
||||
@@ -180,6 +177,7 @@ ZEND_API void zend_highlight(zend_syntax_highlighter_ini *syntax_highlighter_ini
|
||||
}
|
||||
token.type = 0;
|
||||
}
|
||||
done:
|
||||
if (last_color != syntax_highlighter_ini->highlight_html) {
|
||||
zend_printf("</span>\n");
|
||||
}
|
||||
@@ -208,20 +206,22 @@ ZEND_API void zend_strip(TSRMLS_D)
|
||||
case T_DOC_COMMENT:
|
||||
token.type = 0;
|
||||
continue;
|
||||
|
||||
case T_END_HEREDOC: {
|
||||
char *ptr = LANG_SCNG(yy_text);
|
||||
|
||||
zend_write(ptr, LANG_SCNG(yy_leng) - 1);
|
||||
/* The ensure that we only write one ; and that it followed by the required newline */
|
||||
zend_write("\n", sizeof("\n") - 1);
|
||||
if (ptr[LANG_SCNG(yy_leng) - 1] == ';') {
|
||||
lex_scan(&token TSRMLS_CC);
|
||||
}
|
||||
efree(token.value.str.val);
|
||||
}
|
||||
break;
|
||||
case EOF:
|
||||
return;
|
||||
|
||||
case T_END_HEREDOC:
|
||||
zend_write(LANG_SCNG(yy_text), LANG_SCNG(yy_leng));
|
||||
efree(token.value.str.val);
|
||||
/* read the following character, either newline or ; */
|
||||
if (lex_scan(&token TSRMLS_CC) != T_WHITESPACE) {
|
||||
zend_write(LANG_SCNG(yy_text), LANG_SCNG(yy_leng));
|
||||
}
|
||||
zend_write("\n", sizeof("\n") - 1);
|
||||
prev_space = 1;
|
||||
token.type = 0;
|
||||
continue;
|
||||
|
||||
default:
|
||||
zend_write(LANG_SCNG(yy_text), LANG_SCNG(yy_leng));
|
||||
break;
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
+1
-1
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
+1
-1
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
+1
-1
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
+1
-1
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
@@ -249,25 +249,26 @@ string_or_value:
|
||||
expr { $$ = $1; }
|
||||
| CFG_TRUE { $$ = $1; }
|
||||
| CFG_FALSE { $$ = $1; }
|
||||
| var_string_list { $$ = $1; }
|
||||
| '\n' { zend_ini_init_string(&$$); }
|
||||
| /* empty */ { zend_ini_init_string(&$$); }
|
||||
;
|
||||
|
||||
|
||||
var_string_list:
|
||||
var_string_list cfg_var_ref { zend_ini_add_string(&$$, &$1, &$2); free($2.value.str.val); }
|
||||
cfg_var_ref { $$ = $1; }
|
||||
| TC_ENCAPSULATED_STRING { $$ = $1; }
|
||||
| constant_string { $$ = $1; }
|
||||
| var_string_list cfg_var_ref { zend_ini_add_string(&$$, &$1, &$2); free($2.value.str.val); }
|
||||
| var_string_list TC_ENCAPSULATED_STRING { zend_ini_add_string(&$$, &$1, &$2); free($2.value.str.val); }
|
||||
| var_string_list constant_string { zend_ini_add_string(&$$, &$1, &$2); }
|
||||
| /* empty */ { zend_ini_init_string(&$$); }
|
||||
| var_string_list constant_string { zend_ini_add_string(&$$, &$1, &$2); free($2.value.str.val); }
|
||||
;
|
||||
|
||||
cfg_var_ref:
|
||||
TC_DOLLAR_CURLY TC_STRING '}' { zend_ini_get_var(&$$, &$2); }
|
||||
TC_DOLLAR_CURLY TC_STRING '}' { zend_ini_get_var(&$$, &$2); free($2.value.str.val); }
|
||||
;
|
||||
|
||||
expr:
|
||||
constant_string { $$ = $1; }
|
||||
var_string_list { $$ = $1; }
|
||||
| expr '|' expr { zend_ini_do_op('|', &$$, &$1, &$3); }
|
||||
| expr '&' expr { zend_ini_do_op('&', &$$, &$1, &$3); }
|
||||
| '~' expr { zend_ini_do_op('~', &$$, &$2, NULL); }
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
+11
-1
@@ -3,7 +3,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
@@ -139,8 +139,18 @@ NEWLINE ("\r"|"\n"|"\r\n")
|
||||
|
||||
|
||||
<INITIAL>["][^"]*["] {
|
||||
char *p = yytext;
|
||||
|
||||
/* ENCAPSULATED TC_STRING */
|
||||
|
||||
while ((p = strpbrk(p, "\r\n"))) {
|
||||
if (*p == '\r' && *(p + 1) == '\n') {
|
||||
p++;
|
||||
}
|
||||
SCNG(lineno)++;
|
||||
p++;
|
||||
}
|
||||
|
||||
/* eat trailing " */
|
||||
yytext[yyleng-1]=0;
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
@@ -287,7 +287,7 @@ static zend_object_iterator *zend_user_it_get_new_iterator(zend_class_entry *ce,
|
||||
if (!ce || !ce_it || !ce_it->get_iterator || (ce_it->get_iterator == zend_user_it_get_new_iterator && iterator == object)) {
|
||||
if (!EG(exception))
|
||||
{
|
||||
zend_throw_exception_ex(NULL, 0 TSRMLS_CC, "Objects returned by %s::getIterator() must be traversable or implement interface Iterator", ce->name);
|
||||
zend_throw_exception_ex(NULL, 0 TSRMLS_CC, "Objects returned by %s::getIterator() must be traversable or implement interface Iterator", ce ? ce->name : Z_OBJCE_P(object)->name);
|
||||
}
|
||||
if (iterator)
|
||||
{
|
||||
@@ -336,7 +336,7 @@ static int zend_implement_aggregate(zend_class_entry *interface, zend_class_entr
|
||||
} else if (class_type->get_iterator != zend_user_it_get_new_iterator) {
|
||||
/* c-level get_iterator cannot be changed (exception being only Traversable is implmented) */
|
||||
if (class_type->num_interfaces) {
|
||||
for (i = 0; i < class_type->num_interfaces; i++) {
|
||||
for (i = 0; i < (int)class_type->num_interfaces; i++) {
|
||||
if (class_type->interfaces[i] == zend_ce_iterator) {
|
||||
return FAILURE;
|
||||
}
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2005 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
| Copyright (c) 1998-2006 Zend Technologies Ltd. (http://www.zend.com) |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 2.00 of the Zend license, |
|
||||
| that is bundled with this package in the file LICENSE, and is |
|
||||
@@ -501,7 +501,7 @@ method_body:
|
||||
|
||||
variable_modifiers:
|
||||
non_empty_member_modifiers { $$ = $1; }
|
||||
| T_VAR { zend_error(E_STRICT, "var: Deprecated. Please use the public/private/protected modifiers"); $$.u.constant.value.lval = ZEND_ACC_PUBLIC; }
|
||||
| T_VAR { $$.u.constant.value.lval = ZEND_ACC_PUBLIC; }
|
||||
;
|
||||
|
||||
method_modifiers:
|
||||
|
||||
Loaded 100 of 1631 files, more files were not shown because too many files have changed in this diff.
Show more
Reference in new issue
Block a user