mirror of
https://github.com/bdnugget/php-src.git
synced 2026-11-10 18:50:50 +00:00
Compare commits
3249
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
61bc82795d | ||
|
|
2053bc60d2 | ||
|
|
25f5ea0398 | ||
|
|
1618452e53 | ||
|
|
307eedeffe | ||
|
|
aad180c93f | ||
|
|
b38423c7f6 | ||
|
|
f62069244a | ||
|
|
6aecc4c6d6 | ||
|
|
a8d2d22d9b | ||
|
|
8f5c250266 | ||
|
|
8ee3553aa4 | ||
|
|
12e1c89041 | ||
|
|
40329bff38 | ||
|
|
b9d3aafe55 | ||
|
|
7966bb1186 | ||
|
|
5e2f6ea744 | ||
|
|
354eff7e1e | ||
|
|
9a5f0ef61a | ||
|
|
df0d52bd78 | ||
|
|
baed8167d6 | ||
|
|
47b6b1e28a | ||
|
|
a063cc2956 | ||
|
|
5e5de1960f | ||
|
|
893aee30e8 | ||
|
|
30b2af9511 | ||
|
|
03edfa1677 | ||
|
|
1a9d759fc4 | ||
|
|
b8a8640846 | ||
|
|
e384ab1666 | ||
|
|
c50ef2e715 | ||
|
|
f17eff3a6c | ||
|
|
e7e54fccac | ||
|
|
9c488ef4f2 | ||
|
|
5a3baf610b | ||
|
|
9dd0472573 | ||
|
|
900eaa32f3 | ||
|
|
8635889231 | ||
|
|
c0cea96139 | ||
|
|
45fa60d315 | ||
|
|
b7479f6c29 | ||
|
|
27c3401da5 | ||
|
|
8761f766d4 | ||
|
|
22214bc11e | ||
|
|
5eaf82b6eb | ||
|
|
f93672da8e | ||
|
|
7be44d2b6d | ||
|
|
e864dc5b13 | ||
|
|
41da69f20f | ||
|
|
879cbe7961 | ||
|
|
739846a6a8 | ||
|
|
e5d7aef143 | ||
|
|
47692de95f | ||
|
|
6be3e2d751 | ||
|
|
e69edbeac2 | ||
|
|
86b31b56de | ||
|
|
efb6da662d | ||
|
|
7f8bbde609 | ||
|
|
338de41cf9 | ||
|
|
139deb5ddb | ||
|
|
6d859da0da | ||
|
|
8f242bb48b | ||
|
|
7afbc02392 | ||
|
|
e3aa91d3f3 | ||
|
|
8838b0f114 | ||
|
|
349514ed2d | ||
|
|
d676db7541 | ||
|
|
b7c800e6fb | ||
|
|
ba9faa42a0 | ||
|
|
164703f306 | ||
|
|
a9d700c5c7 | ||
|
|
a750e94013 | ||
|
|
bbf5e08fa3 | ||
|
|
1be1a0b472 | ||
|
|
072961be7b | ||
|
|
9f7829fb47 | ||
|
|
80dfa0ba37 | ||
|
|
d1be87446b | ||
|
|
4c9527044b | ||
|
|
7de0f803d1 | ||
|
|
208a735a85 | ||
|
|
58466f957f | ||
|
|
06fd453fb9 | ||
|
|
2d9549455d | ||
|
|
7aa63c6209 | ||
|
|
bc594f1506 | ||
|
|
b5d2a4aa12 | ||
|
|
a20b67c30f | ||
|
|
1aad1b4291 | ||
|
|
6fc504ce16 | ||
|
|
b24de2d58a | ||
|
|
4c5521ad81 | ||
|
|
808dee23d7 | ||
|
|
4c722bee9c | ||
|
|
19db79ff1d | ||
|
|
e3727d1061 | ||
|
|
43d81b700a | ||
|
|
a6ea6cc87c | ||
|
|
9f6f2471f0 | ||
|
|
90adf3ec54 | ||
|
|
de83567151 | ||
|
|
c6af3e463a | ||
|
|
09d9532952 | ||
|
|
4e9e5c1913 | ||
|
|
9a9864a0e9 | ||
|
|
065d0986aa | ||
|
|
8a088529c9 | ||
|
|
908f37b08b | ||
|
|
ea2fa14acb | ||
|
|
ebf7a4f847 | ||
|
|
46d273a2b9 | ||
|
|
4293672558 | ||
|
|
f5865d02d0 | ||
|
|
cf3d459815 | ||
|
|
fcfe6ff818 | ||
|
|
88b30630b2 | ||
|
|
9d4bd52adf | ||
|
|
bf45f6d5ba | ||
|
|
76c42836b2 | ||
|
|
fd4dea3500 | ||
|
|
c1134d6bb9 | ||
|
|
9166d10260 | ||
|
|
fa843198d4 | ||
|
|
e5a94e640e | ||
|
|
3a95b4b173 | ||
|
|
8a6f9ab5c0 | ||
|
|
9a87c59f72 | ||
|
|
831caad432 | ||
|
|
0ef09b9609 | ||
|
|
df1e5064e7 | ||
|
|
ad63c6c086 | ||
|
|
8d802f10f0 | ||
|
|
6c192034a2 | ||
|
|
3bab4824f0 | ||
|
|
951f80976b | ||
|
|
0e00c049c7 | ||
|
|
e85ca0efce | ||
|
|
56c1fec8d8 | ||
|
|
4b1deca2e1 | ||
|
|
c40ac6b268 | ||
|
|
8e07a4fd52 | ||
|
|
5336ad6dbd | ||
|
|
e1fa70df9a | ||
|
|
85923625fe | ||
|
|
de9e6e1f1b | ||
|
|
b145f87d40 | ||
|
|
f579d02059 | ||
|
|
2058fec25b | ||
|
|
6c63a9e153 | ||
|
|
4de55b50dc | ||
|
|
bbdbfa8563 | ||
|
|
cc5e0df571 | ||
|
|
d528916296 | ||
|
|
0cd7e11430 | ||
|
|
772523e4a8 | ||
|
|
5f1a942add | ||
|
|
ddbc35b39c | ||
|
|
ea3c36078c | ||
|
|
24e9c2b3ff | ||
|
|
6241abce94 | ||
|
|
53b5689016 | ||
|
|
7eed89deb7 | ||
|
|
06f91140fe | ||
|
|
0825bb2386 | ||
|
|
64fe4952b6 | ||
|
|
96b2eaca0d | ||
|
|
ffe1113b3d | ||
|
|
db9a8f2f5e | ||
|
|
6efb1b369c | ||
|
|
538a818db0 | ||
|
|
9934670186 | ||
|
|
89206cfca4 | ||
|
|
cb8e1f16ee | ||
|
|
1af4d7724f | ||
|
|
7e941eefe8 | ||
|
|
885e837b2a | ||
|
|
6a3fc10b05 | ||
|
|
e96b4d55bd | ||
|
|
5188dd875f | ||
|
|
6f431d5d6d | ||
|
|
4e78551db1 | ||
|
|
9de151b2ce | ||
|
|
91786ab7a5 | ||
|
|
0bf404dbeb | ||
|
|
e566c744d1 | ||
|
|
a96a6a2b7f | ||
|
|
f51237d726 | ||
|
|
b1061c7443 | ||
|
|
5d3a542a08 | ||
|
|
20c0fb5e9c | ||
|
|
e89ac09125 | ||
|
|
94728f7301 | ||
|
|
e65f145d46 | ||
|
|
2986565c79 | ||
|
|
e2088baab4 | ||
|
|
3263cdd42e | ||
|
|
c6a2f0628d | ||
|
|
39dc110f91 | ||
|
|
a3b179d916 | ||
|
|
84b6a9dfb3 | ||
|
|
c6b98d3891 | ||
|
|
8621923a5e | ||
|
|
c096e54196 | ||
|
|
663841fd31 | ||
|
|
02ab9ce41d | ||
|
|
442c6c9c6f | ||
|
|
5df1e69be1 | ||
|
|
f7226bcc2d | ||
|
|
0b9b69be38 | ||
|
|
5888fd4024 | ||
|
|
1b2b9a6a0d | ||
|
|
a207ace664 | ||
|
|
38b637bdfc | ||
|
|
a96582f13b | ||
|
|
8cf790dea1 | ||
|
|
e58b48e89c | ||
|
|
210d34a088 | ||
|
|
ed5a974ab0 | ||
|
|
bb7f2e4210 | ||
|
|
31b2848051 | ||
|
|
5ebe7edcb3 | ||
|
|
ed68bc6095 | ||
|
|
6a9e52543b | ||
|
|
f1c31423d7 | ||
|
|
441dc97d75 | ||
|
|
8378373527 | ||
|
|
d76514d892 | ||
|
|
2bbfddb533 | ||
|
|
85e5585a1c | ||
|
|
e6840ed921 | ||
|
|
cb20f5cafe | ||
|
|
a95a14cebf | ||
|
|
8b9cc5ba81 | ||
|
|
259a07f733 | ||
|
|
a9674113d1 | ||
|
|
168786cfcf | ||
|
|
3f43cfbb6a | ||
|
|
93578a5789 | ||
|
|
89eaec22b5 | ||
|
|
a99c6916f3 | ||
|
|
30c8d9b166 | ||
|
|
5a6d9048e5 | ||
|
|
0e9275fb37 | ||
|
|
b08b041503 | ||
|
|
9c340ef86f | ||
|
|
baf702a009 | ||
|
|
65ab4040fc | ||
|
|
c3d0c735b8 | ||
|
|
1a5342e468 | ||
|
|
eeaaaf7fce | ||
|
|
5dd18df5eb | ||
|
|
6deb70d17d | ||
|
|
5babe27344 | ||
|
|
ac4adcc2f7 | ||
|
|
46e793d8dc | ||
|
|
cc2149097f | ||
|
|
cdb852e21f | ||
|
|
c18cbd0f35 | ||
|
|
40fe027642 | ||
|
|
2184a5a584 | ||
|
|
b2f06ce507 | ||
|
|
80553d8fc7 | ||
|
|
5b4eeb628c | ||
|
|
2af0c3bbdf | ||
|
|
d4e86c36ed | ||
|
|
fe4a118383 | ||
|
|
ada04f382d | ||
|
|
e1505662ad | ||
|
|
3766f870d4 | ||
|
|
e4c30e6b89 | ||
|
|
9543e9c111 | ||
|
|
d0551c2a7c | ||
|
|
66df106383 | ||
|
|
4c6e92bdb8 | ||
|
|
b2732089f2 | ||
|
|
8e8f8ece29 | ||
|
|
7275b5a177 | ||
|
|
5f0305e605 | ||
|
|
2a0e69c111 | ||
|
|
74c2e50253 | ||
|
|
cb915e0498 | ||
|
|
3379ffa7ed | ||
|
|
0053324a83 | ||
|
|
a0c001aa70 | ||
|
|
7b6a710bd0 | ||
|
|
221d4b346b | ||
|
|
1e60e670ba | ||
|
|
fdec1ab00e | ||
|
|
1aac6063a4 | ||
|
|
0808ccd417 | ||
|
|
61c00477b4 | ||
|
|
9ea8c7ddd4 | ||
|
|
d6cc9d4f01 | ||
|
|
c07cd30cd0 | ||
|
|
c9af2f28e2 | ||
|
|
ea54e26972 | ||
|
|
0ac2170517 | ||
|
|
bd6b53c1d8 | ||
|
|
ca90ec2cac | ||
|
|
91abce9917 | ||
|
|
4cc252ca16 | ||
|
|
1ed5d89106 | ||
|
|
c262cf962c | ||
|
|
8e510ef9b9 | ||
|
|
1aaadf3ca3 | ||
|
|
ca98ed755c | ||
|
|
2fe16812bd | ||
|
|
a300b68b08 | ||
|
|
b9d98f0098 | ||
|
|
deb89ce2f4 | ||
|
|
405101d10d | ||
|
|
bc11725188 | ||
|
|
938e964beb | ||
|
|
49118556bb | ||
|
|
47d30e40e4 | ||
|
|
4135978add | ||
|
|
86bdf2b049 | ||
|
|
1d6cca1b2f | ||
|
|
1e12ed5e1a | ||
|
|
6fe6810c8a | ||
|
|
408c183013 | ||
|
|
cdb4683c30 | ||
|
|
3a6eb48e1e | ||
|
|
2706fda4a6 | ||
|
|
fafe8a19b8 | ||
|
|
69eaab8aac | ||
|
|
6035439314 | ||
|
|
79ed81e971 | ||
|
|
ca53f68729 | ||
|
|
2b66aa860f | ||
|
|
17cef37fd1 | ||
|
|
fa2f1ac2a4 | ||
|
|
a9e21b0a18 | ||
|
|
353b838a13 | ||
|
|
a68c033bf9 | ||
|
|
8c7af900cf | ||
|
|
8e46f4b273 | ||
|
|
86337bac18 | ||
|
|
125d5a2b73 | ||
|
|
de23ffbee3 | ||
|
|
6af73a9f5e | ||
|
|
df8c668559 | ||
|
|
c346be31a1 | ||
|
|
a360d7d794 | ||
|
|
a9b6b75a02 | ||
|
|
fa8c24ff7a | ||
|
|
fb4f76e78d | ||
|
|
f261a8f571 | ||
|
|
5bffdef46d | ||
|
|
d48d599294 | ||
|
|
2b637a2c03 | ||
|
|
e26531e7c3 | ||
|
|
55142148ad | ||
|
|
b9147e80a6 | ||
|
|
96338f74c5 | ||
|
|
0bf4ee95b6 | ||
|
|
697102558f | ||
|
|
e5a2da9811 | ||
|
|
1ca21fdf96 | ||
|
|
66fee7dd46 | ||
|
|
f62beb8487 | ||
|
|
25d980f23c | ||
|
|
33d0cdb426 | ||
|
|
99bcc186f6 | ||
|
|
e596539840 | ||
|
|
0a00d25a28 | ||
|
|
6467ac57d6 | ||
|
|
dd4d0ba050 | ||
|
|
7afa3484c0 | ||
|
|
d525845531 | ||
|
|
ce983dad77 | ||
|
|
5e8bee0b4d | ||
|
|
4e151b1c7d | ||
|
|
ca47777e5f | ||
|
|
0ffeb8f5cd | ||
|
|
195dcc7eda | ||
|
|
c28909f9d9 | ||
|
|
2667855bad | ||
|
|
3887735c4c | ||
|
|
056bb1ad7c | ||
|
|
50f57d6cbb | ||
|
|
074b68fe73 | ||
|
|
bb0973e294 | ||
|
|
223398e0fa | ||
|
|
aef84ceb00 | ||
|
|
55f2a16d01 | ||
|
|
65fa341a3e | ||
|
|
643b271bea | ||
|
|
3b61fc5389 | ||
|
|
8a67145847 | ||
|
|
cef2c74845 | ||
|
|
202500193d | ||
|
|
6505875c9a | ||
|
|
c49fdf4dd8 | ||
|
|
ed53d131ea | ||
|
|
8bb1db38f8 | ||
|
|
29f088a033 | ||
|
|
a081107225 | ||
|
|
d16b06c185 | ||
|
|
c1b09a29f2 | ||
|
|
7b25877fec | ||
|
|
27959e82ec | ||
|
|
c74a480546 | ||
|
|
935ed0d844 | ||
|
|
bfc284dfb5 | ||
|
|
92deeac732 | ||
|
|
6e22b67233 | ||
|
|
31f10bc418 | ||
|
|
331b6605c3 | ||
|
|
e902399d15 | ||
|
|
90583839db | ||
|
|
bdfe271088 | ||
|
|
fe2eb8697f | ||
|
|
d8d8abeee8 | ||
|
|
5207463590 | ||
|
|
fc6aba5bea | ||
|
|
f22177b7e4 | ||
|
|
633a7470d1 | ||
|
|
17d0b30415 | ||
|
|
12d27576f3 | ||
|
|
0b74da4a4a | ||
|
|
09f6f3244b | ||
|
|
5f19e3c747 | ||
|
|
936b7e8e82 | ||
|
|
41904eb4b2 | ||
|
|
baa7c1746e | ||
|
|
f9ee999b71 | ||
|
|
28686f683f | ||
|
|
fea2f6e689 | ||
|
|
cbc8c32567 | ||
|
|
70e26f8ebc | ||
|
|
a6dcd940b5 | ||
|
|
a8202c83d3 | ||
|
|
a5952e9c8b | ||
|
|
4da78a716c | ||
|
|
e41bc6906c | ||
|
|
1f0fe33edb | ||
|
|
422dfcaf3e | ||
|
|
0f7556a1b8 | ||
|
|
bea9ba8fc2 | ||
|
|
3b61552cd7 | ||
|
|
77e02d2e30 | ||
|
|
9058adacc8 | ||
|
|
ab99e92450 | ||
|
|
b539f500fc | ||
|
|
a85cfe5b14 | ||
|
|
f7aef14323 | ||
|
|
8ea0a2c1c8 | ||
|
|
7f529a8361 | ||
|
|
9a0060e27c | ||
|
|
90f72e11bf | ||
|
|
c0d963299a | ||
|
|
cc6dd2f296 | ||
|
|
1fc017d8a3 | ||
|
|
aa288c1f7a | ||
|
|
f899afbfca | ||
|
|
f9279a6b81 | ||
|
|
3cee600ed8 | ||
|
|
a0c6c4f59f | ||
|
|
f2307f1623 | ||
|
|
e03bd905ad | ||
|
|
03db21ee2c | ||
|
|
9235a5d001 | ||
|
|
2a7a76c93e | ||
|
|
1fe64c5ffb | ||
|
|
eb74b414a8 | ||
|
|
0fa2ebc0f2 | ||
|
|
160852eaf0 | ||
|
|
338a796166 | ||
|
|
ba634aacd4 | ||
|
|
437a1e90c9 | ||
|
|
c8dbe95e7a | ||
|
|
f8fa606849 | ||
|
|
60cd2d0604 | ||
|
|
9349ad79ff | ||
|
|
6aeafbd611 | ||
|
|
4f3b9cd691 | ||
|
|
348078406d | ||
|
|
f9bc86556e | ||
|
|
d7d8388543 | ||
|
|
7e950b6a31 | ||
|
|
98dc115fab | ||
|
|
1c9c0f592c | ||
|
|
bf93051fff | ||
|
|
fc3db427b2 | ||
|
|
f3543b425f | ||
|
|
6741fc0883 | ||
|
|
cf2b96f84b | ||
|
|
49e7c1eb7a | ||
|
|
1018001888 | ||
|
|
4d2cdc8224 | ||
|
|
4ae82d2189 | ||
|
|
0e6a306e68 | ||
|
|
a4935ca741 | ||
|
|
162fb6f465 | ||
|
|
f72080cb48 | ||
|
|
e0eaa22d19 | ||
|
|
046da9b906 | ||
|
|
3d3d33c018 | ||
|
|
76a19ecdf8 | ||
|
|
09d6b582ae | ||
|
|
e61a8d577c | ||
|
|
8c0e3568a9 | ||
|
|
cdbfc6a8fb | ||
|
|
5a7f4ada80 | ||
|
|
bf7636d282 | ||
|
|
9973b97212 | ||
|
|
e5b8ff2641 | ||
|
|
6d227b5775 | ||
|
|
d5a0cf3575 | ||
|
|
30f6668c7d | ||
|
|
5f32f2e6a1 | ||
|
|
aade4a6069 | ||
|
|
45b85c504b | ||
|
|
2d5754d69f | ||
|
|
10b70c23ae | ||
|
|
1ceef81ac8 | ||
|
|
f26881fdc0 | ||
|
|
2f7e889009 | ||
|
|
6119dad1ec | ||
|
|
a450efff4e | ||
|
|
ceda30930a | ||
|
|
1729d3ca75 | ||
|
|
4115b9aa6c | ||
|
|
1303e186e5 | ||
|
|
7ba00c2563 | ||
|
|
112bc3df71 | ||
|
|
318fc44c8a | ||
|
|
6771367c95 | ||
|
|
7999d1a384 | ||
|
|
82321ff0d4 | ||
|
|
da74ef221f | ||
|
|
2c28506fcf | ||
|
|
592380ac7c | ||
|
|
a4c86a50bb | ||
|
|
d28971a2b6 | ||
|
|
9b225deeb2 | ||
|
|
3f5a393d9c | ||
|
|
2361a14e0f | ||
|
|
5d7f648f83 | ||
|
|
f766cea8af | ||
|
|
6cdf895b62 | ||
|
|
60661a012b | ||
|
|
b93038396e | ||
|
|
12defebcf0 | ||
|
|
8e0820820a | ||
|
|
087326527e | ||
|
|
5061d1ca32 | ||
|
|
7f504d30ea | ||
|
|
0479203e55 | ||
|
|
ee840f1ff6 | ||
|
|
580d5e80b5 | ||
|
|
8c4361d2f1 | ||
|
|
c6e131f9a4 | ||
|
|
83bec74173 | ||
|
|
a1f00c0bae | ||
|
|
ed54147a4b | ||
|
|
e4b49f2de7 | ||
|
|
b8cd29330d | ||
|
|
a4d189ed94 | ||
|
|
53d0e56f42 | ||
|
|
37871089e1 | ||
|
|
396074e1cc | ||
|
|
da55f714a9 | ||
|
|
8d025a62fb | ||
|
|
74540e51a7 | ||
|
|
1592b88645 | ||
|
|
9dfae5b28d | ||
|
|
bdf9ed31c0 | ||
|
|
cd5ef04293 | ||
|
|
67674a77c7 | ||
|
|
8633a4fb0e | ||
|
|
7efed1c11d | ||
|
|
e0f235787c | ||
|
|
ac05068dd2 | ||
|
|
ee1077aad0 | ||
|
|
6c22098068 | ||
|
|
de3937a88f | ||
|
|
5f4df19833 | ||
|
|
cfeec1e72b | ||
|
|
c77e4951c5 | ||
|
|
5f0729c281 | ||
|
|
1525e15d4f | ||
|
|
4c86e3b2bf | ||
|
|
680dd335bc | ||
|
|
575bd9e537 | ||
|
|
f8fed9d571 | ||
|
|
6aa5175259 | ||
|
|
fe4e7d7b43 | ||
|
|
188d80b7cf | ||
|
|
04a57e2f54 | ||
|
|
68d477c66a | ||
|
|
5fd7263f01 | ||
|
|
f93c6a6a13 | ||
|
|
c878f2708e | ||
|
|
c16bbec898 | ||
|
|
91f0d18894 | ||
|
|
ead22712c9 | ||
|
|
405fcde229 | ||
|
|
e1823b67c2 | ||
|
|
37f824c02a | ||
|
|
b3f36ce142 | ||
|
|
ed1af8a375 | ||
|
|
19d34e9304 | ||
|
|
6f718d420d | ||
|
|
a844072181 | ||
|
|
3a09eb44cf | ||
|
|
67ba3f4c30 | ||
|
|
bbbf8effb4 | ||
|
|
16f65cff5b | ||
|
|
d20c4bc95a | ||
|
|
34c2d8f7a2 | ||
|
|
bbd07ddfff | ||
|
|
3f5a2f35e6 | ||
|
|
5354a79497 | ||
|
|
27298684b2 | ||
|
|
d038c0e046 | ||
|
|
d95ee6d92a | ||
|
|
d3e82a6876 | ||
|
|
a8e94dd8c3 | ||
|
|
c3b2390ea8 | ||
|
|
90957978ab | ||
|
|
06659b28ba | ||
|
|
894f2c9be2 | ||
|
|
c85bca1758 | ||
|
|
12b32d871f | ||
|
|
02ca709afd | ||
|
|
4ffec49140 | ||
|
|
460d1dfaeb | ||
|
|
5e6d8ed2d1 | ||
|
|
79c6c1efbe | ||
|
|
ffa0515b59 | ||
|
|
69796efc37 | ||
|
|
d6541cb740 | ||
|
|
f0b9f4beca | ||
|
|
7765e06ef7 | ||
|
|
6e105b5751 | ||
|
|
52e0410d8e | ||
|
|
c30dfcbd20 | ||
|
|
176f804d75 | ||
|
|
7d60c49e0e | ||
|
|
c4871a7329 | ||
|
|
0d260304dc | ||
|
|
61a601cb12 | ||
|
|
26d3d83a4d | ||
|
|
6d124bfc5e | ||
|
|
10a18840da | ||
|
|
e58611c0c7 | ||
|
|
d71244b42b | ||
|
|
c26e78f88a | ||
|
|
b5fb634af4 | ||
|
|
5bc3f3656a | ||
|
|
13a5ff7119 | ||
|
|
8d9bd14c18 | ||
|
|
c47c73519e | ||
|
|
174f14c76b | ||
|
|
bafccc7dbf | ||
|
|
7b1f6c319e | ||
|
|
a5a3d7b657 | ||
|
|
10b71e08e1 | ||
|
|
869f61fcf8 | ||
|
|
fa90d82b27 | ||
|
|
c3fd539306 | ||
|
|
eae45bec5c | ||
|
|
812f7748a6 | ||
|
|
58a2f7d6a9 | ||
|
|
2dabb19a5a | ||
|
|
e08feebfd5 | ||
|
|
aa359d95e3 | ||
|
|
02b56d1709 | ||
|
|
202d0cb224 | ||
|
|
7aa8ca5e6f | ||
|
|
95e990757d | ||
|
|
9e1dd60032 | ||
|
|
e2cce3325b | ||
|
|
40ffe5ed82 | ||
|
|
5958582185 | ||
|
|
b564d1f137 | ||
|
|
b828a3c43c | ||
|
|
bd5b1ff74f | ||
|
|
e246ca1ef6 | ||
|
|
b6752a1393 | ||
|
|
00203d2968 | ||
|
|
038e99660f | ||
|
|
ed5212ca70 | ||
|
|
7dc3d8bd0e | ||
|
|
701b075782 | ||
|
|
0fff37b01a | ||
|
|
3af4920403 | ||
|
|
d6bb1fd35a | ||
|
|
94f7723659 | ||
|
|
571ca7f26e | ||
|
|
3d08aea7da | ||
|
|
4c9381c538 | ||
|
|
bc087095be | ||
|
|
61e6878898 | ||
|
|
43209b4bf6 | ||
|
|
ca763cac46 | ||
|
|
43cf3d6f66 | ||
|
|
005dfa3c04 | ||
|
|
112c1def73 | ||
|
|
9c1611188c | ||
|
|
1406239f9a | ||
|
|
0958e5a5cb | ||
|
|
ac0a394ffa | ||
|
|
d80b742e44 | ||
|
|
227088c36b | ||
|
|
09529af3b0 | ||
|
|
e8a8dac741 | ||
|
|
0bf7c7781c | ||
|
|
f03caa7b35 | ||
|
|
84eb811be9 | ||
|
|
86da4546de | ||
|
|
9006d8e97b | ||
|
|
e189a15dbf | ||
|
|
88ccac85f3 | ||
|
|
f22b3a19cf | ||
|
|
78f795af80 | ||
|
|
4b18e8086a | ||
|
|
73b34fff94 | ||
|
|
dc04255655 | ||
|
|
c254e0f3ee | ||
|
|
dca5128c58 | ||
|
|
64ee4a850e | ||
|
|
8ff5296643 | ||
|
|
9a24af562c | ||
|
|
e943420bbb | ||
|
|
4608fd6e3f | ||
|
|
370a9e6266 | ||
|
|
59835d886b | ||
|
|
17a411d422 | ||
|
|
393dfba684 | ||
|
|
6d369a51c8 | ||
|
|
9decf616c9 | ||
|
|
f4d96cee48 | ||
|
|
afd5493707 | ||
|
|
7df5e203c6 | ||
|
|
36478058f4 | ||
|
|
fe871be5ca | ||
|
|
25679a60c7 | ||
|
|
afd9e80cb1 | ||
|
|
2361e1e342 | ||
|
|
e41125d052 | ||
|
|
5be79b203b | ||
|
|
9c4b602ee2 | ||
|
|
27879d0f0d | ||
|
|
800b1765ae | ||
|
|
0e93bfdbc3 | ||
|
|
7b7543afad | ||
|
|
4bd822a180 | ||
|
|
35e0567b62 | ||
|
|
4191d2bde1 | ||
|
|
ef14bdb691 | ||
|
|
69cfb62619 | ||
|
|
adfb56c304 | ||
|
|
f335d5447e | ||
|
|
ef89c82c02 | ||
|
|
4c28ca442f | ||
|
|
3a63f098bd | ||
|
|
c0ddfe89e2 | ||
|
|
da62e960e2 | ||
|
|
d0d3b02de7 | ||
|
|
2ce3e8cdec | ||
|
|
2a1bfae434 | ||
|
|
ac534dbf37 | ||
|
|
2aeb246874 | ||
|
|
18a2f7bab4 | ||
|
|
8b2def80d0 | ||
|
|
f0ae93e466 | ||
|
|
21616c7854 | ||
|
|
116956cc64 | ||
|
|
2dd02323c0 | ||
|
|
a85a72e29a | ||
|
|
7492d02cb2 | ||
|
|
52d5dd4da5 | ||
|
|
16ab834b5e | ||
|
|
1b60fa245e | ||
|
|
c057fc931a | ||
|
|
10243d019d | ||
|
|
a13710455c | ||
|
|
cfac03af3c | ||
|
|
39894c69cd | ||
|
|
59d28ed4df | ||
|
|
e2cf657294 | ||
|
|
d18b7a533a | ||
|
|
9308d262d0 | ||
|
|
ad791c135c | ||
|
|
48900111a8 | ||
|
|
61e4791abe | ||
|
|
9b708216d5 | ||
|
|
f692aeb36b | ||
|
|
3a867aad64 | ||
|
|
e4a63807a1 | ||
|
|
1a92434b06 | ||
|
|
2dfed48c99 | ||
|
|
1c2b48e0ca | ||
|
|
fea1d6c1fb | ||
|
|
a754abdc5f | ||
|
|
a56a817706 | ||
|
|
e547d66316 | ||
|
|
d6f18bd5f3 | ||
|
|
6d0d0172f3 | ||
|
|
e2e0cfb6fa | ||
|
|
ec1d763fd2 | ||
|
|
d88229acba | ||
|
|
eb00f1dd54 | ||
|
|
adec65bea6 | ||
|
|
a82bc1b50c | ||
|
|
7620efc274 | ||
|
|
45775e2029 | ||
|
|
46eecba03b | ||
|
|
6e6732ae6a | ||
|
|
9c33e3d3ce | ||
|
|
fff1d6a533 | ||
|
|
ab2ba0f49f | ||
|
|
bda27d167f | ||
|
|
edff9053e8 | ||
|
|
60d11d734c | ||
|
|
5e9a4ecc0e | ||
|
|
0d59c975a0 | ||
|
|
6db270f8fc | ||
|
|
a11f040979 | ||
|
|
e2a74cf344 | ||
|
|
89dde23f32 | ||
|
|
a07e4ef2ff | ||
|
|
a60b5db89e | ||
|
|
85bffe131e | ||
|
|
361aa7dd32 | ||
|
|
e5b50cede5 | ||
|
|
b5b29e267e | ||
|
|
d632dba1ef | ||
|
|
4704bb7186 | ||
|
|
b1eafc6a75 | ||
|
|
c2a66c59c6 | ||
|
|
cb9b99262e | ||
|
|
480e8dd7fc | ||
|
|
f1b478c291 | ||
|
|
a23dfb3b11 | ||
|
|
5646e5f747 | ||
|
|
ee9deb187a | ||
|
|
806c28b5c2 | ||
|
|
8103e07a23 | ||
|
|
de85bccf03 | ||
|
|
18557cba09 | ||
|
|
2fb568e65e | ||
|
|
94f05e60c2 | ||
|
|
2bf4ba798f | ||
|
|
0d6bac093d | ||
|
|
f17845f9bd | ||
|
|
40a1c4b4f4 | ||
|
|
283476972f | ||
|
|
8acd0a3835 | ||
|
|
925a3b6ba8 | ||
|
|
149d034a81 | ||
|
|
b485c4f26c | ||
|
|
db8d5a7fb0 | ||
|
|
ee3c85162f | ||
|
|
ccc0fb6122 | ||
|
|
d18b757655 | ||
|
|
08604e5d44 | ||
|
|
ce2f1ce4bc | ||
|
|
872948f21a | ||
|
|
491cf63bab | ||
|
|
675a41bee2 | ||
|
|
5714f48f4c | ||
|
|
05331829c6 | ||
|
|
258d90d101 | ||
|
|
8d28cb5737 | ||
|
|
c1a998a604 | ||
|
|
ca4d592e11 | ||
|
|
42d1578fb4 | ||
|
|
36e88551eb | ||
|
|
fea99094df | ||
|
|
5b3a654f07 | ||
|
|
0e09bbae14 | ||
|
|
3fcd022dc5 | ||
|
|
66ac209938 | ||
|
|
bbbf1df01d | ||
|
|
3857aa4f7d | ||
|
|
b4bed3fd88 | ||
|
|
776587fdac | ||
|
|
d0d8c4a6a3 | ||
|
|
353dd2444a | ||
|
|
472aaf3f50 | ||
|
|
186e6dc1ba | ||
|
|
46afe5a792 | ||
|
|
99ab17375d | ||
|
|
6d36221995 | ||
|
|
2dadbe3855 | ||
|
|
a11e7affc8 | ||
|
|
fbed1b901c | ||
|
|
75d44d8c07 | ||
|
|
491347fba6 | ||
|
|
b2a44d9327 | ||
|
|
3e59eb2be9 | ||
|
|
32f67e7664 | ||
|
|
010213e4ca | ||
|
|
6afa7b45ef | ||
|
|
6e1032c30d | ||
|
|
70c3e3e95f | ||
|
|
c290f39e3b | ||
|
|
b0fe9422e4 | ||
|
|
2f695ba37d | ||
|
|
72e5f9d395 | ||
|
|
1ba3c62c8b | ||
|
|
e56b9397d9 | ||
|
|
4aacd42826 | ||
|
|
ac848809b5 | ||
|
|
3f585ac923 | ||
|
|
f7972bc8be | ||
|
|
cd8ba5af5b | ||
|
|
fc787ac20f | ||
|
|
72cafaaabf | ||
|
|
968eb65b01 | ||
|
|
c872775134 | ||
|
|
55ec6edbfb | ||
|
|
7a06046d74 | ||
|
|
9761587fc6 | ||
|
|
65b33edeee | ||
|
|
62b4710d9e | ||
|
|
e60d220d5c | ||
|
|
e8d32e9779 | ||
|
|
32505ff927 | ||
|
|
5bda30d1bb | ||
|
|
40bc834210 | ||
|
|
24f458a004 | ||
|
|
aa405f4114 | ||
|
|
13e0c93f0c | ||
|
|
9ec1245550 | ||
|
|
aa1c8bdee5 | ||
|
|
0934056575 | ||
|
|
f59a6aceea | ||
|
|
28dabfb7a6 | ||
|
|
bd5f18bdf7 | ||
|
|
95c6f3e8a0 | ||
|
|
1f2cc89995 | ||
|
|
d20b3d0ed5 | ||
|
|
94e8d2ec62 | ||
|
|
d5bb4753c8 | ||
|
|
8ab1c72867 | ||
|
|
bfb188eff5 | ||
|
|
cbb59ee1b0 | ||
|
|
b02ce8bdc7 | ||
|
|
4d98201217 | ||
|
|
189fe6e665 | ||
|
|
20a35aa472 | ||
|
|
889eb2234e | ||
|
|
b4a6c9fe75 | ||
|
|
b1e3eaacaf | ||
|
|
2457ddb3ba | ||
|
|
e225eee248 | ||
|
|
1c65d69485 | ||
|
|
1eb9a119af | ||
|
|
7651ed0925 | ||
|
|
901af0e106 | ||
|
|
b485be88da | ||
|
|
7c728e6b9e | ||
|
|
049eaa886a | ||
|
|
a2f21f3e8c | ||
|
|
4ac705885e | ||
|
|
5f003af4d4 | ||
|
|
6ce26891e8 | ||
|
|
3d9aed8039 | ||
|
|
c298c075f4 | ||
|
|
84c5c7da97 | ||
|
|
17d5386bb3 | ||
|
|
5fdef05cb0 | ||
|
|
ce4fbe580d | ||
|
|
9f8be37c4e | ||
|
|
bf26b9a7e1 | ||
|
|
c23ec177d5 | ||
|
|
1a283a6c42 | ||
|
|
ca64fae35d | ||
|
|
485cba185b | ||
|
|
43eddf7a58 | ||
|
|
5896ff7e80 | ||
|
|
0767e6f1e2 | ||
|
|
4f2153fd14 | ||
|
|
8edac7234d | ||
|
|
b767129303 | ||
|
|
6d57013b3e | ||
|
|
f137ee87f7 | ||
|
|
fa55a5a826 | ||
|
|
0be182e1ba | ||
|
|
c3757b1f05 | ||
|
|
21af3e8c4e | ||
|
|
4df567fe9d | ||
|
|
1c662bee50 | ||
|
|
e7f085d84b | ||
|
|
fc12da950c | ||
|
|
1f27563128 | ||
|
|
e2782d9e1d | ||
|
|
3782f21222 | ||
|
|
bc24daedc3 | ||
|
|
41c1ea1b05 | ||
|
|
415df9168f | ||
|
|
e98926be3f | ||
|
|
488f26359a | ||
|
|
e5cc26627a | ||
|
|
619d34b7f8 | ||
|
|
58fa31451a | ||
|
|
4942844edb | ||
|
|
f4d7971b7f | ||
|
|
ab9ceb9526 | ||
|
|
9e07fed96e | ||
|
|
0ea4d57d56 | ||
|
|
77005be687 | ||
|
|
aef886e34c | ||
|
|
b21f1582dd | ||
|
|
f8f72bd52e | ||
|
|
7cd06f5088 | ||
|
|
db7baa737f | ||
|
|
bb83f93954 | ||
|
|
008b424ee9 | ||
|
|
720d3804fc | ||
|
|
9d61de0ec9 | ||
|
|
16f3c4b7fb | ||
|
|
65c28b0cc6 | ||
|
|
c0edbc5eee | ||
|
|
a170be820e | ||
|
|
652147def5 | ||
|
|
343a1f081c | ||
|
|
c82c3a41b4 | ||
|
|
e2ee8d0edb | ||
|
|
d702e37902 | ||
|
|
e0d22f195b | ||
|
|
88004a6208 | ||
|
|
a2a30ca7d3 | ||
|
|
d7264e744d | ||
|
|
7f04983ed3 | ||
|
|
ac99c5ab03 | ||
|
|
60097c2661 | ||
|
|
72f98037f4 | ||
|
|
6465017e05 | ||
|
|
f75ae95c8f | ||
|
|
26ff74d670 | ||
|
|
b34666a014 | ||
|
|
d8bbff45c1 | ||
|
|
39a8fc274a | ||
|
|
b6006ed2fc | ||
|
|
4ceecd3e5e | ||
|
|
ab74b63ff2 | ||
|
|
3214d963ec | ||
|
|
6bacb29c98 | ||
|
|
339427de12 | ||
|
|
f1dd5c2406 | ||
|
|
bb4ea41589 | ||
|
|
c5a669caa6 | ||
|
|
cee27dd710 | ||
|
|
879fb489f3 | ||
|
|
1ab01b470b | ||
|
|
e25d006476 | ||
|
|
2732fbadbe | ||
|
|
418cada107 | ||
|
|
850a158531 | ||
|
|
4282e55dfe | ||
|
|
05a0c36072 | ||
|
|
05ae3f22ab | ||
|
|
903275e887 | ||
|
|
88b48b5376 | ||
|
|
88e0b419f2 | ||
|
|
33d7423950 | ||
|
|
30c26df348 | ||
|
|
cadd668aac | ||
|
|
b2c85181d0 | ||
|
|
7da8651511 | ||
|
|
22aab1e328 | ||
|
|
919f53ee51 | ||
|
|
3b2cf9ddef | ||
|
|
3f11a2a6a8 | ||
|
|
2725d3534f | ||
|
|
48c975a333 | ||
|
|
fe042a90b9 | ||
|
|
fab70dea69 | ||
|
|
7b1548e798 | ||
|
|
e084903eab | ||
|
|
3f71921c58 | ||
|
|
806f9145de | ||
|
|
bd3cb846c0 | ||
|
|
9356017daa | ||
|
|
351a686a7c | ||
|
|
61c05dfc9f | ||
|
|
553fb5a3be | ||
|
|
35f457c92e | ||
|
|
b855ab0dd4 | ||
|
|
238aa7baee | ||
|
|
46174f8ac8 | ||
|
|
379040771d | ||
|
|
37a02a3984 | ||
|
|
575b38ee2f | ||
|
|
977ec5eb4a | ||
|
|
064cab8ac8 | ||
|
|
d5fe19eb92 | ||
|
|
c2eb068c8a | ||
|
|
efc550eea3 | ||
|
|
3f54dd40b6 | ||
|
|
7c0dd1251c | ||
|
|
0d8beb77f6 | ||
|
|
1cab24458b | ||
|
|
cfc97c7d71 | ||
|
|
30f1001553 | ||
|
|
92d3c2a08e | ||
|
|
9cfcbd137b | ||
|
|
b74daafbcd | ||
|
|
af01cf787d | ||
|
|
6da25bdae8 | ||
|
|
6ffa3e1780 | ||
|
|
ff35f925b7 | ||
|
|
6b0aaabc98 | ||
|
|
e60da236ae | ||
|
|
d58f597885 | ||
|
|
a25742e18f | ||
|
|
b75c57e521 | ||
|
|
77a22a2835 | ||
|
|
0690aff6b5 | ||
|
|
f877a76a0e | ||
|
|
605563c0a8 | ||
|
|
b2a7d2ed4e | ||
|
|
b2bd6e465c | ||
|
|
ceb065f9eb | ||
|
|
c2302046dd | ||
|
|
bd6bd53646 | ||
|
|
c95bd4ad87 | ||
|
|
1167e85cf3 | ||
|
|
77225b912f | ||
|
|
aa3a1426e8 | ||
|
|
0072a36646 | ||
|
|
cecfd0ace4 | ||
|
|
d7409a9797 | ||
|
|
1560aabbaf | ||
|
|
6ff7c1cedf | ||
|
|
6c7394101b | ||
|
|
c4845a8b65 | ||
|
|
728ca44dff | ||
|
|
1af7f512bc | ||
|
|
07ff7f16c7 | ||
|
|
bfcbf4bc19 | ||
|
|
69322ae43b | ||
|
|
2dea730e08 | ||
|
|
84cc58d013 | ||
|
|
165a1d62c8 | ||
|
|
d5fba05f61 | ||
|
|
9868377fa0 | ||
|
|
c25ed56914 | ||
|
|
a6aef8844f | ||
|
|
7d96d95a5e | ||
|
|
79ff9f2fa3 | ||
|
|
79f338488e | ||
|
|
7c70a8f8c2 | ||
|
|
1e76a63719 | ||
|
|
29c92b6d91 | ||
|
|
7ec8b0bcba | ||
|
|
370eecd336 | ||
|
|
f89eae47f2 | ||
|
|
3d598476ec | ||
|
|
b7d673db52 | ||
|
|
e3d9b17e53 | ||
|
|
dfba9a0ab0 | ||
|
|
47e16d8ad6 | ||
|
|
f3618527a6 | ||
|
|
ad2fa621bd | ||
|
|
f2565109ea | ||
|
|
b1a7a8d572 | ||
|
|
519c152527 | ||
|
|
2e783c4dac | ||
|
|
e95fbd1f2c | ||
|
|
fa40ecfec1 | ||
|
|
be27697628 | ||
|
|
86842904be | ||
|
|
2556aa7b2a | ||
|
|
9f7f4f5bb8 | ||
|
|
85f4e2b191 | ||
|
|
e945608fa4 | ||
|
|
d892bf5333 | ||
|
|
d3b271d04f | ||
|
|
498c4ce19d | ||
|
|
6f53bb90e4 | ||
|
|
e57d86daef | ||
|
|
b050f6e430 | ||
|
|
8caea61bd3 | ||
|
|
8b2dc6853a | ||
|
|
02a1624d22 | ||
|
|
c09cdb4a07 | ||
|
|
2e870b76c6 | ||
|
|
687e73c7af | ||
|
|
71be643056 | ||
|
|
e975382a82 | ||
|
|
35a8ad18a9 | ||
|
|
349a98d388 | ||
|
|
c65fd57a24 | ||
|
|
b459ec5cdb | ||
|
|
e187fad2d1 | ||
|
|
8182575647 | ||
|
|
f9938a3e9a | ||
|
|
ca50da933e | ||
|
|
f43b7faec5 | ||
|
|
ba533a91c4 | ||
|
|
ae171ce2d2 | ||
|
|
97662dc30e | ||
|
|
fc8b10cf71 | ||
|
|
a6901dc7ba | ||
|
|
7297a2b02e | ||
|
|
a4d484b478 | ||
|
|
d3399f8f25 | ||
|
|
5b1dd1818c | ||
|
|
04e9bdd516 | ||
|
|
f5c49771df | ||
|
|
7759a36327 | ||
|
|
fb51a889f4 | ||
|
|
facd6c20c8 | ||
|
|
5e0da82b7f | ||
|
|
9dbbc057c5 | ||
|
|
886184c38e | ||
|
|
3da82597bb | ||
|
|
c2de8f4282 | ||
|
|
0ea41bf2b1 | ||
|
|
7e3fa7bd59 | ||
|
|
cf9cec3562 | ||
|
|
e680c28694 | ||
|
|
8db0c60f58 | ||
|
|
fba6b0da53 | ||
|
|
916627208c | ||
|
|
8da6929e93 | ||
|
|
385db5abbd | ||
|
|
fd4d2df3e6 | ||
|
|
7076a84b83 | ||
|
|
957fcfac4b | ||
|
|
77ec263329 | ||
|
|
d496c5f4a5 | ||
|
|
372fe3128c | ||
|
|
ff8670e601 | ||
|
|
451deb0101 | ||
|
|
b278b99605 | ||
|
|
1d5ca2f45e | ||
|
|
fc0799f0ca | ||
|
|
3a43c4124f | ||
|
|
d197a131db | ||
|
|
7be9dcd263 | ||
|
|
117395ed23 | ||
|
|
7d40544703 | ||
|
|
064e743014 | ||
|
|
701da1fa4d | ||
|
|
224e070c74 | ||
|
|
c1dc317791 | ||
|
|
add133a4c6 | ||
|
|
383d813dd9 | ||
|
|
9a53d1b4fe | ||
|
|
2fe43e8af8 | ||
|
|
f55e1330d5 | ||
|
|
9e09a7c02b | ||
|
|
07b9f0c1d5 | ||
|
|
61fc0ba6b2 | ||
|
|
10bb058051 | ||
|
|
7ba06d0145 | ||
|
|
1b48b07ee4 | ||
|
|
e941298e55 | ||
|
|
be2763d13d | ||
|
|
ef440f1b4e | ||
|
|
d990e2881b | ||
|
|
0c4cf5aff2 | ||
|
|
38b3ef790b | ||
|
|
fd7bb0b3da | ||
|
|
2298aaef75 | ||
|
|
123a5c20d8 | ||
|
|
d60fc0981b | ||
|
|
70491a7ea0 | ||
|
|
0b49f0bea0 | ||
|
|
33108da1d0 | ||
|
|
1674a79e11 | ||
|
|
6f581e803c | ||
|
|
9c7d125108 | ||
|
|
5fc1090dbe | ||
|
|
2057041621 | ||
|
|
3cadadee34 | ||
|
|
660d1fe292 | ||
|
|
d3cc1a3186 | ||
|
|
274237f4d2 | ||
|
|
602241f936 | ||
|
|
7880b84ba7 | ||
|
|
e9c4ca1b61 | ||
|
|
c0bc7b6c80 | ||
|
|
0934f19c69 | ||
|
|
41441e017a | ||
|
|
1277a79544 | ||
|
|
ce527f42cd | ||
|
|
edb801394b | ||
|
|
c40e1cbbfc | ||
|
|
faff0dbd45 | ||
|
|
dff2f35098 | ||
|
|
261429dc52 | ||
|
|
2db6b7e8f1 | ||
|
|
9aa1cce146 | ||
|
|
8c766b9670 | ||
|
|
0777e6062c | ||
|
|
8d4a2eabb8 | ||
|
|
2a836845c8 | ||
|
|
5c4f19b7c5 | ||
|
|
63a8f46dda | ||
|
|
3d972fcc0e | ||
|
|
d69e7b6d04 | ||
|
|
f0623f78eb | ||
|
|
2891206718 | ||
|
|
c4ab6c2cad | ||
|
|
56b4205f38 | ||
|
|
35b40bdb2a | ||
|
|
63289837ae | ||
|
|
439596bce5 | ||
|
|
f725d7b180 | ||
|
|
933ef3298a | ||
|
|
16b3e1e406 | ||
|
|
d560e58711 | ||
|
|
29a8e606f3 | ||
|
|
b4f086b52a | ||
|
|
cf33623715 | ||
|
|
894e2f15f0 | ||
|
|
e7175cbecf | ||
|
|
241945e11f | ||
|
|
1aecd0f1ff | ||
|
|
9cb84b6351 | ||
|
|
cc68ee790e | ||
|
|
e786476701 | ||
|
|
a48ac52a7d | ||
|
|
9e33cdb499 | ||
|
|
5de9ca91cb | ||
|
|
f2d8bb4c38 | ||
|
|
bd719279db | ||
|
|
4f16113988 | ||
|
|
fb79cfb853 | ||
|
|
1a0e3b62e2 | ||
|
|
af30033599 | ||
|
|
b6c6a8db3a | ||
|
|
07b70c743c | ||
|
|
ca7ad2ff2c | ||
|
|
79e4f5a47f | ||
|
|
2be22abf64 | ||
|
|
2fafe59ed2 | ||
|
|
3687e5e953 | ||
|
|
4c1c759343 | ||
|
|
ef32b131ce | ||
|
|
792645aa6f | ||
|
|
8055bab946 | ||
|
|
19928d2509 | ||
|
|
c0f72d9fac | ||
|
|
77b6cdb7dd | ||
|
|
f71e66e50d | ||
|
|
71461f74b2 | ||
|
|
dfbeb6b786 | ||
|
|
3e1affd647 | ||
|
|
1ba9226cb5 | ||
|
|
7f2c03ed0e | ||
|
|
251b1ad96b | ||
|
|
c8e7bc0542 | ||
|
|
ab3957bda7 | ||
|
|
5320379dc0 | ||
|
|
f6b36353a6 | ||
|
|
e5523b4954 | ||
|
|
de9f401877 | ||
|
|
46fd530566 | ||
|
|
b6b4369972 | ||
|
|
3aeaad418f | ||
|
|
b2bedbf40e | ||
|
|
62ef1e2857 | ||
|
|
0d03073c89 | ||
|
|
1ebbe4d551 | ||
|
|
1d14341231 | ||
|
|
b4c03fb0a9 | ||
|
|
9eeb62c4a3 | ||
|
|
116f2fa00a | ||
|
|
d6fbae0c27 | ||
|
|
6c37499531 | ||
|
|
7a92fe4c4c | ||
|
|
986b654098 | ||
|
|
ef7c1af78d | ||
|
|
2a8c1bb255 | ||
|
|
ef2d599f45 | ||
|
|
627c9515b1 | ||
|
|
fc846109ba | ||
|
|
5775569f18 | ||
|
|
55b41157cf | ||
|
|
5ba98ed5d3 | ||
|
|
69e0f3bf48 | ||
|
|
97422095ed | ||
|
|
40acbc1ea5 | ||
|
|
94a9447396 | ||
|
|
8229beefa4 | ||
|
|
6a62b9d5b7 | ||
|
|
bf6c5ff7c1 | ||
|
|
e6177356ec | ||
|
|
53b384c01d | ||
|
|
b66f3b08bb | ||
|
|
92e30ad3df | ||
|
|
17e89935c4 | ||
|
|
04ced9d63d | ||
|
|
555173a263 | ||
|
|
54391bb2ca | ||
|
|
ea0f710586 | ||
|
|
5a2899b78e | ||
|
|
f26cc7bcd4 | ||
|
|
08bc2cde18 | ||
|
|
a5d361d9c4 | ||
|
|
96d4171df7 | ||
|
|
fd2aaa768a | ||
|
|
24f73838f2 | ||
|
|
2b97f7ce7b | ||
|
|
e7e577e05d | ||
|
|
52bdfd3dca | ||
|
|
0e29833fc7 | ||
|
|
92c07fbccc | ||
|
|
bc3d6e90fa | ||
|
|
056e268cb3 | ||
|
|
50eb9f576a | ||
|
|
0db5048d6a | ||
|
|
eed604dce5 | ||
|
|
97b55a966d | ||
|
|
8d5a034c9d | ||
|
|
de6e5e315d | ||
|
|
8a44b6f251 | ||
|
|
e6770d6361 | ||
|
|
e5d8e11306 | ||
|
|
821b603ec2 | ||
|
|
34363d77db | ||
|
|
7a8260d5e0 | ||
|
|
1f1d49bbd6 | ||
|
|
0e82616ea6 | ||
|
|
9a68a887f0 | ||
|
|
f2b405924d | ||
|
|
eee7417f1f | ||
|
|
db48c076a6 | ||
|
|
5a15aee0e0 | ||
|
|
d67afcc9c1 | ||
|
|
b09f475602 | ||
|
|
c4e6c0aa83 | ||
|
|
e459214613 | ||
|
|
3dbe3deb64 | ||
|
|
701c81c7d1 | ||
|
|
557fd9b7a3 | ||
|
|
ae3de7f0c0 | ||
|
|
43b0c8adea | ||
|
|
c70f036024 | ||
|
|
d74a72d580 | ||
|
|
40d758b019 | ||
|
|
b390e0ebf1 | ||
|
|
ab2ea18cb5 | ||
|
|
ea33b2824e | ||
|
|
140e562446 | ||
|
|
9209328fd3 | ||
|
|
35938e4d90 | ||
|
|
316d124ec4 | ||
|
|
b1f59b4703 | ||
|
|
08ce3d0ed5 | ||
|
|
e39472c606 | ||
|
|
3924c1eabf | ||
|
|
929ab8b529 | ||
|
|
da55120b84 | ||
|
|
b1c0e42d00 | ||
|
|
b694edc23d | ||
|
|
0fe951a702 | ||
|
|
4cf62ff62c | ||
|
|
c6647fc0bf | ||
|
|
50b17c0f7d | ||
|
|
a0853a17ed | ||
|
|
35888b62f4 | ||
|
|
6b74250915 | ||
|
|
1269ac0661 | ||
|
|
a2f0a9c380 | ||
|
|
434926a39e | ||
|
|
4ccbb1b867 | ||
|
|
02af1ac144 | ||
|
|
1b747da374 | ||
|
|
f82e06d4f8 | ||
|
|
7812b45b36 | ||
|
|
09c034c096 | ||
|
|
7473ff4698 | ||
|
|
03468f3079 | ||
|
|
138a1157ee | ||
|
|
a63c981d70 | ||
|
|
9888224208 | ||
|
|
33ba2503c6 | ||
|
|
a9eea29b84 | ||
|
|
c21de1dbe5 | ||
|
|
6b8d3f6b01 | ||
|
|
e2ff71d2dd | ||
|
|
36097f68a0 | ||
|
|
20088e34b5 | ||
|
|
ad24ef01de | ||
|
|
304a39c793 | ||
|
|
338ad09a44 | ||
|
|
015712b9f1 | ||
|
|
11cb016d39 | ||
|
|
327e5834d5 | ||
|
|
c984c80a7d | ||
|
|
fe43729707 | ||
|
|
54cee9cd1f | ||
|
|
ad98994e4a | ||
|
|
87c57062c4 | ||
|
|
180e604534 | ||
|
|
47f2fb1832 | ||
|
|
96d9102630 | ||
|
|
f6f08969d1 | ||
|
|
676b4c0362 | ||
|
|
a789f6bb85 | ||
|
|
1e71ec7613 | ||
|
|
b3af6c9da5 | ||
|
|
0ce220d77a | ||
|
|
dc1f25d6fb | ||
|
|
e8c057e33f | ||
|
|
80c568bb30 | ||
|
|
e6b637cd72 | ||
|
|
10228f3bb8 | ||
|
|
e783c0b5a1 | ||
|
|
626f3de608 | ||
|
|
4cc45a7ba9 | ||
|
|
1c7f16c742 | ||
|
|
60211ee3b3 | ||
|
|
68accfe5c1 | ||
|
|
3f824c7e1e | ||
|
|
ab037ed242 | ||
|
|
4aec010451 | ||
|
|
9f97891939 | ||
|
|
9c9b10f047 | ||
|
|
5f4e664e8b | ||
|
|
220a5cb89f | ||
|
|
2cf200c493 | ||
|
|
d042cecbd9 | ||
|
|
cfc8c7a95e | ||
|
|
6c7e5d9c18 | ||
|
|
3fdf998703 | ||
|
|
babbbb048b | ||
|
|
36c9f3116e | ||
|
|
451f0b2d07 | ||
|
|
da10d61faa | ||
|
|
b4aeccba6d | ||
|
|
c60c1258e2 | ||
|
|
cef32b1e2f | ||
|
|
06d67f822b | ||
|
|
97da8ca6bb | ||
|
|
11a765e77d | ||
|
|
52dbb39ecd | ||
|
|
92b1fecc92 | ||
|
|
18c269209d | ||
|
|
808fc0a0bf | ||
|
|
5e852417dd | ||
|
|
677375c0d1 | ||
|
|
33a47baa0f | ||
|
|
a788378ce2 | ||
|
|
d3728b5fff | ||
|
|
79dc4f7a0c | ||
|
|
a32672c1c5 | ||
|
|
a384966f76 | ||
|
|
fd5d1094d3 | ||
|
|
a4ff44794c | ||
|
|
e2d057bd2c | ||
|
|
90eb73bb9d | ||
|
|
d6245c9e69 | ||
|
|
e99d47a3aa | ||
|
|
89e4c87e57 | ||
|
|
8f50a67b87 | ||
|
|
269a3ad5ad | ||
|
|
533c499b44 | ||
|
|
39f801b957 | ||
|
|
17d28abb62 | ||
|
|
9fbee0b347 | ||
|
|
e83404fea2 | ||
|
|
1a65bf61a8 | ||
|
|
6443fb2581 | ||
|
|
2112f46885 | ||
|
|
074aa05880 | ||
|
|
9afa0f3249 | ||
|
|
3b8f0741cb | ||
|
|
4f75f3bef1 | ||
|
|
28f4501f0a | ||
|
|
47acdced4c | ||
|
|
b2cf9fe953 | ||
|
|
1505f6af03 | ||
|
|
35659b625f | ||
|
|
5482637876 | ||
|
|
24e91108ba | ||
|
|
b130f77b94 | ||
|
|
84ebb3ae39 | ||
|
|
aa9d7d766e | ||
|
|
0718a54934 | ||
|
|
b0884491ae | ||
|
|
2da81fefb8 | ||
|
|
651d262d43 | ||
|
|
22a9c4d448 | ||
|
|
b44ea85296 | ||
|
|
951e64a4bc | ||
|
|
19081305e1 | ||
|
|
f189957991 | ||
|
|
fb7f9eb420 | ||
|
|
9085f883ad | ||
|
|
fe95410380 | ||
|
|
7ccfa69750 | ||
|
|
0b0a331e63 | ||
|
|
5a28c6dd94 | ||
|
|
8506ee1bfe | ||
|
|
7cd254b070 | ||
|
|
931f3abe4e | ||
|
|
873f321cf7 | ||
|
|
24a42bb761 | ||
|
|
4168763049 | ||
|
|
84707a7504 | ||
|
|
881414e0af | ||
|
|
d1cbbf62c9 | ||
|
|
59b59d2651 | ||
|
|
1447af9522 | ||
|
|
376c94c239 | ||
|
|
b617f54d34 | ||
|
|
4e38d42183 | ||
|
|
5966ec08a9 | ||
|
|
f7f36b4f37 | ||
|
|
05e3f11ac5 | ||
|
|
be18fcec6b | ||
|
|
0bf1fb6f19 | ||
|
|
7bef1c1f2a | ||
|
|
77763cee25 | ||
|
|
01d848075a | ||
|
|
f9f0c83b30 | ||
|
|
90952aae2d | ||
|
|
fab2534381 | ||
|
|
ea8eefdf72 | ||
|
|
ae7fadf900 | ||
|
|
c97e3bac2a | ||
|
|
63130ca782 | ||
|
|
b653dfe7ba | ||
|
|
33d844496f | ||
|
|
39267c2bf9 | ||
|
|
5430f7efa9 | ||
|
|
f01b062a06 | ||
|
|
db81c3d979 | ||
|
|
092b805de5 | ||
|
|
2ab7673bb0 | ||
|
|
ee11982bcb | ||
|
|
e0c3093711 | ||
|
|
7de28bdc6a | ||
|
|
c5ec799b2d | ||
|
|
3ae99689f7 | ||
|
|
210ce6796f | ||
|
|
9a9b55e60b | ||
|
|
2dc7873362 | ||
|
|
1ebb0b0785 | ||
|
|
01fa930e6b | ||
|
|
28ce738ce7 | ||
|
|
c49dfb1007 | ||
|
|
96559baede | ||
|
|
858c75805f | ||
|
|
f5b3d65f07 | ||
|
|
b5c6ea479d | ||
|
|
9990a0a301 | ||
|
|
43eda262be | ||
|
|
9bc15253ad | ||
|
|
5303587494 | ||
|
|
33bed67b99 | ||
|
|
3d3416d10e | ||
|
|
02c184dce8 | ||
|
|
89f2c54773 | ||
|
|
36e9a1582f | ||
|
|
bd955dcb81 | ||
|
|
653717b72c | ||
|
|
67ebb942b6 | ||
|
|
d9cf9e37fb | ||
|
|
976f0d8303 | ||
|
|
7b514da372 | ||
|
|
a0a3b47001 | ||
|
|
97dd56a974 | ||
|
|
14fc7fa96c | ||
|
|
1a7e7165a7 | ||
|
|
bdcd417ad6 | ||
|
|
b3171064fd | ||
|
|
31fe8c5c16 | ||
|
|
1c0ff3c97e | ||
|
|
2e48996c64 | ||
|
|
0ae1d743e6 | ||
|
|
befce57664 | ||
|
|
db082e4215 | ||
|
|
a7290240a2 | ||
|
|
6fee33722d | ||
|
|
cb87994fcd | ||
|
|
961b1151c0 | ||
|
|
a335bb813d | ||
|
|
0840b0ccf0 | ||
|
|
237bf7a69c | ||
|
|
022d058ce1 | ||
|
|
5aaa0bcf64 | ||
|
|
f41f376213 | ||
|
|
cbd712e8c9 | ||
|
|
b831413ba7 | ||
|
|
2127840893 | ||
|
|
2e34a6a9a6 | ||
|
|
f851db2531 | ||
|
|
5d900b5171 | ||
|
|
25fcdb4304 | ||
|
|
b92cc3d806 | ||
|
|
09ddabb35e | ||
|
|
4cb2b8e1fe | ||
|
|
8eb3233f82 | ||
|
|
8b4ff89345 | ||
|
|
abd2b78275 | ||
|
|
67631ea57c | ||
|
|
12ce650f03 | ||
|
|
549625a4c7 | ||
|
|
5ce5b396f7 | ||
|
|
bddbce404f | ||
|
|
4557989eff | ||
|
|
0f4b4c82de | ||
|
|
a9a7057448 | ||
|
|
5defe2dd7c | ||
|
|
1a6d970f7e | ||
|
|
75144252c0 | ||
|
|
cedd7ef4bf | ||
|
|
9efa05b7c7 | ||
|
|
c00b313bee | ||
|
|
8725a3147d | ||
|
|
d66fa199b4 | ||
|
|
b3251de43f | ||
|
|
2cab62fdc4 | ||
|
|
596b08b9a1 | ||
|
|
52c6a66274 | ||
|
|
ebfb3cb678 | ||
|
|
60434f91bd | ||
|
|
396e830e72 | ||
|
|
331f905e8a | ||
|
|
3987509ac3 | ||
|
|
818412a4a9 | ||
|
|
45a703d3f1 | ||
|
|
55a52eb920 | ||
|
|
e53ca2b5dd | ||
|
|
86ce37ce21 | ||
|
|
68eef6b9f4 | ||
|
|
dd866fdd82 | ||
|
|
f53160138e | ||
|
|
9719a22ff8 | ||
|
|
6a966b79d7 | ||
|
|
8dfb69ebca | ||
|
|
ae30c7f4ab | ||
|
|
eeb43eb1eb | ||
|
|
c2660ef64a | ||
|
|
41278da02f | ||
|
|
d76c684cef | ||
|
|
cf43cddba9 | ||
|
|
ac88c9cabd | ||
|
|
444959cd81 | ||
|
|
0ee4b1dd48 | ||
|
|
8053881211 | ||
|
|
0c376684c7 | ||
|
|
bab2866e21 | ||
|
|
f026645177 | ||
|
|
d36a62dd0e | ||
|
|
a9930145fe | ||
|
|
98e4c9aef4 | ||
|
|
eaeff2e939 | ||
|
|
67391df6f0 | ||
|
|
b484bc253a | ||
|
|
54c83ce7a3 | ||
|
|
37142b284f | ||
|
|
217a213a5d | ||
|
|
9233c937ae | ||
|
|
c4690101a3 | ||
|
|
129d6e940f | ||
|
|
c8c6b2141e | ||
|
|
97a0b51739 | ||
|
|
ee135e463c | ||
|
|
a5c040170c | ||
|
|
8e2ddfb9df | ||
|
|
2c84b8acb8 | ||
|
|
1fdb920299 | ||
|
|
c1a6b4530b | ||
|
|
daacfa367b | ||
|
|
73d041e231 | ||
|
|
5faf455502 | ||
|
|
35fb4f2c20 | ||
|
|
6c3f316db8 | ||
|
|
3837327f43 | ||
|
|
d568d3877a | ||
|
|
99515d905c | ||
|
|
e06424afc7 | ||
|
|
1a5e210004 | ||
|
|
e1818aae0a | ||
|
|
01aef58899 | ||
|
|
670d72a64b | ||
|
|
0a837f8064 | ||
|
|
8307e2c329 | ||
|
|
5c48a21bcc | ||
|
|
39d03d8ab6 | ||
|
|
e674b5c6a4 | ||
|
|
395123dcc8 | ||
|
|
b484523d7f | ||
|
|
22e9844842 | ||
|
|
6dfca30ec9 | ||
|
|
fd0b71760e | ||
|
|
862edc6aae | ||
|
|
fcffe5b582 | ||
|
|
32131681f7 | ||
|
|
2cd08683c8 | ||
|
|
0e47b9242d | ||
|
|
4066bd0a17 | ||
|
|
bbf39825e1 | ||
|
|
7017cc588c | ||
|
|
057d36b789 | ||
|
|
b811d30a74 | ||
|
|
8530516f40 | ||
|
|
987d9aff6c | ||
|
|
1a241fc6f6 | ||
|
|
a0a0ff10a4 | ||
|
|
ecf62dc44e | ||
|
|
cfeebdf8c5 | ||
|
|
cd1def8074 | ||
|
|
99af37d2c8 | ||
|
|
10f2defb04 | ||
|
|
d80e0fc48c | ||
|
|
a159c212c4 | ||
|
|
3b2f0b8ac4 | ||
|
|
6c0ee68f07 | ||
|
|
46756f8caa | ||
|
|
38beab8a1e | ||
|
|
c53c056477 | ||
|
|
6db735215a | ||
|
|
52c52c1c3d | ||
|
|
7d4a198992 | ||
|
|
794994bfb5 | ||
|
|
1df318632d | ||
|
|
b8af95533a | ||
|
|
f695e50683 | ||
|
|
4b3a23efa9 | ||
|
|
ad07d32fc7 | ||
|
|
48ef3a2f55 | ||
|
|
eafad14638 | ||
|
|
6503178113 | ||
|
|
a678dd0832 | ||
|
|
f601dff0c2 | ||
|
|
9acdb6b6c8 | ||
|
|
e29c2b0872 | ||
|
|
96d9074817 | ||
|
|
c959028440 | ||
|
|
8902f7fc3f | ||
|
|
b0fdf62d3c | ||
|
|
c03591bbc0 | ||
|
|
2b2187ea33 | ||
|
|
ee1f22f64e | ||
|
|
b790692180 | ||
|
|
62f0ea7954 | ||
|
|
648355a4cb | ||
|
|
cf6352e82f | ||
|
|
b70f5ce50c | ||
|
|
09d0f92e05 | ||
|
|
4e340d5e6c | ||
|
|
5696b0327f | ||
|
|
ea7f0f7314 | ||
|
|
97807d68e9 | ||
|
|
908f56d375 | ||
|
|
decda2cb0e | ||
|
|
83dbc17647 | ||
|
|
70369b3888 | ||
|
|
314d0c288f | ||
|
|
246300a60c | ||
|
|
98baae88df | ||
|
|
1e6865b38e | ||
|
|
42e19bdbd7 | ||
|
|
44049a7e62 | ||
|
|
cbab7fcfea | ||
|
|
727d97a95e | ||
|
|
ae6840dc31 | ||
|
|
eef36a86dc | ||
|
|
8eac6854f5 | ||
|
|
2645704e4d | ||
|
|
de8c0e5070 | ||
|
|
c52b97c89f | ||
|
|
f63177b075 | ||
|
|
d1ae16818e | ||
|
|
50e6fc68f4 | ||
|
|
ef2bc94ac4 | ||
|
|
7a80b64960 | ||
|
|
825c107f2b | ||
|
|
89cd013bd6 | ||
|
|
9d0951f2d7 | ||
|
|
8a5297e61c | ||
|
|
631112ec2f | ||
|
|
c0b58291d2 | ||
|
|
6d9c0036b7 | ||
|
|
f4a30e483c | ||
|
|
19e8346959 | ||
|
|
c3d353867a | ||
|
|
8062aa164a | ||
|
|
79577fadf9 | ||
|
|
458bcdc77e | ||
|
|
d99e16a9be | ||
|
|
2c1983f352 | ||
|
|
f183abfd6a | ||
|
|
c3a1a51f83 | ||
|
|
c4e23fff2b | ||
|
|
6454f5c3f2 | ||
|
|
08a657f8fa | ||
|
|
fb950ce0d5 | ||
|
|
034d61dbaa | ||
|
|
5edbe423b7 | ||
|
|
3220d2d769 | ||
|
|
2bc6223a5f | ||
|
|
63693db502 | ||
|
|
a2c87335ea | ||
|
|
87eaeb5363 | ||
|
|
c7ae114bdf | ||
|
|
968ed87454 | ||
|
|
886f9faaf3 | ||
|
|
f15b229e55 | ||
|
|
2878b23b14 | ||
|
|
d6302ef69d | ||
|
|
1823f4748c | ||
|
|
7c495e9250 | ||
|
|
fcc7633bd0 | ||
|
|
77d490c8fa | ||
|
|
3005a78fbf | ||
|
|
7be8abe541 | ||
|
|
427e27cc74 | ||
|
|
f007536147 | ||
|
|
cf0b1ab2e3 | ||
|
|
302dc219c1 | ||
|
|
7aef25bc38 | ||
|
|
12e61e2ac4 | ||
|
|
0371773312 | ||
|
|
fd913127ab | ||
|
|
bb56953b8d | ||
|
|
5762d24683 | ||
|
|
71a63bc126 | ||
|
|
582c2462ad | ||
|
|
fd55fc78f4 | ||
|
|
0fe880b867 | ||
|
|
95c2ba883a | ||
|
|
fb743a3e27 | ||
|
|
56fa94a6c0 | ||
|
|
7756f1b7f2 | ||
|
|
be525968af | ||
|
|
2e3222d165 | ||
|
|
973651ae3b | ||
|
|
071b885744 | ||
|
|
bedd024310 | ||
|
|
dd14eb51d4 | ||
|
|
caf1b545b8 | ||
|
|
bf0d23f985 | ||
|
|
1f433956b0 | ||
|
|
d949f9d912 | ||
|
|
8f7009f7f2 | ||
|
|
2e4f176a6d | ||
|
|
694f5ed4de | ||
|
|
b882dbf5b9 | ||
|
|
982458f908 | ||
|
|
48e938368e | ||
|
|
9a57fc8cab | ||
|
|
0117c206d6 | ||
|
|
0be78cd2b4 | ||
|
|
304409e520 | ||
|
|
545b4cff3b | ||
|
|
1719d0062c | ||
|
|
1dafae56b9 | ||
|
|
720d8fdddc | ||
|
|
2fa3048632 | ||
|
|
8b02b1eb7e | ||
|
|
c34c7433eb | ||
|
|
2eb11eae36 | ||
|
|
c629ac4600 | ||
|
|
a743a6dee6 | ||
|
|
460aba89f8 | ||
|
|
c465c5a3eb | ||
|
|
18144dffe9 | ||
|
|
f896c7eeae | ||
|
|
74348caba2 | ||
|
|
bd62bcf18b | ||
|
|
42c98ab6c8 | ||
|
|
0ec69ef808 | ||
|
|
59a1c7dcf5 | ||
|
|
c8e2b9ebfe | ||
|
|
aac21de8ae | ||
|
|
db59a7414e | ||
|
|
dd6c7bb240 | ||
|
|
e486cb60bc | ||
|
|
9500c0c776 | ||
|
|
68cde46c9f | ||
|
|
4c37bb0be8 | ||
|
|
3859a66d14 | ||
|
|
486af716be | ||
|
|
c0bffe6dcf | ||
|
|
b4b0bd3a69 | ||
|
|
ae8c6a816a | ||
|
|
e8713cc150 | ||
|
|
e533fe138b | ||
|
|
aa6e7433bc | ||
|
|
90bb834ed1 | ||
|
|
86f292bc00 | ||
|
|
f251532caa | ||
|
|
72a2ec5d85 | ||
|
|
9ba9ff7b17 | ||
|
|
856b482bab | ||
|
|
38cb520533 | ||
|
|
8e9b151720 | ||
|
|
d720b0c631 | ||
|
|
ee957ac447 | ||
|
|
b6972e5890 | ||
|
|
e25f73df9c | ||
|
|
e28bc16c5b | ||
|
|
f95c4cb8bb | ||
|
|
1ee0cac2d9 | ||
|
|
5c19a5499b | ||
|
|
fb9e0bb965 | ||
|
|
1a97d39a61 | ||
|
|
9e37e7adfb | ||
|
|
5c4dca7424 | ||
|
|
5e0efd3caa | ||
|
|
d346b4ba9b | ||
|
|
31071bdd6c | ||
|
|
12e8ae3adb | ||
|
|
49f3b54810 | ||
|
|
e2fdfb6c19 | ||
|
|
dcdaf1e9a0 | ||
|
|
7f5ff80c86 | ||
|
|
171aaf4e8d | ||
|
|
9cc234e979 | ||
|
|
500cf0a542 | ||
|
|
b724a873e9 | ||
|
|
c77c03b751 | ||
|
|
bbd9c931b0 | ||
|
|
7bfabbae52 | ||
|
|
c6db0221c4 | ||
|
|
e1a54c8d10 | ||
|
|
3cba4261fa | ||
|
|
39c03bc2c5 | ||
|
|
22e0811f2c | ||
|
|
d7a3529ead | ||
|
|
7241d18de1 | ||
|
|
bf5d11b44e | ||
|
|
9ee32440ad | ||
|
|
729d43f733 | ||
|
|
0c0482d59c | ||
|
|
00366c63fc | ||
|
|
d8d9e16711 | ||
|
|
a86c9bbd24 | ||
|
|
cb9a33bc14 | ||
|
|
9b0239178c | ||
|
|
1a3e5a816b | ||
|
|
ff21c392f3 | ||
|
|
99637508f9 | ||
|
|
c48e8e5116 | ||
|
|
9b9ec7ad1e | ||
|
|
d7f0682135 | ||
|
|
aa6810479e | ||
|
|
84e44e9759 | ||
|
|
e49440bb73 | ||
|
|
4f45925b23 | ||
|
|
be8da1111e | ||
|
|
2527cce052 | ||
|
|
18939dd676 | ||
|
|
1a645aa637 | ||
|
|
8b67ff4348 | ||
|
|
3a9322c32a | ||
|
|
c8ff4f2262 | ||
|
|
d9fe90785e | ||
|
|
a4fe7b11ee | ||
|
|
863a441fba | ||
|
|
edea55ecd7 | ||
|
|
bdd3fbf67a | ||
|
|
55c86cbdb9 | ||
|
|
4bfdbfb167 | ||
|
|
6ccaefd48d | ||
|
|
fdee9fe213 | ||
|
|
8e6f5fe353 | ||
|
|
aa00851aa4 | ||
|
|
2b85acd861 | ||
|
|
004746d842 | ||
|
|
216784bcc3 | ||
|
|
1cdedb63bd | ||
|
|
49f0382490 | ||
|
|
50f76f501c | ||
|
|
1525ff177f | ||
|
|
2ea7d06455 | ||
|
|
f5ea07ce61 | ||
|
|
ce99003ae1 | ||
|
|
0200c77d7e | ||
|
|
4033fe903d | ||
|
|
4849145b66 | ||
|
|
bfaf2a8f36 | ||
|
|
f8b07fbbac | ||
|
|
08abb7213c | ||
|
|
f31d157ce7 | ||
|
|
868602b5ab | ||
|
|
5d420d7bb7 | ||
|
|
50d2474660 | ||
|
|
92cc078907 | ||
|
|
fe93cf1b9a | ||
|
|
7333bc8f82 | ||
|
|
9f8701ac58 | ||
|
|
55c5c4b362 | ||
|
|
51f2ad15f4 | ||
|
|
f4dd99e8b8 | ||
|
|
485c71abf7 | ||
|
|
c8948bf677 | ||
|
|
77102efc79 | ||
|
|
e64002e9ef | ||
|
|
043a1f5b36 | ||
|
|
bb0637213f | ||
|
|
b3ac7b808d | ||
|
|
ae3616fba8 | ||
|
|
50c22695cd | ||
|
|
7a5badecbf | ||
|
|
21390b3bf6 | ||
|
|
95ee73b7bf | ||
|
|
086a4fda17 | ||
|
|
e131b99b2a | ||
|
|
7dab648426 | ||
|
|
cd2968d0db | ||
|
|
930347763b | ||
|
|
1548b1ebf4 | ||
|
|
7e8039ef0d | ||
|
|
d1c0cc7f47 | ||
|
|
d484c0ebf8 | ||
|
|
8ff4b67307 | ||
|
|
14aa0e7495 | ||
|
|
bf0c1962d9 | ||
|
|
724429c759 | ||
|
|
00d6a6d8c2 | ||
|
|
5d5755af7c | ||
|
|
f373bcafd3 | ||
|
|
91fb452012 | ||
|
|
6e84cdacd1 | ||
|
|
b5da4730a3 | ||
|
|
2726272b68 | ||
|
|
9b8fbc368c | ||
|
|
ac125fa07f | ||
|
|
1f4e9b8eb7 | ||
|
|
5e0a6b43fc | ||
|
|
640dc6721c | ||
|
|
086c418737 | ||
|
|
21a600c569 | ||
|
|
5555498304 | ||
|
|
dd426eb391 | ||
|
|
6ec674deb7 | ||
|
|
8e15876ed5 | ||
|
|
ec0b8b8639 | ||
|
|
e98163546d | ||
|
|
666d9dea2c | ||
|
|
c334a7fe0b | ||
|
|
1f0a9a2c0c | ||
|
|
42f35b8783 | ||
|
|
334da52d65 | ||
|
|
9daf234fef | ||
|
|
a6072a2b76 | ||
|
|
bb4a3f979b | ||
|
|
651808e3dd | ||
|
|
ecc0759032 | ||
|
|
e9a6358d8d | ||
|
|
80ba3f416f | ||
|
|
c4521dfb2f | ||
|
|
b7875715ce | ||
|
|
ff65578160 | ||
|
|
ce2edd18c7 | ||
|
|
f85ea33a98 | ||
|
|
9ff0a9f23e | ||
|
|
d9e4d36c48 | ||
|
|
15d4bfd607 | ||
|
|
b7cfe4b5a6 | ||
|
|
f461ad12fb | ||
|
|
db230015b8 | ||
|
|
1ce0aca43e | ||
|
|
1c0de7be96 | ||
|
|
ec127efd14 | ||
|
|
64e2082f39 | ||
|
|
86306178c5 | ||
|
|
a5274daf1f | ||
|
|
f8ff0d2cb4 | ||
|
|
5f0e06e89c | ||
|
|
e120dab4f2 | ||
|
|
1d71c7b86e | ||
|
|
88bbfc9975 | ||
|
|
9c617f52f6 | ||
|
|
5945ba1c6d | ||
|
|
c89afb6539 | ||
|
|
b544c99344 | ||
|
|
bb0a9b3208 | ||
|
|
718d337c64 | ||
|
|
25dc000e41 | ||
|
|
1f77ab10fc | ||
|
|
ceed7b9d77 | ||
|
|
7ebc888513 | ||
|
|
06b796783c | ||
|
|
cecc66d17b | ||
|
|
c479e904dd | ||
|
|
893c567e35 | ||
|
|
6aecc88543 | ||
|
|
7480c6ac91 | ||
|
|
b5930ec988 | ||
|
|
2f47425d71 | ||
|
|
a0b0182016 | ||
|
|
ea59c6262d | ||
|
|
4a8de5c704 | ||
|
|
8c86b7e323 | ||
|
|
c51569c3b6 | ||
|
|
aef81e78a0 | ||
|
|
ca552c2618 | ||
|
|
55b4052887 | ||
|
|
217d3e39c6 | ||
|
|
a6c9ed61a6 | ||
|
|
fdc6b229a6 | ||
|
|
0b4182d8ad | ||
|
|
afa7fa58d7 | ||
|
|
de93525d7d | ||
|
|
c2c3eaf5a7 | ||
|
|
768f515afc | ||
|
|
7ae1572b39 | ||
|
|
af3950d196 | ||
|
|
03777d2784 | ||
|
|
25e8d3215d | ||
|
|
ba7b405913 | ||
|
|
183f99038a | ||
|
|
388607dc2d | ||
|
|
273d7623a6 | ||
|
|
15703e7fb8 | ||
|
|
37aafafc7d | ||
|
|
c4db6427f4 | ||
|
|
03188dfd50 | ||
|
|
bac7bb82b0 | ||
|
|
d4a01a8524 | ||
|
|
2fdf127a6f | ||
|
|
9f2cd8d5f2 | ||
|
|
f7c7e4cadb | ||
|
|
ff9fc7aa3f | ||
|
|
688f6d1b9d | ||
|
|
7cd06114f1 | ||
|
|
6659396dc6 | ||
|
|
5dc55d66fc | ||
|
|
156ab40baa | ||
|
|
05afcba8e7 | ||
|
|
f38526321b | ||
|
|
288d19ae0a | ||
|
|
779cc0f8d4 | ||
|
|
0af96031de | ||
|
|
84dcdc880f | ||
|
|
57a32b2825 | ||
|
|
690439a295 | ||
|
|
d03df22d4c | ||
|
|
4730528a95 | ||
|
|
1ab395eed3 | ||
|
|
9ea0fff51d | ||
|
|
60963ffe6c | ||
|
|
22e1885d29 | ||
|
|
900584ec7f | ||
|
|
b1d3a4d6cd | ||
|
|
bdaed8f51a | ||
|
|
367c917d80 | ||
|
|
062a5863c0 | ||
|
|
0a2f05f09b | ||
|
|
16106bd1f7 | ||
|
|
2185951cbb | ||
|
|
06c9c4d205 | ||
|
|
8a3bd41416 | ||
|
|
3aced8a7d4 | ||
|
|
e21f147cb9 | ||
|
|
ff33d897d5 | ||
|
|
bb30c3ad73 | ||
|
|
9f34a5beca | ||
|
|
05ce493547 | ||
|
|
bfa3967c70 | ||
|
|
a9cf0f46fc | ||
|
|
cddddbe04c | ||
|
|
9ec2c33e9d | ||
|
|
4648e756a9 | ||
|
|
9dfd6c8779 | ||
|
|
95987aedb2 | ||
|
|
4f7a06cf66 | ||
|
|
8c92d6574c | ||
|
|
d1c5e9706f | ||
|
|
4fc121ad7f | ||
|
|
58c67323da | ||
|
|
f27049afb6 | ||
|
|
da7b2d970d | ||
|
|
a758078ce5 | ||
|
|
20c9225f64 | ||
|
|
2492aba147 | ||
|
|
cc44d7c3d6 | ||
|
|
c138b63720 | ||
|
|
e34d5dd3e8 | ||
|
|
52967f54b9 | ||
|
|
45a1a3037a | ||
|
|
f760f7b6b3 | ||
|
|
67b6b9781f | ||
|
|
5f142e88fb | ||
|
|
011ea824da | ||
|
|
94e6ceec58 | ||
|
|
d391faffe6 | ||
|
|
41ab6de3aa | ||
|
|
7559d17ec1 | ||
|
|
2cc9d8537f | ||
|
|
98c17e6cee | ||
|
|
9b8cdd7fe9 | ||
|
|
66736faf95 | ||
|
|
d63aa79f79 | ||
|
|
52e84a5f0b | ||
|
|
68679a9d0e | ||
|
|
81b97d6f8e | ||
|
|
f42ff6e563 | ||
|
|
3c0d44c580 | ||
|
|
c106213d5c | ||
|
|
e46f133a2b | ||
|
|
668d8f88c1 | ||
|
|
3dece9cd5c | ||
|
|
26cb6a8d20 | ||
|
|
a8b620a91f | ||
|
|
802a410834 | ||
|
|
ed2ea558a8 | ||
|
|
e32ebf58c7 | ||
|
|
276a43792c | ||
|
|
114afad93d | ||
|
|
47ea35f85b | ||
|
|
161db1b519 | ||
|
|
8d2773e188 | ||
|
|
03ab5315d5 | ||
|
|
17479b8a0f | ||
|
|
9c4f6365b8 | ||
|
|
fc25077468 | ||
|
|
3e983d2bc6 | ||
|
|
3daa76dd25 | ||
|
|
5ae27dbe85 | ||
|
|
095595dd61 | ||
|
|
d33ceff2a5 | ||
|
|
61dd954da2 | ||
|
|
70432e3bef | ||
|
|
18e06aefee | ||
|
|
659a5ca923 | ||
|
|
dcb20d8fd6 | ||
|
|
488f38424e | ||
|
|
7323b80041 | ||
|
|
a14adbcafe | ||
|
|
0570451948 | ||
|
|
c1170b27fc | ||
|
|
01ad5f9b94 | ||
|
|
97301cbc36 | ||
|
|
92600eeb76 | ||
|
|
a731bd9f44 | ||
|
|
af2589e943 | ||
|
|
6b0adb932b | ||
|
|
4308ba9e42 | ||
|
|
87b3063593 | ||
|
|
6d4e490ae1 | ||
|
|
2fa25b8799 | ||
|
|
35839a5f96 | ||
|
|
0f88e33c05 | ||
|
|
ee5fe8f38d | ||
|
|
2c486990c6 | ||
|
|
cf2fe4d2da | ||
|
|
c3b452be51 | ||
|
|
1a920b4b19 | ||
|
|
e964bb3779 | ||
|
|
fd5f2b33a9 | ||
|
|
3d8e6218ef | ||
|
|
f713b0d8b0 | ||
|
|
c0eb65d6be | ||
|
|
71d140e992 | ||
|
|
1cabc773e4 | ||
|
|
6708c4d24d | ||
|
|
c663066261 | ||
|
|
f19bd6bf3f | ||
|
|
033bea7a29 | ||
|
|
5112f925df | ||
|
|
152bcb4e6d | ||
|
|
c6a8a1bf04 | ||
|
|
ea23f45b36 | ||
|
|
e0217033e4 | ||
|
|
1e8876bdad | ||
|
|
f49b5760eb | ||
|
|
f89ebf69bf | ||
|
|
c96af79b53 | ||
|
|
3df90156fd | ||
|
|
0c52aed751 | ||
|
|
a9a4668b92 | ||
|
|
bb2f10122c | ||
|
|
1544debc9f | ||
|
|
240b4d18e3 | ||
|
|
49664eb29a | ||
|
|
e7155c5f3d | ||
|
|
fc069fb51b | ||
|
|
18843133b8 | ||
|
|
ef667d12e1 | ||
|
|
b8547bbff0 | ||
|
|
51eac9d194 | ||
|
|
a4ef92e0ec | ||
|
|
ca2cd45607 | ||
|
|
b79c07099f | ||
|
|
a9b5596a02 | ||
|
|
935a58c3a2 | ||
|
|
753e0cf3dd | ||
|
|
bd55197721 | ||
|
|
1abd496ccf | ||
|
|
a3ad6e8426 | ||
|
|
193021f8f6 | ||
|
|
fd2483fe83 | ||
|
|
040839d34b | ||
|
|
3f67551437 | ||
|
|
80aadb9e77 | ||
|
|
395e90b16b | ||
|
|
be563c3140 | ||
|
|
41f25857bb | ||
|
|
f63d9b778f | ||
|
|
8ea1d52d7a | ||
|
|
c511afe310 | ||
|
|
77e48a2801 | ||
|
|
9220edbf14 | ||
|
|
8d9da24365 | ||
|
|
fdc6323b34 | ||
|
|
92d2462660 | ||
|
|
c61f4fe7b3 | ||
|
|
7de39b3377 | ||
|
|
3d67565aed | ||
|
|
accaef402b | ||
|
|
e7b71d3932 | ||
|
|
157ab1fd10 | ||
|
|
5a6bacea03 | ||
|
|
d39c73dba2 | ||
|
|
614a83e555 | ||
|
|
fd631013d9 | ||
|
|
fe2506a5ff | ||
|
|
5f2c98c566 | ||
|
|
c2176e0843 | ||
|
|
eb4e27f356 | ||
|
|
25eff603b1 | ||
|
|
2c09220992 | ||
|
|
c85abb1789 | ||
|
|
42bf45cee1 | ||
|
|
e2c593c928 | ||
|
|
d3f8b43799 | ||
|
|
9c6c9f8fcd | ||
|
|
5f607a11a9 | ||
|
|
3a2a0b1c4c | ||
|
|
f6cf0fce5c | ||
|
|
6809236f2b | ||
|
|
5c988b679e | ||
|
|
ad54620a27 | ||
|
|
4382065fad | ||
|
|
b298ce0dd0 | ||
|
|
af1432d9a8 | ||
|
|
68b0858da6 | ||
|
|
e572e41cff | ||
|
|
f133f366e2 | ||
|
|
37a4fa83fb | ||
|
|
ac73fa6482 | ||
|
|
f695a4c3b6 | ||
|
|
9c90d59fc0 | ||
|
|
dd15de6bda | ||
|
|
d98f4b5a6a | ||
|
|
ba0a3f5673 | ||
|
|
7ad4a8f0b5 | ||
|
|
e62a2145bb | ||
|
|
6d47746e5a | ||
|
|
c81a6322c1 | ||
|
|
36bc1fb617 | ||
|
|
fdd1cf4772 | ||
|
|
20156b84eb | ||
|
|
261860cfec | ||
|
|
c6fa04834c | ||
|
|
9b4f865e5d | ||
|
|
b3140b0218 | ||
|
|
4a27c8a032 | ||
|
|
faaaabb640 | ||
|
|
8b9c2fbc66 | ||
|
|
bed6a98112 | ||
|
|
5d0e8a70bb | ||
|
|
40e365b239 | ||
|
|
45894683e9 | ||
|
|
26d4841366 | ||
|
|
7fd1152dea | ||
|
|
c2187f4f17 | ||
|
|
10198da7d0 | ||
|
|
66aa7f76d8 | ||
|
|
4fb6c33182 | ||
|
|
6f8da6f3b3 | ||
|
|
398b912ca5 | ||
|
|
ffb1961064 | ||
|
|
991af2d2f0 | ||
|
|
7c5adc1bb8 | ||
|
|
2413a30578 | ||
|
|
840d327139 | ||
|
|
8ea2a50279 | ||
|
|
69a24f699d | ||
|
|
ac9dd33e9a | ||
|
|
9ebca1715b | ||
|
|
fa0e1a6363 | ||
|
|
c6b71544a4 | ||
|
|
7e94fe102c | ||
|
|
8879087461 | ||
|
|
11260dc9d7 | ||
|
|
4a7e9488dd | ||
|
|
53532f9ec2 | ||
|
|
263c27f1ea | ||
|
|
b1593177fd | ||
|
|
983479603c | ||
|
|
cbd263dafe | ||
|
|
75efe4efbb | ||
|
|
fcace76909 | ||
|
|
4fc8d5412d | ||
|
|
7a7c43c72b | ||
|
|
9c7635228f | ||
|
|
0aa95a722a | ||
|
|
35ae0bfaa2 | ||
|
|
552da2b7f2 | ||
|
|
10c80a1344 | ||
|
|
948c33ba88 | ||
|
|
ed36254fcc | ||
|
|
4b541216e3 | ||
|
|
532ec10636 | ||
|
|
01f0478750 | ||
|
|
c8d4018067 | ||
|
|
04e25c59f7 | ||
|
|
b99ce6c644 | ||
|
|
eb09c03ae1 | ||
|
|
55d7aa9142 | ||
|
|
9d20219f73 | ||
|
|
5173670675 | ||
|
|
d4a0d6f6a5 | ||
|
|
8aa0debb6e | ||
|
|
4b5fb9c99b | ||
|
|
d631657862 | ||
|
|
385729ef2a | ||
|
|
984380543e | ||
|
|
e9d17fba59 | ||
|
|
e7609d54be | ||
|
|
af8557850b | ||
|
|
3df73b303e | ||
|
|
b7e4606a73 | ||
|
|
8fc9bfc66e | ||
|
|
4b2f06a0fa | ||
|
|
77e3df17cc | ||
|
|
6cfa5ae855 | ||
|
|
7ec507dec2 | ||
|
|
fd66d44562 | ||
|
|
50ac9e5aef | ||
|
|
ac4554b8c8 | ||
|
|
2cd330b733 | ||
|
|
33db0681c8 | ||
|
|
ddd2ce19ec | ||
|
|
f1f5996447 | ||
|
|
215e66b8d6 | ||
|
|
d956ec06f2 | ||
|
|
24bbf22171 | ||
|
|
9675190c46 | ||
|
|
eef3cdf70b | ||
|
|
bdde9d0aa2 | ||
|
|
2108d66d2b | ||
|
|
1306b02625 | ||
|
|
7cb5be80be | ||
|
|
bcf2e083cc | ||
|
|
ed7d034849 | ||
|
|
f834ec6410 | ||
|
|
7ce83ed0ca | ||
|
|
f9712217d8 | ||
|
|
e54ec4b8d2 | ||
|
|
7145b24e59 | ||
|
|
2b51649f74 | ||
|
|
a0a0428b34 | ||
|
|
1ae32f0c2d | ||
|
|
afaecf4140 | ||
|
|
16add2cb7a | ||
|
|
2475dbc759 | ||
|
|
bc517aaa2a | ||
|
|
9547f33a8e | ||
|
|
8d1923852a | ||
|
|
90175ea1d8 | ||
|
|
c6f204ab79 | ||
|
|
55090ad3f8 | ||
|
|
2e9cafa7e5 | ||
|
|
c9d1212cf2 | ||
|
|
be72d3fe1b | ||
|
|
f3627d1d8d | ||
|
|
6cd12c25ee | ||
|
|
3d913d6143 | ||
|
|
f757c17b2f | ||
|
|
bf496a03cf | ||
|
|
d558e94c93 | ||
|
|
a6a0ae3e74 | ||
|
|
16f626702d | ||
|
|
bdfee70cec | ||
|
|
b6813a0898 | ||
|
|
aa55dcf8f5 | ||
|
|
d92f023f4d | ||
|
|
a51420ddc8 | ||
|
|
90dce5bec5 | ||
|
|
ef6658864a | ||
|
|
af4be723b2 | ||
|
|
d4223acfed | ||
|
|
e7a663d137 | ||
|
|
01ef5c86f1 | ||
|
|
34c712bae0 | ||
|
|
93ca6a350e | ||
|
|
008dc0c248 | ||
|
|
bfd4ad90ed | ||
|
|
06049c7753 | ||
|
|
98f4eed1d4 | ||
|
|
1baeaf9201 | ||
|
|
e2b1618571 | ||
|
|
f70be2a9a7 | ||
|
|
c1e7c349c5 | ||
|
|
692fc9d24a | ||
|
|
6b0b91474a | ||
|
|
43e6623c3d | ||
|
|
13e162eb04 | ||
|
|
05e397b330 | ||
|
|
283efd226d | ||
|
|
4be86f6c14 | ||
|
|
56107bb783 | ||
|
|
49ad4ad943 | ||
|
|
3744c31519 | ||
|
|
34c7b71a89 | ||
|
|
fcb3b7d6b9 | ||
|
|
a7851234a7 | ||
|
|
79dcd3c4cf | ||
|
|
e7605bb420 | ||
|
|
6eb3a0ff12 | ||
|
|
856dafbe36 | ||
|
|
c4ba0d56d2 | ||
|
|
998c64cc5d | ||
|
|
81586fed7d | ||
|
|
d2549b91aa | ||
|
|
5e63f36507 | ||
|
|
9f2275ec67 | ||
|
|
c23bb9ce4f | ||
|
|
339702a044 | ||
|
|
bd731f1ed3 | ||
|
|
309e5aacc1 | ||
|
|
67acb0fa9e | ||
|
|
6d7d365d3c | ||
|
|
63610854d5 | ||
|
|
827b79d6c1 | ||
|
|
b7010976f0 | ||
|
|
6faa5e5bc4 | ||
|
|
03caef107a | ||
|
|
8650dda505 | ||
|
|
35876e07b3 | ||
|
|
0cb305a4f8 | ||
|
|
17c7216ee0 | ||
|
|
5a0738d82d | ||
|
|
beed320140 | ||
|
|
97ab5eb4d4 | ||
|
|
694406816b | ||
|
|
96f815aa74 | ||
|
|
12e5f25ced | ||
|
|
3835ea2241 | ||
|
|
b5b59b7ee6 | ||
|
|
169ce6948d | ||
|
|
ed8ccb2911 | ||
|
|
b36e230373 | ||
|
|
956681d54a | ||
|
|
736588313d | ||
|
|
f660a474af | ||
|
|
c8ee823db0 | ||
|
|
39d29d68b2 | ||
|
|
842fa7a716 | ||
|
|
839512558f | ||
|
|
f142761ab8 | ||
|
|
375f71522b | ||
|
|
2fb7ff2f43 | ||
|
|
d5b75a2768 | ||
|
|
2a4f59ce8f | ||
|
|
0d29b1ef72 | ||
|
|
306918850b | ||
|
|
6695acbd23 | ||
|
|
3871b272fd | ||
|
|
a630f7cf1d | ||
|
|
98536a9d8b | ||
|
|
eb15881a94 | ||
|
|
9aea9970bb | ||
|
|
7ce609a045 | ||
|
|
8d5ade4cef | ||
|
|
8e5d7f67ef | ||
|
|
1c3f186c11 | ||
|
|
cea7bd34ca | ||
|
|
6cd646e939 | ||
|
|
e506353517 | ||
|
|
c7c6ddf6e1 | ||
|
|
0eb7973e96 | ||
|
|
1d6714eea4 | ||
|
|
5849307944 | ||
|
|
e2dd22e13f | ||
|
|
4bbff1f82d | ||
|
|
ba1e0fbf46 | ||
|
|
d78df15074 | ||
|
|
77821ecb75 | ||
|
|
8fdf6abb81 | ||
|
|
2070287f64 | ||
|
|
35382136b4 | ||
|
|
875814b68b | ||
|
|
591b6e7d59 | ||
|
|
d3a2e6852c | ||
|
|
65b0cbbfeb | ||
|
|
95122f3209 | ||
|
|
16670b2d42 | ||
|
|
6c7c785e9d | ||
|
|
14b549692e | ||
|
|
4affc10629 | ||
|
|
6b398307a3 | ||
|
|
eb8f7ccead | ||
|
|
2ed8d327b8 | ||
|
|
f7b9d75e18 | ||
|
|
5295f6e657 | ||
|
|
eaa9026f2d | ||
|
|
5360b2e876 | ||
|
|
55f12ed0bb | ||
|
|
18d55a08b3 | ||
|
|
29db4eaa2c | ||
|
|
9c9d4b2177 | ||
|
|
0c51c2b3dc | ||
|
|
6a547ff74b | ||
|
|
a21aa4991d | ||
|
|
a97cbb59e2 | ||
|
|
3ae6ab890d | ||
|
|
7bd89a17dd | ||
|
|
18a5dc440f | ||
|
|
c7050f9f93 | ||
|
|
093b043bca | ||
|
|
57a3edd204 | ||
|
|
a712b3f5f4 | ||
|
|
0ec6f5f3e9 | ||
|
|
debdc829df | ||
|
|
4214d95e6f | ||
|
|
5eaeb31845 | ||
|
|
2c92e3f983 | ||
|
|
e566262369 | ||
|
|
6ea06ad338 | ||
|
|
8fb3f4a199 | ||
|
|
e1c35b0f16 | ||
|
|
0faa05d744 | ||
|
|
82e8134fc6 | ||
|
|
70e5f19ff8 | ||
|
|
5cd68e4606 | ||
|
|
7917d26b57 | ||
|
|
0cc6d8fccf | ||
|
|
ab84d192be | ||
|
|
73bf754530 | ||
|
|
d20ee838f0 | ||
|
|
c687f71c5a | ||
|
|
8994f31b03 | ||
|
|
7a16fdbd27 | ||
|
|
4978b31363 | ||
|
|
20a2136350 | ||
|
|
2dfed948a1 | ||
|
|
8b5cb40c24 | ||
|
|
1d819f780c | ||
|
|
296bc367dc | ||
|
|
794f365e4e | ||
|
|
d9afe5c129 | ||
|
|
6c44faecfd | ||
|
|
544be4d557 | ||
|
|
9a2babf4b6 | ||
|
|
b89acbbc31 | ||
|
|
b37cbba31d | ||
|
|
562fa5b78f | ||
|
|
1fcbd36e6d | ||
|
|
7be4d4640a | ||
|
|
7802d1e61c | ||
|
|
65029af613 | ||
|
|
f600d3e481 | ||
|
|
ada8f84019 | ||
|
|
73cac507ad | ||
|
|
063c192a12 | ||
|
|
b2576fd44f | ||
|
|
48c8f7c55b | ||
|
|
b05115978c | ||
|
|
bb74381c49 | ||
|
|
dc8e2ab453 | ||
|
|
c71f17295c | ||
|
|
4033a44b95 | ||
|
|
6f533a3d8a | ||
|
|
1bfe97474f | ||
|
|
ae6d79eae3 | ||
|
|
71a5313fc5 | ||
|
|
7daca337be | ||
|
|
da497ecb88 | ||
|
|
655a3126a2 | ||
|
|
ae0519643e | ||
|
|
f01f0ff5e0 | ||
|
|
8e64a1c73f | ||
|
|
c4fc154089 | ||
|
|
de38a0eca4 | ||
|
|
da85b57c61 | ||
|
|
514996363e | ||
|
|
4e4a4036cf | ||
|
|
680e256d17 | ||
|
|
a50d3f2029 | ||
|
|
8c761c73ad | ||
|
|
f8721992dd | ||
|
|
525bb0ed7e | ||
|
|
fe18a0e9b1 | ||
|
|
ec46829b38 | ||
|
|
03d440e1c0 | ||
|
|
a412c510d4 | ||
|
|
ac07cbb0ca | ||
|
|
ce2ae19703 | ||
|
|
ca8772a059 | ||
|
|
23a44e86ce | ||
|
|
5c5c577359 | ||
|
|
15675d6f49 | ||
|
|
4cb293e5a1 | ||
|
|
c3e88c6d59 | ||
|
|
d39471b761 | ||
|
|
ddcf71c483 | ||
|
|
28624bb7f6 | ||
|
|
d74b967c9e | ||
|
|
cdb8029c39 | ||
|
|
8ef253d9dc | ||
|
|
d91ac3b7b8 | ||
|
|
08f7cfae71 | ||
|
|
dd734b5a5d | ||
|
|
d8b14bd700 | ||
|
|
4e395f36af | ||
|
|
b9ad07ca0b | ||
|
|
6497cc956c | ||
|
|
ee3e6f12ae | ||
|
|
4f7f46d0b8 | ||
|
|
991ca2274f | ||
|
|
b72ea915ab | ||
|
|
055f1f483e | ||
|
|
a493c51949 | ||
|
|
45cb9dc7b1 | ||
|
|
45f5605f38 | ||
|
|
6c3558c2ac | ||
|
|
0dd36fd9f5 | ||
|
|
d07f529652 | ||
|
|
cb6d34ee25 | ||
|
|
00cc762934 | ||
|
|
409f64d09d | ||
|
|
5367710045 | ||
|
|
e5343487ac | ||
|
|
f0e94729bf | ||
|
|
673dee58ad | ||
|
|
9b16b3d7b8 | ||
|
|
51a711b609 | ||
|
|
022e5db8ec | ||
|
|
a29eb8c1d2 | ||
|
|
c16bb3d7c9 | ||
|
|
aaba243f41 | ||
|
|
41226129d7 | ||
|
|
17384705d3 | ||
|
|
5e489050e1 | ||
|
|
4100b87e38 | ||
|
|
5f6f1ab107 | ||
|
|
de713235ed | ||
|
|
6e2cd3fcfe | ||
|
|
b686c05f3b | ||
|
|
174f00fe03 | ||
|
|
4f1947c729 | ||
|
|
50c811c210 | ||
|
|
614614c89e | ||
|
|
4de8da30d0 | ||
|
|
2e23a75ff4 | ||
|
|
02a5c36cb9 | ||
|
|
f380b6b5da | ||
|
|
641bf4653a | ||
|
|
fd7b8ff912 | ||
|
|
4dd722e870 | ||
|
|
25e38548cb | ||
|
|
d8f5916a72 | ||
|
|
b27ae49ada | ||
|
|
7c9dd72b76 | ||
|
|
95b4b3ea3e | ||
|
|
2615ec3dee | ||
|
|
e4871a4a2c | ||
|
|
0dbe08cba2 | ||
|
|
f81e612976 | ||
|
|
2e828c812c | ||
|
|
3748fb07e8 | ||
|
|
251c2a2383 | ||
|
|
6cf87a7740 | ||
|
|
83638d2232 | ||
|
|
af69bece5b | ||
|
|
58637340e8 | ||
|
|
a3d0b7e43f | ||
|
|
07391c8f28 | ||
|
|
90741703de | ||
|
|
a962c4e340 | ||
|
|
20da71fb75 | ||
|
|
e8295e70af | ||
|
|
8954a0486c | ||
|
|
c36139bd55 | ||
|
|
41335dc90f | ||
|
|
33ccce8047 | ||
|
|
5b71dbb4e2 | ||
|
|
375cf41b62 | ||
|
|
f142b06770 | ||
|
|
e88e587c30 | ||
|
|
15c23426d8 | ||
|
|
bd59a23e0a | ||
|
|
ddc78bc5c0 | ||
|
|
8cd8c85017 | ||
|
|
d88973feba | ||
|
|
5410ce07eb | ||
|
|
4e855de5ae | ||
|
|
9053c5eadd | ||
|
|
016d0be3e0 | ||
|
|
97b8a7cd4d | ||
|
|
37f5e2f175 | ||
|
|
40ebc2a27b | ||
|
|
80f831e167 | ||
|
|
7e85b2bdde | ||
|
|
6cd84e1a15 | ||
|
|
f65be7ff50 | ||
|
|
7095c25d75 | ||
|
|
7df75cd38f | ||
|
|
58613036fb | ||
|
|
27cdd59feb | ||
|
|
9baa62f093 | ||
|
|
e651db5cf1 | ||
|
|
0314da12d0 | ||
|
|
4789b8eb3b | ||
|
|
e549631cee | ||
|
|
5d0ac38b24 | ||
|
|
a50bd94a0e | ||
|
|
fc410b16fc | ||
|
|
e730be9eec | ||
|
|
a55180af39 | ||
|
|
21f011822d | ||
|
|
9e7b94e7c1 | ||
|
|
16eac635ae | ||
|
|
41ffdb4fc4 | ||
|
|
508a9c3ebd | ||
|
|
a840f429e7 | ||
|
|
359a28fc69 | ||
|
|
ebb708b068 | ||
|
|
d6fed23482 | ||
|
|
27c7538eb2 | ||
|
|
9aee6dce1a | ||
|
|
9147eae986 | ||
|
|
be0abad331 | ||
|
|
47fa22b5cf | ||
|
|
b85d1443b7 | ||
|
|
afae8d98c5 | ||
|
|
373784fb86 | ||
|
|
51b63d6b5a | ||
|
|
6003d9ad36 | ||
|
|
120f6a9bf2 | ||
|
|
9ba824a27a | ||
|
|
ccde6eef9c | ||
|
|
93f50df68d | ||
|
|
4cc3aa052d | ||
|
|
b9c7ee9733 | ||
|
|
0b3d1b1e47 | ||
|
|
bd77e7d0f8 | ||
|
|
5d9bc065f5 | ||
|
|
147e4bc66f | ||
|
|
d71fc18027 | ||
|
|
065b04628f | ||
|
|
b2131fd973 | ||
|
|
507b8cd4ba | ||
|
|
3fbd4431f9 | ||
|
|
12cbd70562 | ||
|
|
c69e47414c | ||
|
|
e085d9bccb | ||
|
|
a7047d2243 | ||
|
|
a984c1329f | ||
|
|
db403663f7 | ||
|
|
75a30c7233 | ||
|
|
fdc3a171dc | ||
|
|
f57ac2fa05 | ||
|
|
b2a98beaee | ||
|
|
753450e21e | ||
|
|
c81b7d7156 | ||
|
|
f116d23398 | ||
|
|
0d9704fa7b | ||
|
|
5650d9fdd1 | ||
|
|
da3e324e7f | ||
|
|
7cf0a8601a | ||
|
|
e2e2111b1c | ||
|
|
55320820ba | ||
|
|
9af1962986 | ||
|
|
675d254b15 | ||
|
|
9901a6f0cd | ||
|
|
3a70279b7d | ||
|
|
ae635f837b | ||
|
|
e8fe75a589 | ||
|
|
14dbf42db8 | ||
|
|
5c29f19331 | ||
|
|
c185f97956 | ||
|
|
1652d1f3b4 | ||
|
|
02f9791e19 | ||
|
|
a27d6d90ec | ||
|
|
89d758c378 | ||
|
|
335786915a | ||
|
|
c8ac633540 | ||
|
|
81b7c2abc1 | ||
|
|
a2aed8eff2 | ||
|
|
e931611837 | ||
|
|
898b8673ed | ||
|
|
58d49c3af9 | ||
|
|
dcfe521fce | ||
|
|
434d35cf62 | ||
|
|
6cf9a9015d | ||
|
|
11eb34e8ee | ||
|
|
4eccd8094e | ||
|
|
f3fba1ee12 | ||
|
|
802968443e | ||
|
|
d50bdd0a16 | ||
|
|
80960e148b | ||
|
|
fcbde2dad4 | ||
|
|
9f85f6d66a | ||
|
|
5ed73ea30b | ||
|
|
2cf6676651 | ||
|
|
2e2e65b576 | ||
|
|
ebcfd99797 | ||
|
|
3d4145a7e3 | ||
|
|
fb93430ba6 | ||
|
|
ba122bc645 | ||
|
|
6e8529a62b | ||
|
|
680d2326a6 | ||
|
|
a6673450df | ||
|
|
af51b8fd42 | ||
|
|
4c1ca75177 | ||
|
|
d58428d3bd | ||
|
|
03a87edd97 | ||
|
|
5454f01e04 | ||
|
|
d88510d0b9 | ||
|
|
bfd27eda54 | ||
|
|
fd65c1661b | ||
|
|
bdf7cdd073 | ||
|
|
e0018cc874 | ||
|
|
314c4c6874 | ||
|
|
9ea095c41c | ||
|
|
3da7a2c23e | ||
|
|
f4e68f2504 | ||
|
|
dab83e9889 | ||
|
|
e1b7458984 | ||
|
|
c16d330371 | ||
|
|
8963c524d7 | ||
|
|
77b9675c4b | ||
|
|
bd45fa6a8f | ||
|
|
31ee5eca0d | ||
|
|
c5bcca7bab | ||
|
|
1ec334a99f | ||
|
|
073788340b | ||
|
|
0d90cd59dc | ||
|
|
fd52bf2bd8 | ||
|
|
61463cbc2a | ||
|
|
f902cf4675 | ||
|
|
9f83137631 | ||
|
|
7c811718a7 | ||
|
|
5d51f8ee55 | ||
|
|
fe3200ed07 | ||
|
|
8c16118248 | ||
|
|
b2e297ed27 | ||
|
|
2ebb360d0e | ||
|
|
cc2abd5275 | ||
|
|
4ec67e7df3 | ||
|
|
3033a27023 | ||
|
|
ed264ac576 | ||
|
|
0394a52b81 | ||
|
|
5301c168e4 | ||
|
|
5ec97e6b22 | ||
|
|
3bd2828386 | ||
|
|
3cc7a5f2a8 | ||
|
|
b71f73322a | ||
|
|
8f73c27ca6 | ||
|
|
1fc6e75705 | ||
|
|
974e2188cc | ||
|
|
aae2d28e7f | ||
|
|
106c57d48f | ||
|
|
7801f96096 | ||
|
|
a5d3a242d1 | ||
|
|
1800daed83 | ||
|
|
1fc9449e0d | ||
|
|
9ebf68f5f8 | ||
|
|
33b0617d99 | ||
|
|
e9b28977a5 | ||
|
|
c15ae34535 | ||
|
|
529bfcae52 | ||
|
|
d70ac295c4 | ||
|
|
d15c493713 | ||
|
|
07bec98624 | ||
|
|
f389c07436 | ||
|
|
fb90dd014c | ||
|
|
3a90b70eac | ||
|
|
d4cfbfd310 | ||
|
|
cd8d0410fd | ||
|
|
2c95d3c427 | ||
|
|
4c85a6c5ba | ||
|
|
a623b65a98 | ||
|
|
5bc9ba45bf | ||
|
|
b4664a5796 | ||
|
|
e7a0f547f8 | ||
|
|
2ec9fdbe8d | ||
|
|
293086db3f | ||
|
|
435d875a02 | ||
|
|
14d6306385 | ||
|
|
8ae87f8762 | ||
|
|
9e7f020233 | ||
|
|
45bf902713 | ||
|
|
837d371f50 | ||
|
|
0debfe1163 | ||
|
|
3652c75a5d | ||
|
|
8d9de08fc9 | ||
|
|
78d474a58e | ||
|
|
07b7ac10b6 | ||
|
|
08fa24dd93 | ||
|
|
47d920fd66 | ||
|
|
af153a37f0 | ||
|
|
e6c6bdc2d9 | ||
|
|
594e183737 | ||
|
|
2832208fc5 | ||
|
|
769be40253 | ||
|
|
c31d9b7850 | ||
|
|
6e9a4ec6e6 | ||
|
|
179effddf3 | ||
|
|
6c0b8b370b | ||
|
|
7f6afc578c | ||
|
|
82ac093b6b | ||
|
|
20c0cd2a88 | ||
|
|
caa461e493 | ||
|
|
558795b066 | ||
|
|
755958ac16 | ||
|
|
00beb9dbce | ||
|
|
5302361ece | ||
|
|
f96922968f | ||
|
|
26a1202ee0 | ||
|
|
915c446634 | ||
|
|
be66394313 | ||
|
|
6eee55fde4 | ||
|
|
8a86509e4b | ||
|
|
610e0c36ec | ||
|
|
dbaedcda20 | ||
|
|
7c79b7026b | ||
|
|
248fcb16be | ||
|
|
cda63e432c | ||
|
|
bc6120892a | ||
|
|
5eae9a11dd | ||
|
|
89f833b5d0 | ||
|
|
8ab3132acb | ||
|
|
b35690c4b9 | ||
|
|
d1245e43e4 | ||
|
|
98bd51e9ad | ||
|
|
8455b5b0c1 | ||
|
|
29ec528c42 | ||
|
|
abe964d237 | ||
|
|
7a974d0ef1 | ||
|
|
33b6f2a71a | ||
|
|
4b6f7554c0 | ||
|
|
bfaac17306 | ||
|
|
4f0b31cf5d | ||
|
|
d7ded80028 | ||
|
|
2c11564d0a | ||
|
|
d6ee6ce580 | ||
|
|
941047121f | ||
|
|
72b7ea5d77 | ||
|
|
59a18f6a83 | ||
|
|
d708e20b12 | ||
|
|
81bf1d581d | ||
|
|
463ccd8283 | ||
|
|
d9e33dbaec | ||
|
|
9831d1492d | ||
|
|
cb228e9002 | ||
|
|
48099d9569 | ||
|
|
0b717a898b | ||
|
|
8a19278ac8 | ||
|
|
241a5e6798 | ||
|
|
21c8c2ba44 | ||
|
|
b59c0d1274 | ||
|
|
3d4fe01bb6 | ||
|
|
da110d3f59 | ||
|
|
01a12a109a | ||
|
|
f201adbbdb | ||
|
|
416fb87dff | ||
|
|
8d2075dd85 | ||
|
|
03851bac05 | ||
|
|
4ef373153a | ||
|
|
854c4614e9 | ||
|
|
a5f2931544 | ||
|
|
b17bfef199 | ||
|
|
f06e6a7802 | ||
|
|
32733912f1 | ||
|
|
c52b6d3fc0 | ||
|
|
f6534cb075 | ||
|
|
1574ad43b2 | ||
|
|
6e05f972a1 | ||
|
|
af3aa7d9fc | ||
|
|
037483602a | ||
|
|
9ba6732230 | ||
|
|
d190f54321 | ||
|
|
608a52b9b9 | ||
|
|
8a185f8107 | ||
|
|
f6fec8adf1 | ||
|
|
d7ac826f89 | ||
|
|
d88ac3a972 | ||
|
|
aaf5c39690 | ||
|
|
07e278c9d4 | ||
|
|
f48a7e5f78 | ||
|
|
16ea198a13 | ||
|
|
1e219b65bf | ||
|
|
ec36147dbf | ||
|
|
e31196d184 | ||
|
|
cea50a67e1 | ||
|
|
41a0f1c59b | ||
|
|
9c5c168394 | ||
|
|
0f5232c5d2 | ||
|
|
a920cec9aa | ||
|
|
dd68136bd9 | ||
|
|
174c207381 | ||
|
|
f16e2e6650 | ||
|
|
bbcb203900 | ||
|
|
40e65a119d | ||
|
|
e58c52ae7e | ||
|
|
bd49c212c3 | ||
|
|
03222e4d82 | ||
|
|
54e893af56 | ||
|
|
07075670c3 | ||
|
|
a6df543348 | ||
|
|
857e1a6b30 | ||
|
|
05eadd933c | ||
|
|
4c5cf3125f | ||
|
|
1fe950b9a6 | ||
|
|
54a2a9dd13 | ||
|
|
6df2d4c33c | ||
|
|
5555b1c3a8 | ||
|
|
fcc8f8fbd0 | ||
|
|
2827407d43 | ||
|
|
d9d34ae282 | ||
|
|
e3718c88b2 | ||
|
|
4bab2c1afd | ||
|
|
7ad332abf8 | ||
|
|
4b7ea20437 | ||
|
|
ea17af230a | ||
|
|
ab37eae5cb | ||
|
|
1019c662a5 | ||
|
|
f16941595a | ||
|
|
46d3edd8c1 | ||
|
|
81cd0ebfa0 | ||
|
|
516eacd03f | ||
|
|
df34134534 | ||
|
|
a022fb30d0 | ||
|
|
ded0b2efba | ||
|
|
f3ba6741ec | ||
|
|
ed84676c15 | ||
|
|
bcaf766768 | ||
|
|
5386b85b15 | ||
|
|
d32b02e1ca | ||
|
|
dde44ae7b2 | ||
|
|
b12880ce40 | ||
|
|
c60242c944 | ||
|
|
65995b5c4f | ||
|
|
a8bb6a9eca | ||
|
|
b391a7a372 | ||
|
|
4a15ca11e7 | ||
|
|
cb8e121ca9 | ||
|
|
6caa25e9f6 | ||
|
|
6c46b47b75 | ||
|
|
c03f73a3b3 | ||
|
|
d483bd4ecc | ||
|
|
57c012b007 | ||
|
|
2eced40646 | ||
|
|
1102505d22 | ||
|
|
e6659bd69f |
No files matched your search
@@ -1,21 +1,6 @@
|
||||
set $zts = 0
|
||||
|
||||
define ____executor_globals
|
||||
if $zts
|
||||
set $eg = ((zend_executor_globals) (*((void ***) tsrm_ls))[executor_globals_id-1])
|
||||
else
|
||||
set $eg = executor_globals
|
||||
end
|
||||
end
|
||||
|
||||
document ____executor_globals
|
||||
portable way of accessing executor_globals
|
||||
type "set $zts = 1" if you use --enable-maintainer-zts on your configure line
|
||||
end
|
||||
|
||||
define dump_bt
|
||||
set $t = $arg0
|
||||
while $t
|
||||
set $t = $arg0
|
||||
while $t
|
||||
printf "[0x%08x] ", $t
|
||||
if $t->function_state.function->common.function_name
|
||||
printf "%s() ", $t->function_state.function->common.function_name
|
||||
@@ -27,7 +12,7 @@ define dump_bt
|
||||
end
|
||||
set $t = $t->prev_execute_data
|
||||
printf "\n"
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
document dump_bt
|
||||
@@ -35,7 +20,7 @@ document dump_bt
|
||||
end
|
||||
|
||||
define printzv
|
||||
set $ind = 1
|
||||
set $ind = 0
|
||||
____printzv $arg0 0
|
||||
end
|
||||
|
||||
@@ -43,56 +28,60 @@ document printzv
|
||||
prints content of zval
|
||||
end
|
||||
|
||||
define ____printzv_contents
|
||||
____executor_globals
|
||||
define ____printzv
|
||||
set $zvalue = $arg0
|
||||
|
||||
if $zvalue.type == 0
|
||||
if $zvalue->type == 0
|
||||
set $typename = "NULL"
|
||||
end
|
||||
if $zvalue.type == 1
|
||||
if $zvalue->type == 1
|
||||
set $typename = "long"
|
||||
end
|
||||
if $zvalue.type == 2
|
||||
if $zvalue->type == 2
|
||||
set $typename = "double"
|
||||
end
|
||||
if $zvalue.type == 3
|
||||
if $zvalue->type == 3
|
||||
set $typename = "string"
|
||||
end
|
||||
if $zvalue.type == 4
|
||||
if $zvalue->type == 4
|
||||
set $typename = "array"
|
||||
end
|
||||
if $zvalue.type == 5
|
||||
if $zvalue->type == 5
|
||||
set $typename = "object"
|
||||
end
|
||||
if $zvalue.type == 6
|
||||
if $zvalue->type == 6
|
||||
set $typename = "bool"
|
||||
end
|
||||
if $zvalue.type == 7
|
||||
if $zvalue->type == 7
|
||||
set $typename = "resource"
|
||||
end
|
||||
if $zvalue.type == 8
|
||||
if $zvalue->type == 8
|
||||
set $typename = "constant"
|
||||
end
|
||||
if $zvalue.type == 9
|
||||
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
|
||||
printf "[0x%08x] ", $zvalue
|
||||
|
||||
if $zvalue == executor_globals.uninitialized_zval_ptr
|
||||
printf "*uninitialized* "
|
||||
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
|
||||
printf "%lf", $zvalue->value.dval
|
||||
end
|
||||
if $zvalue.type == 3
|
||||
printf "\"%s\"(%d)", $zvalue.value.str.val, $zvalue.value.str.len
|
||||
if $zvalue->type == 3
|
||||
printf "\"%s\"(%d)", $zvalue->value.str.val, $zvalue->value.str.len
|
||||
end
|
||||
if $zvalue.type == 4
|
||||
if $zvalue->type == 4
|
||||
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
|
||||
@@ -102,86 +91,35 @@ define ____printzv_contents
|
||||
printf "}"
|
||||
end
|
||||
end
|
||||
if $zvalue.type == 5
|
||||
if $zvalue->type == 5
|
||||
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 "}"
|
||||
end
|
||||
# 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 "}"
|
||||
end
|
||||
end
|
||||
if $zvalue.type == 6
|
||||
if $zvalue.value.lval
|
||||
if $zvalue->type == 6
|
||||
if $zvalue->lval
|
||||
printf "true"
|
||||
else
|
||||
printf "false"
|
||||
end
|
||||
end
|
||||
if $zvalue.type == 7
|
||||
printf "#%d", $zvalue.value.lval
|
||||
if $zvalue->type == 7
|
||||
printf "#%d", $zvalue->value.lval
|
||||
end
|
||||
printf "\n"
|
||||
end
|
||||
|
||||
define ____printzv
|
||||
____executor_globals
|
||||
set $zvalue = $arg0
|
||||
|
||||
printf "[0x%08x] ", $zvalue
|
||||
|
||||
if $zvalue == $eg.uninitialized_zval_ptr
|
||||
printf "*uninitialized* "
|
||||
end
|
||||
|
||||
set $zcontents = *(struct _zval_struct *) $zvalue
|
||||
if $arg1
|
||||
____printzv_contents $zcontents $arg1
|
||||
else
|
||||
____printzv_contents $zcontents 0
|
||||
end
|
||||
end
|
||||
|
||||
define ____print_const_table
|
||||
set $ht = $arg0
|
||||
set $p = $ht->pListHead
|
||||
|
||||
while $p != 0
|
||||
set $const = *(zend_constant *) $p->pData
|
||||
|
||||
set $i = $ind
|
||||
while $i > 0
|
||||
printf " "
|
||||
set $i = $i - 1
|
||||
end
|
||||
|
||||
if $p->nKeyLength > 0
|
||||
printf "\"%s\" => ", $p->arKey
|
||||
else
|
||||
printf "%d => ", $p->h
|
||||
end
|
||||
|
||||
____printzv_contents $const.value 0
|
||||
set $p = $p->pListNext
|
||||
end
|
||||
end
|
||||
|
||||
define print_const_table
|
||||
set $ind = 1
|
||||
printf "[0x%08x] {\n", $arg0
|
||||
____print_const_table $arg0
|
||||
printf "}\n"
|
||||
end
|
||||
|
||||
define ____print_ht
|
||||
set $ht = $arg0
|
||||
set $p = $ht->pListHead
|
||||
@@ -218,7 +156,6 @@ document print_ht
|
||||
end
|
||||
|
||||
define printzn
|
||||
____executor_globals
|
||||
set $ind = 0
|
||||
set $znode = $arg0
|
||||
if $znode->op_type == 1
|
||||
@@ -238,17 +175,17 @@ define printzn
|
||||
|
||||
if $znode->op_type == 1
|
||||
printf ": "
|
||||
____printzv &$znode->u.constant 0
|
||||
____printzv &$znode->u.constant
|
||||
end
|
||||
if $znode->op_type == 2
|
||||
printf ": "
|
||||
set $tvar = (union _temp_variable *)((char *)$eg.current_execute_data->Ts + $znode->u.var)
|
||||
____printzv ((union _temp_variable *)$tvar)->tmp_var 0
|
||||
set $tvar = (union _temp_variable *)((char *)executor_globals.current_execute_data->Ts + $znode->u.var)
|
||||
____printzv ((union _temp_variable *)$tvar)->tmp_var
|
||||
end
|
||||
if $znode->op_type == 4
|
||||
printf ": "
|
||||
set $tvar = (union _temp_variable *)((char *)$eg.current_execute_data->Ts + $znode->u.var)
|
||||
____printzv *$tvar->var.ptr_ptr 0
|
||||
set $tvar = (union _temp_variable *)((char *)executor_globals.current_execute_data->Ts + $znode->u.var)
|
||||
____printzv *$tvar->var.ptr_ptr
|
||||
end
|
||||
if $znode->op_type == 8
|
||||
printf "\n"
|
||||
|
||||
+62
-21
@@ -48,27 +48,81 @@ Exceptions:
|
||||
doing so, should return that new length, so it doesn't have to be
|
||||
recalculated with strlen() (e.g. php_addslashes())
|
||||
|
||||
[5] NEVER USE strncat(). If you're absolutely sure you know what you're doing,
|
||||
[5] Use php_error_docref() group of functions to report any errors/warnings
|
||||
during code execution. Use descriptive error messages, and try to avoid
|
||||
using identical error strings for different stages of an error. For
|
||||
example, if in order to obtain a URL you have to parse the URL, connect,
|
||||
and retreive the text, assuming something can go wrong at each of these
|
||||
stages, don't report an error "Unable to get URL" on all of them, but
|
||||
instead, write something like "Unable to parse URL", "Unable to connect
|
||||
to URL server" and "Unable to fetch URL text", respectively.
|
||||
|
||||
It has been silently agreed to prefix every php_error() message with the
|
||||
name of the current function if applicable:
|
||||
|
||||
php_error(E_WHATEVER, "%s(): Desc.", get_active_function_name(TSRMLS_C));
|
||||
|
||||
This can be done automatically using php_error_docref(). The first
|
||||
parameter, docref, is either NULL or the URL of a page describing the
|
||||
error in detail. In most cases you will pass NULL, to generate the URL
|
||||
from the name of the function being executed:
|
||||
|
||||
php_error_docref(NULL TSRMLS_CC, E_WHATEVER, "Desc.");
|
||||
|
||||
If you pass a URL, it can either be a full URL beginning with "http://":
|
||||
|
||||
php_error_docref("http://externalsite.tld/page.ext#error"
|
||||
TSRMLS_CC, E_WHATEVER, "Desc.");
|
||||
|
||||
Or the name of a manual page without file extension, but with an optional
|
||||
target anchor. Or simply the anchor within the manual page of the current
|
||||
function. When using function names you must replace '_' by '-':
|
||||
|
||||
php_error_docref("function.ext-func#error" TSRMLS_CC, E_WHATEVER, "Desc.");
|
||||
|
||||
To display one or two important parameters after the function name, use
|
||||
php_error_docref1() or php_error_docref2(). For example, file functions
|
||||
should display the name of the file opened:
|
||||
|
||||
php_error_docref1("function.fopen" TSRMLS_CC, filename,
|
||||
E_WHATEVER, "Desc.");
|
||||
|
||||
php_error_docref2("function.fopen" TSRMLS_CC, filename, openmode,
|
||||
E_WHATEVER, "Desc.");
|
||||
|
||||
Fixing ("unifying") existing php_error() message is a good thing [tm].
|
||||
|
||||
[6] NEVER USE strncat(). If you're absolutely sure you know what you're doing,
|
||||
check its man page again, and only then, consider using it, and even then,
|
||||
try avoiding it.
|
||||
|
||||
[6] Use PHP_* macros in the PHP source, and ZEND_* macros in the Zend
|
||||
[7] Use PHP_* macros in the PHP source, and ZEND_* macros in the Zend
|
||||
part of the source. Although the PHP_* macro's are mostly aliased to the
|
||||
ZEND_* macros it gives a better understanding on what kind of macro you're
|
||||
calling.
|
||||
|
||||
[7] When commenting out code using a #if statement, do NOT use 0 only. Instead
|
||||
[8] Use assert(). assert.h is included in php.h if it is available. Not only
|
||||
does good assertion catch bugs, but it also helps with code readability.
|
||||
- Do not use assert for error handling. Use assert only for the
|
||||
condition that must be always true.
|
||||
- Do not use assignments in assert conditions. If you assign inside an
|
||||
assert condition, you risk an elusive bug that would be very difficult
|
||||
to spot in a debug build, due to the side effect of the assignment.
|
||||
Function calls in assert conditions may also cause this problem, if
|
||||
they modify one of their arguments or global variables.
|
||||
|
||||
[9] When commenting out code using a #if statement, do NOT use 0 only. Instead
|
||||
use "<cvs username here>_0". For example, #if FOO_0, where FOO is your
|
||||
cvs user foo. This allows easier tracking of why code was commented out,
|
||||
especially in bundled libraries.
|
||||
|
||||
[8] Do not define functions that are not available. For instance, if a
|
||||
[10] Do not define functions that are not available. For instance, if a
|
||||
library is missing a function, do not define the PHP version of the
|
||||
function, and do not raise a run-time error about the function not
|
||||
existing. End users should use function_exists() to test for the
|
||||
existence of a function
|
||||
|
||||
[9] Prefer emalloc(), efree(), estrdup(), etc. to their standard C library
|
||||
[11] Prefer emalloc(), efree(), estrdup(), etc. to their standard C library
|
||||
counterparts. These functions implement an internal "safety-net"
|
||||
mechanism that ensures the deallocation of any unfreed memory at the
|
||||
end of a request. They also provide useful allocation and overflow
|
||||
@@ -104,7 +158,8 @@ Naming Conventions
|
||||
'hw_GetObjectByQueryCollObj'
|
||||
'pg_setclientencoding'
|
||||
'jf_n_s_i'
|
||||
|
||||
|
||||
|
||||
[2] If they are part of a "parent set" of functions, that parent should
|
||||
be included in the user function name, and should be clearly related
|
||||
to the parent program or function family. This should be in the form
|
||||
@@ -125,7 +180,7 @@ Naming Conventions
|
||||
with "_php_", and followed by a word or an underscore-delimited list of
|
||||
words, in lowercase letters, that describes the function. If applicable,
|
||||
they should be declared 'static'.
|
||||
|
||||
|
||||
[4] Variable names must be meaningful. One letter variable names must be
|
||||
avoided, except for places where the variable has no real meaning or
|
||||
a trivial meaning (e.g. for (i=0; i<100; i++) ...).
|
||||
@@ -133,20 +188,6 @@ Naming Conventions
|
||||
[5] Variable names should be in lowercase. Use underscores to separate
|
||||
between words.
|
||||
|
||||
[6] 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'.
|
||||
|
||||
Good:
|
||||
'Curl'
|
||||
'Foo_Bar'
|
||||
|
||||
Bad:
|
||||
'foobar'
|
||||
'foo_bar'
|
||||
'FooBar'
|
||||
|
||||
|
||||
Syntax and indentation
|
||||
----------------------
|
||||
|
||||
Binary file not shown.
+150
-100
@@ -26,56 +26,42 @@ Status legend
|
||||
|
||||
== Server APIs ==
|
||||
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: aolserver
|
||||
MAINTENANCE: Unknown
|
||||
STATUS: Unknown
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: activescript
|
||||
PRIMARY MAINTAINER: Wez Furlong <wez@php.net>
|
||||
MAINTENANCE: Odd Fixes
|
||||
STATUS: Experimental
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: aolserver
|
||||
MAINTENANCE: Unknown
|
||||
STATUS: Unknown
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: apache
|
||||
PRIMARY MAINTAINER: Rasmus Lerdorf <rasmus@php.net>
|
||||
MAINTENANCE: Maintained
|
||||
STATUS: Working
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: apache2handler / apache2filter
|
||||
EXTENSION: apache2
|
||||
PRIMARY MAINTAINER: Aaron Bannert <aaron@php.net>
|
||||
MAINTENANCE: Maintained
|
||||
STATUS: Experimental
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: apache_hooks
|
||||
MAINTENANCE: Unknown
|
||||
STATUS: Unknown
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: caudium
|
||||
MAINTENANCE: Unknown
|
||||
STATUS: Unknown
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: cgi
|
||||
MAINTENANCE: Unknown
|
||||
STATUS: Working
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: cli
|
||||
MAINTENANCE: Marcus Boerger <helly@php.net>, Edin Kadribasic <edink@php.net>
|
||||
MAINTENANCE: Unknown
|
||||
STATUS: Working
|
||||
SINCE: 4.3.0
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: embed
|
||||
PRIMARY MAINTAINER: Edin Kadribasic <edink@php.net>
|
||||
MAINTENANCE: Maintained
|
||||
STATUS: Working
|
||||
EXTENSION: fhttpd
|
||||
MAINTENANCE: Unknown
|
||||
STATUS: Unknown
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: isapi
|
||||
MAINTENANCE: Unknown
|
||||
STATUS: Working
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: milter
|
||||
MAINTENANCE: Unknown
|
||||
STATUS: Unknown
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: nsapi
|
||||
PRIMARY MAINTAINER: Uwe Schindler <thetaphi@php.net>
|
||||
MAINTENANCE: Maintained
|
||||
@@ -93,12 +79,12 @@ EXTENSION: roxen
|
||||
MAINTENANCE: Unknown
|
||||
STATUS: Unknown
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: thttpd
|
||||
PRIMARY MAINTAINER: Sascha Schumann <sascha@schumann.cx>
|
||||
MAINTENANCE: Odd fixes
|
||||
EXTENSION: servlet
|
||||
PRIMARY MAINTAINER: Sam Ruby <rubys@us.ibm.com>
|
||||
MAINTENANCE: Maintained
|
||||
STATUS: Working
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: tux
|
||||
EXTENSION: thttpd
|
||||
MAINTENANCE: Unknown
|
||||
STATUS: Unknown
|
||||
-------------------------------------------------------------------------------
|
||||
@@ -116,7 +102,6 @@ EXTENSION: dba
|
||||
PRIMARY MAINTAINER: Marcus Börger <helly@php.net>
|
||||
MAINTENANCE: Maintained
|
||||
STATUS: Working
|
||||
COMMENT: DBM abstraction for db2, db3, db4, dbm, ndbm, gdbm, ini
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: dbase
|
||||
PRIMARY MAINTAINER: Jim Winstead <jimw@php.net>
|
||||
@@ -134,10 +119,10 @@ EXTENSION: filepro
|
||||
MAINTENANCE: Unknown
|
||||
STATUS: Unknown
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: hwapi
|
||||
EXTENSION: hyperwave
|
||||
PRIMARY MAINTAINER: Uwe Steinmann <steinm@php.net>
|
||||
MAINTENANCE: Unknown
|
||||
STATUS: Unknown
|
||||
MAINTENANCE: Maintained
|
||||
STATUS: Working
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: informix
|
||||
PRIMARY MAINTAINER: Danny Heijl <Danny.Heijl@cevi.be>
|
||||
@@ -151,14 +136,20 @@ STATUS: Experimental
|
||||
SINCE: 4.0.2
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: interbase
|
||||
PRIMARY MAINTAINER: Ard Biesheuvel <ard@ard.nu>, Jouni Ahto <jouni.ahto@exdec.fi>
|
||||
MAINTENANCE: Maintained
|
||||
PRIMARY MAINTAINER: Jouni Ahto <jouni.ahto@exdec.fi>, Ard Biesheuvel <ard@ard.nu>
|
||||
MAINTENANCE: Odd Fixes
|
||||
STATUS: Working
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: msql
|
||||
MAINTENANCE: Unknown
|
||||
STATUS: Working
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: msession
|
||||
PRIMARY MAINTAINER Mark L. Woodward mlwmohawk@mohawksoft.com
|
||||
MAINTENANCE: Maintained
|
||||
STATUS: Working/Experimental
|
||||
COMMENT: Tested on Linux, should work on other UNIX platforms. Backend server code can compile under Windows.
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: mssql
|
||||
PRIMARY MAINTAINER: Frank M. Kromann <fmk@swwwing.com>
|
||||
MAINTENANCE: Maintained
|
||||
@@ -170,25 +161,12 @@ PRIMARY MAINTAINER: Zak Greant <zak@mysql.com>, Georg Richter <georg@php.net>
|
||||
MAINTENANCE: Maintained
|
||||
STATUS: Working
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: mysqli
|
||||
PRIMARY MAINTAINER: Georg Richter <georg@php.net>
|
||||
MAINTENANCE: Maintained
|
||||
STATUS: Experimental
|
||||
SINCE: 5.0
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: pgsql
|
||||
PRIMARY MAINTAINER: Marcus Boerger <helly@php.net>, Yasuo Ohgaki <yohgaki@php.net>
|
||||
PRIMARY MAINTAINER: Yasuo Ohgaki <yohgaki@php.net>
|
||||
MAINTENANCE: Maintained
|
||||
STATUS: Working
|
||||
COMMENT: Use PostgreSQL 7.0.x or later. PostgreSQL 6.5.3 or less have fatal bug.
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: sqlite
|
||||
PRIMARY MAINTAINER: Marcus Boerger <helly@php.net>, Wez Furlong <wez@php.net>
|
||||
MAINTENANCE: Maintained
|
||||
STATUS: Working
|
||||
SINCE: 5.0 (Since 4.3.2 in PECL)
|
||||
COMMENT: Integrates SQLite embeddable SQL database engine.
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: sybase
|
||||
MAINTENANCE: Unknown
|
||||
STATUS: Not Working
|
||||
@@ -198,7 +176,8 @@ MAINTENANCE: Unknown
|
||||
STATUS: Working
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: oci8
|
||||
MAINTENANCE: Orphaned
|
||||
PRIMARY MAINTAINER: Antony Dovgal <tony2001@php.net>
|
||||
MAINTENANCE: Maintained
|
||||
STATUS: Working
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: odbc
|
||||
@@ -214,80 +193,58 @@ COMMENT: Using the new OCI8 driver is encouraged where possible.
|
||||
-------------------------------------------------------------------------------
|
||||
|
||||
|
||||
== XML extensions ==
|
||||
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: dom
|
||||
PRIMARY MAINTAINER: Christian Stocker <chregu@php.net>, Rob Richards <rrichards@php.net>, Marcus Boerger <helly@php.net>
|
||||
MAINTENANCE: Maintained
|
||||
STATUS: Experimental
|
||||
SINCE: 5.0
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: simplexml
|
||||
PRIMARY MAINTAINER: Sterling Hughes <sterling@php.net>
|
||||
MAINTENANCE: Maintained
|
||||
STATUS: Experimental
|
||||
SINCE: 5.0
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: wddx
|
||||
PRIMARY MAINTAINER: Andrei Zmievski <andrei@php.net>
|
||||
MAINTENANCE: Maintained
|
||||
STATUS: Working
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: xml
|
||||
PRIMARY MAINTAINER: Thies C. Arntzen <thies@thieso.net>
|
||||
MAINTENANCE: Maintained
|
||||
STATUS: Working
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: xmlrpc
|
||||
PRIMARY MAINTAINER: Dan Libby
|
||||
MAINTENANCE: UNKNOWN
|
||||
STATUS: Experimental
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: xsl
|
||||
PRIMARY MAINTAINER: Christian Stocker <chregu@php.net>, Rob Richards <rrichards@php.net>
|
||||
MAINTENANCE: Maintained
|
||||
STATUS: Experimental
|
||||
SINCE: 5.0
|
||||
-------------------------------------------------------------------------------
|
||||
|
||||
|
||||
== Other extensions ==
|
||||
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: aspell
|
||||
MAINTENANCE: Unknown
|
||||
STATUS: Working
|
||||
COMMENT: For aspell .27 and greater, check out the pspell extension
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: bcmath
|
||||
MAINTENANCE: Unknown
|
||||
STATUS: Unknown
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: bz2
|
||||
PRIMARY MAINTAINER: Hartmut Holzgraefe <hholzgra@php.net>
|
||||
PRIMARY MAINTAINER: Hartmut Holzgraefe <hartmut@six.de>
|
||||
MAINTENANCE: Odd Fixes
|
||||
STATUS: Working
|
||||
SINCE: 4.0.3
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: dio
|
||||
PRIMARY MAINTAINER: Sterling Hughes <sterling@php.net>
|
||||
MAINTENANCE: Orphaned
|
||||
STATUS: Working
|
||||
SINCE: 4.0.6
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: cyrus
|
||||
PRIMARY MAINTAINER: Sterling Hughes <sterling@php.net>
|
||||
MAINTENANCE: Orphaned
|
||||
STATUS: Working
|
||||
SINCE: 4.0.6
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: calendar
|
||||
PRIMARY MAINTAINER: Hartmut Holzgraefe <hholzgra@php.net>
|
||||
PRIMARY MAINTAINER: Hartmut Holzgraefe <hartmut@six.de>
|
||||
MAINTENANCE: Odd Fixes
|
||||
STATUS: Working
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: com_dotnet
|
||||
PRIMARY MAINTAINER: Wez Furlong <wez@php.net>
|
||||
EXTENSION: com
|
||||
PRIMARY MAINTAINER: Harald Radi <h.radi@nme.at>
|
||||
MAINTENANCE: Maintained
|
||||
STATUS: Windows
|
||||
SINCE: 5.0
|
||||
STATUS: Working
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: cpdf
|
||||
PRIMARY MAINTAINER: Uwe Steinmann <steinm@php.net>
|
||||
MAINTENANCE: Maintained
|
||||
STATUS: Working
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: crack
|
||||
MAINTENANCE: Unknown
|
||||
STATUS: Experimental
|
||||
SINCE: 4.0.5
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: ctype
|
||||
PRIMARY MAINTAINER: Hartmut Holzgraefe <hholzgra@php.net>
|
||||
PRIMARY MAINTAINER: Hartmut Holzgraefe <hartmut@six.de>
|
||||
MAINTENANCE: Maintained
|
||||
STATUS: Working
|
||||
-------------------------------------------------------------------------------
|
||||
@@ -297,6 +254,21 @@ MAINTENANCE: Maintained
|
||||
STATUS: Working
|
||||
SINCE: 4.0.2
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: cybercash
|
||||
PRIMARY MAINTAINER: Evan Klinger <evan715@sirius.com>
|
||||
MAINTENANCE: Maintained
|
||||
STATUS: Unknown
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: domxml
|
||||
PRIMARY MAINTAINER: Uwe Steinmann <steinm@php.net>
|
||||
MAINTENANCE: Maintained
|
||||
STATUS: Experimental
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: dotnet
|
||||
PRIMARY MAINTAINER: Sam Ruby <rubys@us.ibm.com>
|
||||
MAINTENANCE: Maintained
|
||||
STATUS: Experimental
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: exif
|
||||
PRIMARY MAINTAINER: Marcus Boerger <helly@php.net>
|
||||
MAINTENANCE: Maintained
|
||||
@@ -308,6 +280,11 @@ PRIMARY MAINTAINER: Uwe Steinmann <steinm@php.net>
|
||||
MAINTENANCE: Maintained
|
||||
STATUS: Unknown
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: fribidi
|
||||
PRIMARY MAINTAINER: Tal Peer <tal@php.net>
|
||||
MAINTENANCE: Maintained
|
||||
STATUS: Working
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: ftp
|
||||
PRIMARY MAINTAINER: Stefan Esser (sesser@php.net)
|
||||
MAINTENANCE: Maintained
|
||||
@@ -327,6 +304,10 @@ MAINTENANCE: Unknown
|
||||
STATUS: Unknown
|
||||
SINCE: 4.0.4
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: icap
|
||||
MAINTENANCE: Unknown
|
||||
STATUS: Obsolete
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: iconv
|
||||
PRIMARY MAINTAINER: Moriyoshi Koizumi <moriyoshi@php.net>
|
||||
MAINTENANCE: Maintained
|
||||
@@ -337,6 +318,11 @@ PRIMARY MAINTAINER: Chuck Hagenbuch <chuck@horde.org>
|
||||
MAINTENANCE: Odd Fixes
|
||||
STATUS: Working
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: java
|
||||
PRIMARY MAINTAINER: Sam Ruby <rubys@us.ibm.com>
|
||||
MAINTENANCE: Maintained
|
||||
STATUS: Working
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: ldap
|
||||
PRIMARY MAINTAINER: Stig Venaas <venaas@php.net>
|
||||
MAINTENANCE: Maintained
|
||||
@@ -347,6 +333,11 @@ PRIMARY MAINTAINER: Rui Hirokawa <hirokawa@php.net>
|
||||
MAINTENANCE: Maintained
|
||||
STATUS: Working
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: mcal
|
||||
PRIMARY MAINTAINER: Chuck Hagenbuch <chuck@horde.org>
|
||||
MAINTENANCE: Odd Fixes
|
||||
STATUS: Working
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: mcrypt
|
||||
PRIMARY MAINTAINER: Derick Rethans <derick@derickrethans.nl>
|
||||
MAINTENANCE: Maintained
|
||||
@@ -357,11 +348,12 @@ PRIMARY MAINTAINER: Sascha Schumann <sascha@schumann.cx>
|
||||
MAINTENANCE: Maintained
|
||||
STATUS: Working
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: msession
|
||||
PRIMARY MAINTAINER Mark L. Woodward mlwmohawk@mohawksoft.com
|
||||
EXTENSION: muscat
|
||||
PRIMARY MAINTAINER: Sam Liddicott <sam@ananova.com>
|
||||
MAINTENANCE: Maintained
|
||||
STATUS: Working/Experimental
|
||||
COMMENT: Tested on Linux, should work on other UNIX platforms. Backend server code can compile under Windows.
|
||||
STATUS: Working
|
||||
SINCE: 4.0.5
|
||||
COMMENT: Not tested against windows, only core API completed, rest under development
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: openssl
|
||||
PRIMARY MAINTAINER: Wez Furlong <wez@php.net>
|
||||
@@ -369,6 +361,11 @@ MAINTENANCE: Maintained
|
||||
STATUS: Experimental
|
||||
SINCE: 4.0.4
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: overload
|
||||
PRIMARY MAINTAINER: Andrei Zmievski <andrei@php.net>
|
||||
MAINTENANCE: Maintained
|
||||
STATUS: Experimental
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: pcre
|
||||
PRIMARY MAINTAINER: Andrei Zmievski <andrei@php.net>
|
||||
MAINTENANCE: Maintained
|
||||
@@ -390,12 +387,24 @@ PRIMARY MAINTAINER: Kristian K
|
||||
MAINTENANCE: Maintained
|
||||
STATUS: Working
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: printer
|
||||
PRIMARY MAINTAINER: Daniel Beulshausen <daniel@php4win.de>
|
||||
MAINTENANCE: Maintained
|
||||
STATUS: Working
|
||||
SINCE: 4.0.4
|
||||
COMMENT: Only for Win32
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: pspell
|
||||
PRIMARY MAINTAINER: Vlad Krupin <phpdevel@echospace.com>
|
||||
MAINTENANCE: Unknown
|
||||
STATUS: Unknown
|
||||
SINCE: 4.0.2
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: qtdom
|
||||
MAINTENANCE: Unknown
|
||||
STATUS: Experimental
|
||||
SINCE: 4.0.4
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: readline
|
||||
MAINTENANCE: Unknown
|
||||
STATUS: Unknown
|
||||
@@ -405,6 +414,18 @@ PRIMARY MAINTAINER: Kristian K
|
||||
MAINTENANCE: Maintained
|
||||
STATUS: Working
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: sablot
|
||||
PRIMARY MAINTAINER: Sterling Hughes <sterling@php.net>
|
||||
MAINTENANCE: Obsolete
|
||||
STATUS: Experimental
|
||||
SINCE: 4.0.3
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: satellite
|
||||
PRIMARY MAINTAINER: David Eriksson <eriksson@php.net>
|
||||
MAINTENANCE: Odd Fixes
|
||||
STATUS: Experimental
|
||||
SINCE: 4.0.3
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: session
|
||||
PRIMARY MAINTAINER: Sascha Schumann <sascha@schumann.cx>
|
||||
MAINTENANCE: Maintained
|
||||
@@ -427,9 +448,11 @@ MAINTENANCE: Maintained
|
||||
STATUS: Experimental
|
||||
SINCE: 4.0.2
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: sysvmsg
|
||||
MAINTENANCE: Unknown
|
||||
STATUS: Unknown
|
||||
EXTENSION: swf
|
||||
PRIMARY MAINTAINER: Sterling Hughes <sterling@php.net>
|
||||
MAINTENANCE: Orphaned
|
||||
STATUS: Deprecated (Use the ming swf extension instead)
|
||||
COMMENT: Only for Unix (won't change)
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: sysvsem
|
||||
MAINTENANCE: Unknown
|
||||
@@ -439,6 +462,26 @@ EXTENSION: sysvshm
|
||||
MAINTENANCE: Unknown
|
||||
STATUS: Working
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: vpopmail
|
||||
MAINTENANCE: Unknown
|
||||
STATUS: Experimental
|
||||
SINCE: 4.0.5
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: wddx
|
||||
PRIMARY MAINTAINER: Andrei Zmievski <andrei@php.net>
|
||||
MAINTENANCE: Maintained
|
||||
STATUS: Working
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: xml
|
||||
PRIMARY MAINTAINER: Thies C. Arntzen <thies@thieso.net>
|
||||
MAINTENANCE: Maintained
|
||||
STATUS: Working
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: xslt
|
||||
PRIMARY MAINTAINER: Hartmut Holzgraefe <hartmut@six.de>
|
||||
MAINTENANCE: Odd Fixes
|
||||
STATUS: Working (mostly)
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: yaz
|
||||
PRIMARY MAINTAINER: Adam Dickmeiss <adam@indexdata.dk>
|
||||
MAINTENANCE: Maintained
|
||||
@@ -454,3 +497,10 @@ PRIMARY MAINTAINER: Stefan Roehrich <sr@linux.de>
|
||||
MAINTENANCE: Maintained
|
||||
STATUS: Working
|
||||
-------------------------------------------------------------------------------
|
||||
EXTENSION: zziplib
|
||||
PRIMARY MAINTAINER: Hartmut Holzgraefe <hartmut@six.de>
|
||||
MAINTENANCE: Odd Fixes
|
||||
STATUS: Working
|
||||
SINCE: 4.0.5
|
||||
-------------------------------------------------------------------------------
|
||||
# iptc?
|
||||
@@ -1,4 +1,4 @@
|
||||
Installation Instructions for PHP 5
|
||||
Installation Instructions for PHP 4
|
||||
-----------------------------------
|
||||
|
||||
STOP!
|
||||
@@ -108,8 +108,8 @@ $ make
|
||||
$ make install
|
||||
|
||||
$ cd ../apache_1.3.x
|
||||
$ ./configure --prefix=/www --activate-module=src/modules/php5/libphp5.a
|
||||
(The above line is correct! Yes, we know libphp5.a does not exist at this
|
||||
$ ./configure --prefix=/www --activate-module=src/modules/php4/libphp4.a
|
||||
(The above line is correct! Yes, we know libphp4.a does not exist at this
|
||||
stage. It isn't supposed to. It will be created.)
|
||||
$ make
|
||||
(you should now have an httpd binary which you can copy to your Apache bin dir if
|
||||
@@ -226,7 +226,7 @@ Installing PHP can be done in four simple steps:
|
||||
3b. Static Module Installation
|
||||
|
||||
For the Apache module version this will copy the appropriate files
|
||||
to the src/modules/php5 directory in your Apache distribution if
|
||||
to the src/modules/php4 directory in your Apache distribution if
|
||||
you are using Apache 1.3.x. If you are still running Apache 1.2.x
|
||||
these files will be copied directly to the main src directory.
|
||||
|
||||
@@ -235,7 +235,7 @@ Installing PHP can be done in four simple steps:
|
||||
|
||||
cd apache_1.3.x
|
||||
./configure --prefix=/<path>/apache \
|
||||
--activate-module=src/modules/php5/libphp5.a
|
||||
--activate-module=src/modules/php4/libphp4.a
|
||||
make
|
||||
make install
|
||||
|
||||
@@ -248,29 +248,29 @@ Installing PHP can be done in four simple steps:
|
||||
|
||||
For Apache 1.3.x add:
|
||||
|
||||
AddModule modules/php5/libphp5.a
|
||||
AddModule modules/php4/libphp4.a
|
||||
|
||||
For Apache 1.3.x don't do anything else. Just add this line and then
|
||||
run "./Configure" followed by "make".
|
||||
|
||||
For Apache 1.2.x add:
|
||||
|
||||
Module php5_module mod_php5.o
|
||||
Module php4_module mod_php4.o
|
||||
|
||||
For Apache 1.2.x you will also have to look in the libphp5.module file,
|
||||
For Apache 1.2.x you will also have to look in the libphp4.module file,
|
||||
which was copied to the src directory. The EXTRA_LIBS line in the Apache
|
||||
Configuration file needs to be set to use the same libs as specified on
|
||||
the LIBS line in libphp5.module. You also need to make sure to add
|
||||
the LIBS line in libphp4.module. You also need to make sure to add
|
||||
"-L." to the beginning of the EXTRA_LIBS line.
|
||||
|
||||
So, as an example, your EXTRA_LIBS line might look like:
|
||||
|
||||
EXTRA_LIBS=-L. -lphp5 -lgdbm -ldb -L/usr/local/mysql/lib -lmysqlclient
|
||||
EXTRA_LIBS=-L. -lphp4 -lgdbm -ldb -L/usr/local/mysql/lib -lmysqlclient
|
||||
|
||||
NOTE: You should not enclose the EXTRA_LIBS line in double-quotes, as it
|
||||
is in the libphp5.module file.
|
||||
is in the libphp4.module file.
|
||||
|
||||
Also, look at the RULE_WANTHSREGEX setting in the libphp5.module file
|
||||
Also, look at the RULE_WANTHSREGEX setting in the libphp4.module file
|
||||
and set the WANTHSREGEX directive accordingly in your Configuration file.
|
||||
This last step applies to versions of Apache prior to 1.3b3.
|
||||
|
||||
@@ -291,17 +291,17 @@ Installing PHP can be done in four simple steps:
|
||||
enable the dynamic PHP module. To verify this, look for a line that
|
||||
looks like this:
|
||||
|
||||
LoadModule php5_module libexec/libphp5.so
|
||||
LoadModule php4_module libexec/libphp4.so
|
||||
|
||||
The actual path before the libphp5.so part might differ slightly. This
|
||||
The actual path before the libphp4.so part might differ slightly. This
|
||||
is likely fine. If you are paranoid you can examine the output from the
|
||||
make install step to see where the libphp5.so file was actually put and
|
||||
make install step to see where the libphp4.so file was actually put and
|
||||
place the full path to this file on this LoadModule line.
|
||||
|
||||
If somewhere in your httpd.conf file you have a ClearModuleList line
|
||||
then you also need this line:
|
||||
|
||||
AddModule mod_php5.c
|
||||
AddModule mod_php4.c
|
||||
|
||||
And finally you need to tell Apache which file extension should trigger
|
||||
PHP. You do this by creating a special mime type and associating it
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
--------------------------------------------------------------------
|
||||
The PHP License, Version 3.0
|
||||
Copyright (c) 1999 - 2003 The PHP Group. All rights reserved.
|
||||
The PHP License, version 3.0
|
||||
Copyright (c) 1999 - 2002 The PHP Group. All rights reserved.
|
||||
--------------------------------------------------------------------
|
||||
|
||||
Redistribution and use in source and binary forms, with or without
|
||||
|
||||
+13
-11
@@ -14,22 +14,22 @@ all: $(all_targets)
|
||||
|
||||
build-modules: $(PHP_MODULES)
|
||||
|
||||
libphp5.la: $(PHP_GLOBAL_OBJS) $(PHP_SAPI_OBJS)
|
||||
libphp4.la: $(PHP_GLOBAL_OBJS) $(PHP_SAPI_OBJS)
|
||||
$(LIBTOOL) --mode=link $(CC) $(CFLAGS) $(EXTRA_CFLAGS) -rpath $(phptempdir) $(EXTRA_LDFLAGS) $(LDFLAGS) $(PHP_RPATHS) $(PHP_GLOBAL_OBJS) $(PHP_SAPI_OBJS) $(EXTRA_LIBS) $(ZEND_EXTRA_LIBS) -o $@
|
||||
-@$(LIBTOOL) --silent --mode=install cp libphp5.la $(phptempdir)/libphp5.la >/dev/null 2>&1
|
||||
-@$(LIBTOOL) --silent --mode=install cp libphp4.la $(phptempdir)/libphp4.la >/dev/null 2>&1
|
||||
|
||||
libs/libphp5.bundle: $(PHP_GLOBAL_OBJS) $(PHP_SAPI_OBJS)
|
||||
$(CC) $(MH_BUNDLE_FLAGS) $(CFLAGS_CLEAN) $(EXTRA_CFLAGS) $(LDFLAGS) $(EXTRA_LDFLAGS) $(PHP_GLOBAL_OBJS:.lo=.o) $(PHP_SAPI_OBJS:.lo=.o) $(PHP_FRAMEWORKS) $(EXTRA_LIBS) $(ZEND_EXTRA_LIBS) -o $@ && cp $@ libs/libphp5.so
|
||||
libs/libphp4.bundle: $(PHP_GLOBAL_OBJS) $(PHP_SAPI_OBJS)
|
||||
$(CC) $(MH_BUNDLE_FLAGS) $(CFLAGS_CLEAN) $(EXTRA_CFLAGS) $(LDFLAGS) $(EXTRA_LDFLAGS) $(PHP_GLOBAL_OBJS:.lo=.o) $(PHP_SAPI_OBJS:.lo=.o) $(PHP_FRAMEWORKS) $(EXTRA_LIBS) $(ZEND_EXTRA_LIBS) -o $@ && cp $@ libs/libphp4.so
|
||||
|
||||
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)/libphp4.$(SHLIB_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)/libphp4.$(SHLIB_SUFFIX_NAME).$$i; then \
|
||||
$(LN_S) $(phptempdir)/libphp4.$(SHLIB_SUFFIX_NAME).$$i $(phptempdir)/libphp4.$(SHLIB_SUFFIX_NAME); \
|
||||
break; \
|
||||
fi; \
|
||||
done; \
|
||||
@@ -61,14 +61,16 @@ test:
|
||||
fi
|
||||
|
||||
clean:
|
||||
find . -name \*.lo -o -name \*.o | xargs rm -f
|
||||
find . -name \*.la -o -name \*.a | xargs rm -f
|
||||
find . -name \*.lo | xargs rm -f
|
||||
find . -name \*.o | xargs rm -f
|
||||
find . -name \*.la | xargs rm -f
|
||||
find . -name \*.a | xargs rm -f
|
||||
find . -name \*.so | xargs rm -f
|
||||
find . -name .libs -a -type d|xargs rm -rf
|
||||
rm -f libphp5.la $(SAPI_CLI_PATH) $(OVERALL_TARGET) modules/* libs/*
|
||||
rm -f libphp4.la $(SAPI_CLI_PATH) $(OVERALL_TARGET) modules/* libs/*
|
||||
|
||||
distclean: clean
|
||||
rm -f config.cache config.log config.status Makefile.objects Makefile.fragments libtool main/php_config.h stamp-h php5.spec sapi/apache/libphp5.module buildmk.stamp
|
||||
rm -f config.cache config.log config.status Makefile.objects Makefile.fragments libtool main/php_config.h stamp-h php4.spec sapi/apache/libphp4.module buildmk.stamp
|
||||
egrep define'.*include/php' configure|sed 's/.*>//'|xargs rm -f
|
||||
find . -name Makefile | xargs rm -f
|
||||
|
||||
|
||||
+1
-6
@@ -1,7 +1,3 @@
|
||||
(NOTE: you may also want to take a look at the pear package
|
||||
PECL_Gen, a PHP-only alternative for this script that
|
||||
supports way more extension writing tasks and is
|
||||
supposed to replace ext_skel completely in the long run ...)
|
||||
|
||||
WHAT IT IS
|
||||
|
||||
@@ -21,8 +17,7 @@ HOW TO USE IT
|
||||
|
||||
[ Note that GNU awk is likely required for this script to work. Debian
|
||||
systems seem to default to using mawk, so you may need to change the
|
||||
#! line in skeleton/create_stubs and the cat $proto | awk line in
|
||||
ext_skel to use gawk explicitly. ]
|
||||
#! line in skeleton/create_stubs to use gawk explicitly. ]
|
||||
|
||||
If you don't need to test the existence of any external header files,
|
||||
libraries or functions in them, the module is already almost ready to be
|
||||
|
||||
@@ -42,14 +42,14 @@ Type specifiers
|
||||
z - the actual zval
|
||||
|
||||
The following characters also have a meaning in the specifier string:
|
||||
| - indicates that the remaining parameters are optional, they
|
||||
should be initialized to default values by the extension since they
|
||||
will not be touched by the parsing function if they are not
|
||||
passed to it.
|
||||
/ - use SEPARATE_ZVAL_IF_NOT_REF() on the parameter it follows
|
||||
! - the parameter it follows can be of specified type or NULL (only applies
|
||||
to 'a', 'o', 'O', 'r', and 'z'). If NULL is passed, the results
|
||||
pointer is set to NULL as well.
|
||||
| - indicates that the remaining parameters are optional, they
|
||||
should be initialized to default values by the extension since they
|
||||
will not be touched by the parsing function if they are not
|
||||
passed to it.
|
||||
/ - use SEPARATE_ZVAL_IF_NOT_REF() on the parameter it follows
|
||||
! - the parameter it follows can be of specified type or NULL (only applies
|
||||
to 'a', 'o', 'O', 'r', and 'z'). If NULL is passed, the results
|
||||
pointer is set to NULL as well.
|
||||
|
||||
Examples
|
||||
--------
|
||||
|
||||
@@ -1,41 +0,0 @@
|
||||
1. strrpos() and strripos() now use the entire string as a needle.
|
||||
Be aware that the existing scripts may no longer work as you expect.
|
||||
|
||||
EX :
|
||||
<?php
|
||||
var_dump(strrpos("ABCDEF","DEF"));
|
||||
var_dump(strrpos("ABCDEF","DAF"));
|
||||
?>
|
||||
|
||||
Will give you different results. The former returns 3 while the latter
|
||||
returns false rather than the position of the last occurrence of 'D'.
|
||||
The same applies to strripos().
|
||||
|
||||
2. Illegal use of string offsets causes E_ERROR instead of E_WARNING.
|
||||
|
||||
EX :
|
||||
<?php
|
||||
$a = "foo";
|
||||
unset($a[0][1][2]);
|
||||
?>
|
||||
|
||||
Fatal error: Cannot use string offset as an array in ... on line 1
|
||||
|
||||
3. array_merge() was changed to accept only arrays. If a non-array variable is
|
||||
passed, a E_WARNING will be thrown for every such parameter. Be careful
|
||||
because your code may start emitting E_WARNING out of the blue.
|
||||
|
||||
4. Be careful when porting from ext/mysql to ext/mysqli. The following
|
||||
functions return NULL when no more data is available in the result set
|
||||
(ext/mysql's functions return FALSE).
|
||||
|
||||
- mysqli_fetch_row()
|
||||
- mysqli_fetch_array()
|
||||
- mysqli_fetch_assoc()
|
||||
|
||||
5. PATH_TRANSLATED server variable is no longer set implicitly under
|
||||
Apache2 SAPI in contrast to the situation in PHP4, where it is set to the
|
||||
same value as the SCRIPT_FILENAME server variable when it is not populated
|
||||
by Apache. This change was made to comply with the CGI specification.
|
||||
Please refer to bug #23610 for further information.
|
||||
|
||||
+1
-7
@@ -37,10 +37,9 @@ PHPAPI int php_stream_close(php_stream * stream);
|
||||
PHPAPI int php_stream_flush(php_stream * stream);
|
||||
PHPAPI int php_stream_seek(php_stream * stream, off_t offset, int whence);
|
||||
PHPAPI off_t php_stream_tell(php_stream * stream);
|
||||
PHPAPI int php_stream_lock(php_stream * stream, int mode);
|
||||
|
||||
These (should) behave in the same way as the ANSI stdio functions with similar
|
||||
names: fread, fwrite, fprintf, feof, fgetc, fgets, fclose, fflush, fseek, ftell, flock.
|
||||
names: fread, fwrite, fprintf, feof, fgetc, fgets, fclose, fflush, fseek, ftell.
|
||||
|
||||
Opening Streams
|
||||
===============
|
||||
@@ -158,11 +157,6 @@ can lead to a crash when the resource is later used/released.
|
||||
NOTE: If you are opening a stream and need it to be seekable, use the
|
||||
STREAM_MUST_SEEK option to php_stream_open_wrapper();
|
||||
|
||||
PHPAPI int php_stream_supports_lock(php_stream * stream);
|
||||
|
||||
This function will return either 1 (success) or 0 (failure) indicating whether or
|
||||
not a lock can be set on this stream. Typically you can only set locks on stdio streams.
|
||||
|
||||
Casting Streams
|
||||
===============
|
||||
What if your extension needs to access the FILE* of a user level file pointer?
|
||||
|
||||
@@ -123,4 +123,5 @@ commit log. If your patch affects end-users, a brief description
|
||||
and your name might be added to the NEWS file.
|
||||
|
||||
|
||||
|
||||
Thank you for submitting patch for PHP!
|
||||
+141
-4
@@ -1,6 +1,6 @@
|
||||
[IMPORTANT NOTICE]
|
||||
------------------
|
||||
Please do not ask developers why some or all tests are failing in
|
||||
Do _not_ ask to developers why some or all tests are failed under
|
||||
your environment! Let us know if you find why it fails. Thank you.
|
||||
|
||||
|
||||
@@ -108,7 +108,7 @@ Example script to be run by cron(1):
|
||||
========== qa-test.sh =============
|
||||
#!/bin/sh
|
||||
|
||||
CO_DIR=$HOME/cvs/php5
|
||||
CO_DIR=$HOME/cvs/php4
|
||||
MYMAIL=qa-test@domain.com
|
||||
TMPDIR=/var/tmp
|
||||
TODAY=`date +"%Y%m%d"`
|
||||
@@ -119,7 +119,7 @@ export MAKE=gmake
|
||||
export CC=gcc
|
||||
|
||||
# Set test environment
|
||||
export NO_INTERACTION=1
|
||||
export NO_INTERACTIVITY=1
|
||||
export REPORT_EXIT_STATUS=1
|
||||
|
||||
cd $CO_DIR
|
||||
@@ -141,8 +141,145 @@ advised to test for non-zero, rather then a specific value.
|
||||
[Creating new test files]
|
||||
-------------------------
|
||||
Writing test file is very easy if you are used to PHP.
|
||||
See the HOWTO at http://qa.php.net/write-test.php
|
||||
|
||||
Here is an actual test file from standard module.
|
||||
|
||||
===== ext/standard/tests/strings/strtr.phpt =======
|
||||
--TEST--
|
||||
strtr() function
|
||||
--FILE--
|
||||
<?php
|
||||
/* Do not change this test it is a REATME.TESTING example. */
|
||||
$trans = array("hello"=>"hi", "hi"=>"hello", "a"=>"A", "world"=>"planet");
|
||||
var_dump(strtr("# hi all, I said hello world! #", $trans));
|
||||
?>
|
||||
--EXPECT--
|
||||
string(32) "# hello All, I sAid hi planet! #"
|
||||
===== ext/standard/tests/strings/strtr.phpt =======
|
||||
|
||||
As you can see the file is devided into several sections. Below is a
|
||||
list of all possible sections:
|
||||
|
||||
"--TEST--" is title of the test (required).
|
||||
"--SKIPIF--" is condition when to skip this test (optional).
|
||||
"--POST--" is POST variable passed to test script (optional).
|
||||
"--GET--" is GET variable passed to test script (optional).
|
||||
"--INI--" each line contains an ini setting e.g. foo=bar (optional).
|
||||
"--FILE--" is the test script (required).
|
||||
"--EXPECT--" is the expected output from the test script (required).
|
||||
"--EXPECTF--" is an alternative of --EXPECT--. The difference is that
|
||||
this form uses sscanf for output validation (alternative).
|
||||
"--EXPECTREGEX--" is an alternative of --EXPECT--. This form allows the tester
|
||||
to specify the result in a regular expression (alternative).
|
||||
|
||||
A test must at least contain the sections TEST, FILE and either EXPECT
|
||||
or EXPECTF. When a test is called run-test.php takes the name from the
|
||||
TEST section and writes the FILE section into a ".php" file with the
|
||||
same name as the ".phpt" file. This ".php" file will then be executed
|
||||
and its output compared to the contents of the EXPECT section. It is a
|
||||
good idea to generate output with var_dump() calls.
|
||||
|
||||
/ext/standard/tests/strings/str_shuffle.phpt is a good example for using
|
||||
EXPECTF instead of EXPECT. From time to time the algorithm used for shuffle
|
||||
changed and sometimes the machine used to execute the code has influence
|
||||
on the result of shuffle. But it always returns a three character string
|
||||
detectable by %s. Other scan-able forms are %i for integers, %d for numbers
|
||||
only, %f for floating point values, %c for single characters and %x for
|
||||
hexadecimal values.
|
||||
|
||||
==== /ext/standard/tests/strings/str_shuffle.phpt ===
|
||||
--TEST--
|
||||
Testing str_shuffle.
|
||||
--FILE--
|
||||
<?php
|
||||
/* Do not change this test it is a REATME.TESTING example. */
|
||||
$s = '123';
|
||||
var_dump(str_shuffle($s));
|
||||
var_dump($s);
|
||||
?>
|
||||
--EXPECTF--
|
||||
string(3) %s
|
||||
string(3) "123"
|
||||
==== end of /ext/standard/tests/strings/str_shuffle.phpt ===
|
||||
|
||||
/ext/standard/tests/strings/strings001.phpt is a good example for using
|
||||
EXPECTREGEX instead of EXPECT. This test also shows that in EXPECTREGEX
|
||||
some characters need to be escaped since otherwise they would be
|
||||
interpreted as a regular expression.
|
||||
|
||||
==== /ext/standard/tests/strings/strings001.phpt ===
|
||||
--TEST--
|
||||
Test whether strstr() and strrchr() are binary safe.
|
||||
--FILE--
|
||||
<?php
|
||||
/* Do not change this test it is a REATME.TESTING example. */
|
||||
$s = "alabala nica".chr(0)."turska panica";
|
||||
var_dump(strstr($s, "nic"));
|
||||
var_dump(strrchr($s," nic"));
|
||||
?>
|
||||
--EXPECTREGEX--
|
||||
string\(18\) \"nica\x00turska panica\"
|
||||
string\(19\) \" nica\x00turska panica\"
|
||||
==== end of /ext/standard/tests/strings/strings001.phpt ===
|
||||
|
||||
Some tests depend on modules or functions available only in certain versions
|
||||
or they even require minimum version of php or zend. These tests should be
|
||||
skipped when the requirement cannot be fullfilled. To achieve this you can
|
||||
use the SKIPIF section. To tell run-test.php that your test should be skipped
|
||||
the SKIPIF section must print out the word "skip" followed by a reason why
|
||||
the test should skip.
|
||||
|
||||
==== /ext/exif/tests/exif005.phpt ===
|
||||
--TEST--
|
||||
Check for exif_read_data, unusual IFD start
|
||||
--SKIPIF--
|
||||
<?php
|
||||
if (!extension_loaded('exif')) print 'skip exif extension not available';
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
/* Do not change this test it is a REATME.TESTING example.
|
||||
* test5.jpg is a 1*1 image that contains an Exif section with ifd = 00000009h
|
||||
*/
|
||||
$image = exif_read_data('./ext/exif/tests/test5.jpg','',true,false);
|
||||
var_dump($image['IFD0']);
|
||||
?>
|
||||
--EXPECT--
|
||||
array(2) {
|
||||
["ImageDescription"]=>
|
||||
string(11) "Ifd00000009"
|
||||
["DateTime"]=>
|
||||
string(19) "2002:10:18 20:06:00"
|
||||
}
|
||||
==== end of /ext/exif/tests/exif005.phpt ===
|
||||
|
||||
Test script and SKIPIF code should be directly written into *.phpt. However,
|
||||
it is recommended to use include files when more test scripts depend on the
|
||||
same SKIPIF code or when certain test files need the same values for some
|
||||
input. But no file used by any test should have one of the following
|
||||
extensions: ".php", ".log", ".exp", ".out" or ".diff".
|
||||
|
||||
Tests should be named according to the following list:
|
||||
|
||||
Class: Name: Example:
|
||||
Tests for bugs bug<bugid>.phpt bug17123.phpt
|
||||
Tests for functions <functionname>.phpt dba_open.phpt
|
||||
General tests for extensions <extname><no>.phpt dba3.phpt
|
||||
|
||||
When you use an include file for the SKIPIF section it should be named
|
||||
"skipif.inc" and an include file used in the FILE section of many tests
|
||||
should be named "test.inc".
|
||||
|
||||
NOTE: All tests should run correctly with error_reporting(E_ALL) and
|
||||
display_errors=1. This is the default when called from run-test.php.
|
||||
If you have a good reason for lowering the error reporting, use --INI--
|
||||
section and comment this in your testcode.
|
||||
|
||||
NOTE: If your test intentionally generates a PHP warning message use
|
||||
$php_errormsg variable, which you can then output. This will result
|
||||
in a consistent error message output across all platforms and PHP
|
||||
configurations, preventing your test from failing due inconsistencies
|
||||
in the error message content.
|
||||
|
||||
[How to help us]
|
||||
----------------
|
||||
|
||||
-137
@@ -1,137 +0,0 @@
|
||||
[IMPORTANT NOTICE]
|
||||
------------------
|
||||
This is an addendum to README.TESTING with additional information
|
||||
specific to run-tests2.php.
|
||||
|
||||
run-tests2.php is backward compatible with tests developed for
|
||||
the original run-tests.php script. run-tests2 is *not* used by
|
||||
'make test'. run-tests2 was developed to provide support for
|
||||
testing PHP under it's primary environment, HTTP, and can run the
|
||||
PHP tests under any of the SAPI modules that are direct executables,
|
||||
or are accessable via HTTP.
|
||||
|
||||
[New features]
|
||||
----------------
|
||||
* Command line interface:
|
||||
You can run 'php run-tests2.php -h' to get all the possible options.
|
||||
* Configuration file:
|
||||
the -c argument will allow you to use a configuration file. This is
|
||||
handy if you are testing multiple environments and need various options
|
||||
depending on the environment.
|
||||
see run-tests-config.php for details.
|
||||
* CGI Emulation:
|
||||
Will emulate a CGI environment when testing with the cgi sapi executable.
|
||||
* HTTP testing:
|
||||
can be configured to run test scripts through an HTTP server running
|
||||
on localhost. localhost is required since either the web server must
|
||||
alias a directory to the php source directory, or the test scripts
|
||||
must be copied to a directory under the web server
|
||||
(see config options TEST_WEB_BASE_URL, TEST_BASE_PATH, and TEST_WEB_EXT)
|
||||
* New sections supported for test files (see below)
|
||||
|
||||
When running tests over http, tests that require ini settings different that what
|
||||
the web server runs under will be skipped. Since the test harness defines a number
|
||||
of ini settings by default, the web server may require special configuration to
|
||||
make testing work.
|
||||
|
||||
[Example Usage]
|
||||
----------------
|
||||
Some (but not all!) examples of usage:
|
||||
|
||||
1. run tests from the php source directory
|
||||
php run-tests2.php -p /path/to/php-cli
|
||||
|
||||
2. run tests using cgi emulation
|
||||
php run-tests2.php -p /path/to/php-cgi
|
||||
|
||||
3. run tests over http, copying test files into document root
|
||||
php run-tests2.php -w -u http://localhost/test -m /path/to/htdocs/test
|
||||
|
||||
4. run tests over http, php sources have been aliased in web server
|
||||
php run-tests2.php -w -u http://localhost/test
|
||||
|
||||
5. run tests using configuration file
|
||||
php run-tests2.php -c /path/to/run-tests-config.php
|
||||
|
||||
6. run tests using configuration file, but overriding some settings:
|
||||
(config file must be first)
|
||||
php run-tests2.php -c /path/to/run-tests-config.php -w -t 3 -d /path/to/testdir
|
||||
|
||||
NOTE: configuration as described in README.TESTING still works.
|
||||
|
||||
[New Test Sections]
|
||||
----------------
|
||||
In addition to the traditional test sections
|
||||
(see http://qa.php.net/write-test.php), several new sections are available
|
||||
under run-tests2.
|
||||
|
||||
--POST--
|
||||
This is not a new section, but not multipart posts are supported for testing
|
||||
file uploads, or other types of POST data.
|
||||
|
||||
--CGI--
|
||||
This section takes no value. It merely provides a simple marker for tests
|
||||
that MUST be run as CGI, even if there is no --POST-- or --GET-- sections
|
||||
in the test file.
|
||||
|
||||
--DESCRIPTION--
|
||||
Not used for anything, just a section for documenting the test
|
||||
|
||||
--ENV--
|
||||
This section get's eval()'d to help build an environment for the
|
||||
execution of the test. This can be used to change environment
|
||||
vars that are used for CGI emulation, or simply to set env vars
|
||||
for cli testing. A full example looks like:
|
||||
|
||||
--ENV--
|
||||
return <<<END
|
||||
PATH_TRANSLATED=$filename
|
||||
PATH_INFO=$scriptname
|
||||
SCRIPT_NAME=$scriptname
|
||||
END;
|
||||
|
||||
Some variables are made easily available for use in this section, they
|
||||
include:
|
||||
$filename full native path to file, will become PATH_TRANSLATED
|
||||
$filepath =dirname($filename)
|
||||
$scriptname this is what will become SCRIPT_NAME unless you override it
|
||||
$docroot the equivelant of DOCUMENT_ROOT under Apache
|
||||
$cwd the directory that the test is being initiated from
|
||||
$this->conf all run-tests2 configuration vars
|
||||
$this->env all environment variables that will get passed to the test
|
||||
|
||||
|
||||
--REQUEST--
|
||||
This section is also eval'd, and is similar in nature to --ENV--. However,
|
||||
this section is used to build the url used in an HTTP request. Valid values
|
||||
to set in this section would include:
|
||||
SCRIPT_NAME The inital part of the request url
|
||||
PATH_INFO The pathinfo part of a request url
|
||||
FRAGMENT The fragment section of a url (after #)
|
||||
QUERY_STRING The query part of a url (after ?)
|
||||
|
||||
--REQUEST--
|
||||
return <<<END
|
||||
PATH_INFO=/path/info
|
||||
END;
|
||||
|
||||
--HEADERS--
|
||||
This section is also eval'd. It is used to provide additional headers sent
|
||||
in an HTTP request, such as content type for multipart posts, cookies, etc.
|
||||
|
||||
--HEADERS--
|
||||
return <<<END
|
||||
Content-Type=multipart/form-data; boundary=---------------------------240723202011929
|
||||
Content-Length=100
|
||||
END;
|
||||
|
||||
--EXPECTHEADERS--
|
||||
This section can be used to define what headers are required to be
|
||||
received back from a request, and is checked in addition to the
|
||||
regular expect sections. For example:
|
||||
|
||||
--EXPECTHEADERS--
|
||||
Status: 404
|
||||
|
||||
|
||||
|
||||
@@ -108,7 +108,7 @@ module, program, etc).
|
||||
|
||||
For example for APXS:
|
||||
|
||||
PHP_SELECT_SAPI(apache, shared, sapi_apache.c mod_php5.c php_apache.c)
|
||||
PHP_SELECT_SAPI(apache, shared, sapi_apache.c mod_php4.c php_apache.c)
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -1,163 +0,0 @@
|
||||
The Win32 Build System.
|
||||
$Id$
|
||||
Wez Furlong <wez@thebrainroom.com>
|
||||
|
||||
NB: Please don't mail me asking for help on this, unless
|
||||
you are a Core PHP developer, or you are prepared to donate
|
||||
some money via paypal or buy me something from my wishlist.
|
||||
http://pecl.php.net/user/wez
|
||||
Thanks :-)
|
||||
|
||||
===========================================================
|
||||
Contents:
|
||||
1. How to build PHP under windows
|
||||
a. Requirements
|
||||
b. Opening a command prompt
|
||||
c. Generating configure.js
|
||||
d. Configuring
|
||||
e. Building
|
||||
f. Cleaning up
|
||||
g. Running the test suite
|
||||
|
||||
2. How to write config.w32 files
|
||||
x. to be written.
|
||||
|
||||
===========================================================
|
||||
1. How to build PHP under windows
|
||||
a. Requirements
|
||||
|
||||
You need:
|
||||
- Windows Scripting Host (cscript.exe)
|
||||
- Microsoft Build Tools from either:
|
||||
Microsoft Visual Studio (VC6) or later
|
||||
Microsoft Platform SDK
|
||||
|
||||
You also need:
|
||||
- bindlib_w32 [http://www.php.net/extra/bindlib_w32.zip]
|
||||
- win32build [http://www.php.net/extra/win32build.zip]
|
||||
|
||||
b. Opening the Build Environment Command Prompt:
|
||||
- Using Visual Studio (VC6)
|
||||
1. Install it
|
||||
2. If you have a VC++ Command Prompt icon on your start menu,
|
||||
click on it to get a Command Prompt with the env vars
|
||||
set up correctly.
|
||||
|
||||
If not, create a new shortcut and set the Target to:
|
||||
|
||||
%comspec% /k "C:\Program Files\Microsoft Visual Studio\VC98\Bin\vcvars32.bat"
|
||||
|
||||
You might also want to set the prompt to start in
|
||||
a convenient location (such as the root of your
|
||||
PHP source checkout).
|
||||
|
||||
- Using Visual Studio .Net
|
||||
1. Install it.
|
||||
2. Under the Visual Studio .Net Tools sub menu of your start
|
||||
menu, you should have a Visual Studio .Net Command Prompt
|
||||
icon. If not, create a new shortcut and set the Target to:
|
||||
|
||||
%comspec% /k "C:\Program Files\Microsoft Visual Studio .NET 2003\Common7\Tools\vsvars32.bat"
|
||||
|
||||
You might also want to set the prompt to start in
|
||||
a convenient location (such as the root of your
|
||||
PHP source checkout).
|
||||
|
||||
- Using the Platform SDK tools
|
||||
1. Download the Platform SDK:
|
||||
http://www.microsoft.com/msdownload/platformsdk/sdkupdate/
|
||||
|
||||
- You need the Core SDK, which is approx 200MB to download
|
||||
and requires approx 500MB of disk space.
|
||||
- The other components of the SDK are not required by PHP
|
||||
- You might be able to reduce the download size by downloading
|
||||
the installer control component first and then selecting
|
||||
only the Build Environment (around 30MB), but I haven't
|
||||
tried this.
|
||||
|
||||
** Note: it seems that MS don't include the 32 bit
|
||||
build tools in the platform SDK any longer, so
|
||||
you will probably have very limited luck if you
|
||||
don't also have VC++ or VS.Net already installed.
|
||||
|
||||
2. Once installed, you will have an icon on your start menu
|
||||
that will launch the build environment; the latest SDK's
|
||||
install a number of different versions of this; you probably
|
||||
want to choose the Windows 2000 Retail build environment.
|
||||
Clicking on this will open a command prompt with its Path,
|
||||
Include and Lib env vars set to point to the build tools
|
||||
and win32 headers.
|
||||
|
||||
c. Generating configure
|
||||
|
||||
Change directory to where you have your PHP 5 sources.
|
||||
Run buildconf.bat.
|
||||
|
||||
d. Configuring
|
||||
|
||||
cscript /nologo configure.js --help
|
||||
|
||||
Will give you a list of configuration options; these will
|
||||
have the form:
|
||||
|
||||
--enable-foo or --disable-foo or --with-foo or --without-foo.
|
||||
|
||||
--enable-foo will turn something on, and is equivalent to
|
||||
specifying --enable-foo=yes
|
||||
|
||||
--disable-foo will turn something off, and is equivalent to
|
||||
specifying --enable-foo=no
|
||||
|
||||
--enable-foo=shared will attempt to build that feature as
|
||||
a shared, dynamically loadable module.
|
||||
|
||||
Sometimes a configure option needs additional information
|
||||
about where to find headers and libraries; quite often
|
||||
you can specify --enable-foo=option where option could be
|
||||
the path to where to find those files. If you want to
|
||||
specify a parameter and build it as shared, you can use
|
||||
this syntax instead: --enable-foo=shared,option
|
||||
|
||||
The same rules all apply to --with-foo and --without-foo;
|
||||
the only difference is the way the options are named;
|
||||
the convention is that --enable-foo means that you are
|
||||
switching on something that comes with PHP, whereas
|
||||
--with-foo means that you want to build in something
|
||||
external to PHP.
|
||||
|
||||
e. Building
|
||||
|
||||
Once you have successfully configured your build (make
|
||||
sure you read the output from the command to make sure
|
||||
it worked correctly), you can build the code; simply type
|
||||
|
||||
"nmake" at the command prompt, and it will build everthing
|
||||
you asked for.
|
||||
|
||||
Once the build has completed, you will find your binaries
|
||||
in the build dir determined by configure; this is typically
|
||||
Release_TS for release builds or Debug_TS for debug builds.
|
||||
If you build a non-thread-safe build, it will use Release
|
||||
or Debug to store the files. Also in this build dir you
|
||||
will find sub directories for each module that went into
|
||||
your PHP build. The files you'll want to keep are the
|
||||
.exe and .dll files directly in your build dir.
|
||||
|
||||
f. Cleaning Up
|
||||
|
||||
You can automatically delete everything that was built
|
||||
by running "nmake clean". This will delete everything
|
||||
that was put there when you ran nmake, including the
|
||||
.exe and .dll files.
|
||||
|
||||
g. Running the test suite
|
||||
|
||||
You can verify that your build is working well by running
|
||||
the regression test suite. You do this by typing
|
||||
"nmake test". You can specify the tests you want to run
|
||||
by defing the TESTS variable - if you wanted to run the
|
||||
sqlite test suite only, you would type
|
||||
"nmake /D TESTS=ext/sqlite/tests test"
|
||||
|
||||
vim:tw=78:sw=1:ts=1:et
|
||||
|
||||
+24
-10
@@ -21,13 +21,29 @@ If you have any problems, please check the support site for more
|
||||
up-to-date information and advice.
|
||||
|
||||
|
||||
Quick guide to installing CGI/FastCGI with Zeus
|
||||
-----------------------------------------------
|
||||
Quick guide to installing FastCGI with Zeus
|
||||
-------------------------------------------
|
||||
|
||||
Step 1 - Compile PHP as FastCGI.
|
||||
Step 1 - obtain and install FastCGI development kit.
|
||||
|
||||
Grab the package from:
|
||||
http://www.fastcgi.com/dist/devkit_2.2.0.tar.gz
|
||||
|
||||
Extract the package and follow the instructions:
|
||||
./configure
|
||||
make
|
||||
make export
|
||||
(run the last as root)
|
||||
|
||||
This will install to /usr/local/lib/libfcgi.a
|
||||
and /usr/local/include/*fcgi*
|
||||
|
||||
|
||||
|
||||
Step 2 - Compile PHP as FastCGI.
|
||||
|
||||
Compile as follows:
|
||||
./configure --enable-fastcgi
|
||||
./configure --with-fastcgi
|
||||
make
|
||||
|
||||
Note that PHP has many options to the configure script -
|
||||
@@ -39,7 +55,7 @@ program called 'php'. Copy this into your document root, under a
|
||||
dedicated FastCGI directory (e.g. $DOCROOT/fcgi-bin/php)
|
||||
|
||||
|
||||
Step 2 - configure Zeus
|
||||
Step 3 - configure Zeus
|
||||
|
||||
Four stages:
|
||||
- enable FastCGI
|
||||
@@ -82,7 +98,7 @@ Click 'update' to commit these changes
|
||||
Finally restart your virtual server for these changes to take effect.
|
||||
|
||||
|
||||
Step 3 - start PHP as a FastCGI runner
|
||||
Step 4 - start PHP as a FastCGI runner
|
||||
|
||||
When you start PHP, it will pre-fork a given number of child processes
|
||||
to handle incoming PHP requests. Each process will handle a given
|
||||
@@ -90,10 +106,8 @@ number of requests before exiting (and being replaced by a newly
|
||||
forked process). You can control these two parameters by setting the
|
||||
following environment variables BEFORE starting the FastCGI runner:
|
||||
|
||||
PHP_FCGI_CHILDREN - the number of child processes to pre-fork. This
|
||||
variable MUST be set, if not then the PHP will not run as a FastCGI.
|
||||
We recommend a value of 8 for a fairly busy site. If you have many,
|
||||
long-running PHP scripts, then you may need to increase this further.
|
||||
PHP_FCGI_CHILDREN - the number of child processes to pre-fork. If not
|
||||
set, defaults to 8.
|
||||
|
||||
PHP_FCGI_MAX_REQUESTS - the number of requests each PHP child process
|
||||
handles before exiting. If not set, defaults to 500.
|
||||
|
||||
@@ -1,193 +0,0 @@
|
||||
Input Filter Support in PHP5
|
||||
----------------------------
|
||||
|
||||
XSS (Cross Site Scripting) hacks are becoming more and more prevalent,
|
||||
and can be quite difficult to prevent. Whenever you accept user data
|
||||
and somehow display this data back to users, you are likely vulnerable
|
||||
to XSS hacks.
|
||||
|
||||
The Input Filter support in PHP5 is aimed at providing the framework
|
||||
through which a company-wide or site-wide security policy can be
|
||||
enforced. It is implemented as a SAPI hook and is called from the
|
||||
treat_data and post handler functions. To implement your own security
|
||||
policy you will need to write a standard PHP extension.
|
||||
|
||||
A simple implementation might look like the following. This stores the
|
||||
original raw user data and adds a my_get_raw() function while the normal
|
||||
$_POST, $_GET and $_COOKIE arrays are only populated with stripped
|
||||
data. In this simple example all I am doing is calling strip_tags() on
|
||||
the data. If register_globals is turned on, the default globals that
|
||||
are created will be stripped ($foo) while a $RAW_foo is created with the
|
||||
original user input.
|
||||
|
||||
ZEND_BEGIN_MODULE_GLOBALS(my_input_filter)
|
||||
zval *post_array;
|
||||
zval *get_array;
|
||||
zval *cookie_array;
|
||||
ZEND_END_MODULE_GLOBALS(my_input_filter)
|
||||
|
||||
#ifdef ZTS
|
||||
#define IF_G(v) TSRMG(my_input_filter_globals_id, zend_my_input_filter_globals *, v)
|
||||
#else
|
||||
#define IF_G(v) (my_input_filter_globals.v)
|
||||
#endif
|
||||
|
||||
ZEND_DECLARE_MODULE_GLOBALS(my_input_filter)
|
||||
|
||||
function_entry my_input_filter_functions[] = {
|
||||
PHP_FE(my_get_raw, NULL)
|
||||
{NULL, NULL, NULL}
|
||||
};
|
||||
|
||||
zend_module_entry my_input_filter_module_entry = {
|
||||
STANDARD_MODULE_HEADER,
|
||||
"my_input_filter",
|
||||
my_input_filter_functions,
|
||||
PHP_MINIT(my_input_filter),
|
||||
PHP_MSHUTDOWN(my_input_filter),
|
||||
NULL,
|
||||
PHP_RSHUTDOWN(my_input_filter),
|
||||
PHP_MINFO(my_input_filter),
|
||||
"0.1",
|
||||
STANDARD_MODULE_PROPERTIES
|
||||
};
|
||||
|
||||
PHP_MINIT_FUNCTION(my_input_filter)
|
||||
{
|
||||
ZEND_INIT_MODULE_GLOBALS(my_input_filter, php_my_input_filter_init_globals, NULL);
|
||||
|
||||
REGISTER_LONG_CONSTANT("POST", PARSE_POST, CONST_CS | CONST_PERSISTENT);
|
||||
REGISTER_LONG_CONSTANT("GET", PARSE_GET, CONST_CS | CONST_PERSISTENT);
|
||||
REGISTER_LONG_CONSTANT("COOKIE", PARSE_COOKIE, CONST_CS | CONST_PERSISTENT);
|
||||
|
||||
sapi_register_input_filter(my_sapi_input_filter);
|
||||
return SUCCESS;
|
||||
}
|
||||
|
||||
PHP_RSHUTDOWN_FUNCTION(my_input_filter)
|
||||
{
|
||||
if(IF_G(get_array)) {
|
||||
zval_ptr_dtor(&IF_G(get_array));
|
||||
IF_G(get_array) = NULL;
|
||||
}
|
||||
if(IF_G(post_array)) {
|
||||
zval_ptr_dtor(&IF_G(post_array));
|
||||
IF_G(post_array) = NULL;
|
||||
}
|
||||
if(IF_G(cookie_array)) {
|
||||
zval_ptr_dtor(&IF_G(cookie_array));
|
||||
IF_G(cookie_array) = NULL;
|
||||
}
|
||||
return SUCCESS;
|
||||
}
|
||||
|
||||
PHP_MINFO_FUNCTION(my_input_filter)
|
||||
{
|
||||
php_info_print_table_start();
|
||||
php_info_print_table_row( 2, "My Input Filter Support", "enabled" );
|
||||
php_info_print_table_row( 2, "Revision", "$Revision$");
|
||||
php_info_print_table_end();
|
||||
}
|
||||
|
||||
/* The filter handler. If you return 1 from it, then PHP also registers the
|
||||
* (modified) variable. Returning 0 prevents PHP from registering the variable;
|
||||
* you can use this if your filter already registers the variable under a
|
||||
* different name, or if you just don't want the variable registered at all. */
|
||||
SAPI_INPUT_FILTER_FUNC(my_sapi_input_filter)
|
||||
{
|
||||
zval new_var;
|
||||
zval *array_ptr = NULL;
|
||||
char *raw_var;
|
||||
int var_len;
|
||||
|
||||
assert(*val != NULL);
|
||||
|
||||
switch(arg) {
|
||||
case PARSE_GET:
|
||||
if(!IF_G(get_array)) {
|
||||
ALLOC_ZVAL(array_ptr);
|
||||
array_init(array_ptr);
|
||||
INIT_PZVAL(array_ptr);
|
||||
}
|
||||
IF_G(get_array) = array_ptr;
|
||||
break;
|
||||
case PARSE_POST:
|
||||
if(!IF_G(post_array)) {
|
||||
ALLOC_ZVAL(array_ptr);
|
||||
array_init(array_ptr);
|
||||
INIT_PZVAL(array_ptr);
|
||||
}
|
||||
IF_G(post_array) = array_ptr;
|
||||
break;
|
||||
case PARSE_COOKIE:
|
||||
if(!IF_G(cookie_array)) {
|
||||
ALLOC_ZVAL(array_ptr);
|
||||
array_init(array_ptr);
|
||||
INIT_PZVAL(array_ptr);
|
||||
}
|
||||
IF_G(cookie_array) = array_ptr;
|
||||
break;
|
||||
}
|
||||
Z_STRLEN(new_var) = val_len;
|
||||
Z_STRVAL(new_var) = estrndup(*val, val_len);
|
||||
Z_TYPE(new_var) = IS_STRING;
|
||||
|
||||
var_len = strlen(var);
|
||||
raw_var = emalloc(var_len+5); /* RAW_ and a \0 */
|
||||
strcpy(raw_var, "RAW_");
|
||||
strlcat(raw_var,var,var_len+5);
|
||||
|
||||
php_register_variable_ex(raw_var, &new_var, array_ptr TSRMLS_DC);
|
||||
|
||||
php_strip_tags(*val, val_len, NULL, NULL, 0);
|
||||
|
||||
*new_val_len = strlen(*val);
|
||||
return 1;
|
||||
}
|
||||
|
||||
PHP_FUNCTION(my_get_raw)
|
||||
{
|
||||
long arg;
|
||||
char *var;
|
||||
int var_len;
|
||||
zval **tmp;
|
||||
zval *array_ptr = NULL;
|
||||
HashTable *hash_ptr;
|
||||
char *raw_var;
|
||||
|
||||
if(zend_parse_parameters(2 TSRMLS_CC, "ls|l", &arg, &var, &var_len) == FAILURE) {
|
||||
return;
|
||||
}
|
||||
|
||||
switch(arg) {
|
||||
case PARSE_GET:
|
||||
array_ptr = IF_G(get_array);
|
||||
break;
|
||||
case PARSE_POST:
|
||||
array_ptr = IF_G(post_array);
|
||||
break;
|
||||
case PARSE_COOKIE:
|
||||
array_ptr = IF_G(post_array);
|
||||
break;
|
||||
}
|
||||
|
||||
if(!array_ptr) RETURN_FALSE;
|
||||
|
||||
/*
|
||||
* I'm changing the variable name here because when running with register_globals on,
|
||||
* the variable will end up in the global symbol table
|
||||
*/
|
||||
raw_var = emalloc(var_len+5); /* RAW_ and a \0 */
|
||||
strcpy(raw_var, "RAW_");
|
||||
strlcat(raw_var,var,var_len+5);
|
||||
hash_ptr = HASH_OF(array_ptr);
|
||||
|
||||
if(zend_hash_find(hash_ptr, raw_var, var_len+5, (void **)&tmp) == SUCCESS) {
|
||||
*return_value = **tmp;
|
||||
zval_copy_ctor(return_value);
|
||||
} else {
|
||||
RETVAL_FALSE;
|
||||
}
|
||||
efree(raw_var);
|
||||
}
|
||||
|
||||
@@ -3,17 +3,21 @@ parenthesis means that person has taken on this project.
|
||||
|
||||
Zend
|
||||
----
|
||||
For PHP 4.3.0:
|
||||
* Allow foreach ($array as $k => &$val) syntax. right now we cannot
|
||||
traverse an array without copying each element.
|
||||
* Allow foreach ($array as $k => list($a, $b)) syntax for multi
|
||||
dimensional arrays.
|
||||
* Look at replacing c-lib call tolower().
|
||||
* Make hash API functions work with HASH_OF() to save time.
|
||||
* Allow to set a default value for call-by-reference-parameters.
|
||||
eg: function hello (&$pallo = NULL) {}
|
||||
* Disallow function(method) redefinition in class.
|
||||
* Add configure test to determine if dlsym() requires underscore and set
|
||||
DLSYM_NEEDS_UNDERSCORE accordingly. Perl and zsh have it in configure,
|
||||
for example. (DONE?)
|
||||
* Allow foreach ($array as $k => &$val) syntax. right now we cannot
|
||||
traverse an array without copying each element.
|
||||
|
||||
For PHP 5.0.0:
|
||||
* Native large number support (probably with GNU GMP)
|
||||
* Const'ify APIs. Right now, many functions leave parameters untouched,
|
||||
but don't declare those as const. This makes interaction with other
|
||||
@@ -22,11 +26,26 @@ Zend
|
||||
|
||||
global
|
||||
------
|
||||
For PHP 4.3.0:
|
||||
* Add aliases to functions to conform to new naming conventions, e.g.
|
||||
str_to_upper().
|
||||
* Make all extensions thread-safe.
|
||||
* Make everything on the language-level independent of your locale
|
||||
settings.
|
||||
* Change PHP error messages, so that they point to pages or sections
|
||||
in the PHP Manual.
|
||||
* Make sure that all ZTS globals get destructed. Most ts_allocate_id()
|
||||
calls should have a dtor entry.
|
||||
* Activate all extensions by default that don't rely on external
|
||||
dependencies. (eg ftp) (DONE?)
|
||||
* on some platforms unimplemented function will just do nothing
|
||||
(e.g. symlink) they should print a warning or not even be defined!
|
||||
(DONE ?)
|
||||
* Use arg_separator.input to implode args in the CGI sapi extension
|
||||
and arg_separator.input to explode in php_build_argv(). (DONE?)
|
||||
|
||||
For PHP 5.0.0
|
||||
* bundle and use curl lib for fopen wrapper.
|
||||
* --enable-all in configure. (--enable-shared=max ...)
|
||||
* make configure print out a summary when it's done (like XEmacs)
|
||||
* replace standard functions which work on static data with
|
||||
@@ -39,28 +58,16 @@ global
|
||||
* Move most extensions and PEAR packages out of the PHP CVS tree,
|
||||
include them again during release packaging.
|
||||
|
||||
|
||||
Other
|
||||
* use thread-safe resolver functions (either require BIND 8 or adns).
|
||||
* implement javadoc based function docs template system.
|
||||
* provide optional IPv6 support (seems to be done?).
|
||||
* provide optional IPv6 support.
|
||||
* find a better way to implement script timeouts. SIGVTALRM is used
|
||||
by some POSIX threads implementations (i.e. OpenBSD) and is not
|
||||
available in ZTS mode.
|
||||
* Implement flush feature suitable for nested output buffers.
|
||||
|
||||
Streams
|
||||
-------
|
||||
* Route filestat.c through the wrapper layer; isolate the statcache code
|
||||
so that it is independent of php functions and can be applied to any
|
||||
stream/path.
|
||||
* Implement generalized connection pool for stated protocols such as
|
||||
ftp and http/1.1 (using keep-alive) to avoid having to negotiate
|
||||
new command/request stream for each subsequent call; Possibly store
|
||||
resources in contexts (creating a default context if necessary) to
|
||||
allow segmentation of connection pools.
|
||||
* Add a method to take ownership of the memory buffer in memory streams so
|
||||
that generating string values for zvals doesn't require an estrdup.
|
||||
* bundle and use curl lib for fopen wrapper.
|
||||
|
||||
documentation
|
||||
-------------
|
||||
@@ -133,13 +140,24 @@ ext/session
|
||||
* Provide a callback facility which is executed upon encountering
|
||||
an unknown class name during deserialization
|
||||
|
||||
ext/sockets
|
||||
-----------
|
||||
* Implement IPv6
|
||||
* Review/Fix vectors
|
||||
|
||||
ext/standard
|
||||
------------
|
||||
* Add a version number to data serialized via serialize().
|
||||
* Possibly modify parsing of GPC data to automatically create arrays if
|
||||
variable name is seen more than once.
|
||||
* Implement regex-cache for url-functions.
|
||||
* stri_replace(). (Andrei)
|
||||
* Move socket related functions to fsock.c.
|
||||
* NOT binary safe:
|
||||
strtok()
|
||||
basename()
|
||||
dirname()
|
||||
strrpos()
|
||||
|
||||
ext/wddx
|
||||
--------
|
||||
@@ -155,5 +173,3 @@ ext/wddx
|
||||
other cool stuff
|
||||
----------------
|
||||
* PVM extension
|
||||
|
||||
vim:et:sw=4:ts=4
|
||||
@@ -1,211 +0,0 @@
|
||||
Component: Zend Engine 2
|
||||
|
||||
Important stuff to finish: PPP members/PPP methods,
|
||||
support of overloaded extensions, possibly differentiate
|
||||
between class and namespace as discussed with Stig in
|
||||
Germany.
|
||||
Responsibility: Zeev, Andi, Stas
|
||||
Time frame: Couple of months for first part and extensions will be
|
||||
ongoing while PHP is being fixed.
|
||||
Things to leave for later versions: Native aggregation
|
||||
support, accessing static members via object and not class.
|
||||
|
||||
|
||||
Component: Aggregation
|
||||
Responsibility: Andi, Stig?
|
||||
Time frame: ?
|
||||
|
||||
|
||||
Component: Introspection
|
||||
|
||||
get_function_definition(<is_callable> [field]) =>
|
||||
array(
|
||||
file => filename
|
||||
line_start =>
|
||||
line_end =>
|
||||
parameters => array( name, byref, default )
|
||||
static_variables => array( name, value/default )
|
||||
scope => 'namespace' | 'class' | null
|
||||
namespace => classname | namespacename | 'main'
|
||||
protection => protection_flags
|
||||
phpdoc => pre-scanned-phpdoc-string
|
||||
type => 'internal' | 'user'
|
||||
)
|
||||
|
||||
get_class_definition(<class> [field]) =>
|
||||
array(
|
||||
type => 'internal' | 'user'
|
||||
file => filename
|
||||
line_start =>
|
||||
line_end =>
|
||||
name => pretty-name
|
||||
parent => classname | namespace | null
|
||||
flags => bitfield (ABSTRACT)
|
||||
methods => array( array( name, phpdoc ) )
|
||||
default_properties => array( array( name, value, phpdoc ) )
|
||||
private_properties => array( array( name, value, phpdoc ) )
|
||||
protected_properties => array( array( name, value, phpdoc ) )
|
||||
public_properties => array( array( name, value, phpdoc ) )
|
||||
static_members => array( array( name, value, phpdoc ) )
|
||||
constants => array( array( name, value, phpdoc ) )
|
||||
classes => array( array( name, phpdoc ) )
|
||||
phpdoc => pre-scanned-phpdoc-string
|
||||
)
|
||||
|
||||
get_constant_definition(<constant> [field]) =>
|
||||
array(
|
||||
file => filename
|
||||
line_start =>
|
||||
line_end =>
|
||||
name =>
|
||||
value =>
|
||||
phpdoc =>
|
||||
)
|
||||
|
||||
get_global_variable_defintion(<name> [field]) =>
|
||||
array(
|
||||
file =>
|
||||
line_start =>
|
||||
line_end =>
|
||||
name =>
|
||||
phpdoc =>
|
||||
)
|
||||
|
||||
We tried to take into account the implementation of each piece of
|
||||
information, and there are some that are problematic, especially those
|
||||
regarding constants and global variables (where do we store the extra
|
||||
information?)
|
||||
|
||||
With "pre-scanned-phpdoc-string" we mean converting:
|
||||
|
||||
/**
|
||||
* Blah blah blah
|
||||
* @param foo ...
|
||||
*/
|
||||
|
||||
to:
|
||||
|
||||
Blah blah blah
|
||||
@param foo
|
||||
|
||||
The rest of the phpdoc handling should be left to an extension.
|
||||
Responsibility: Stig, Andrei, Harald
|
||||
Time frame: ?
|
||||
|
||||
|
||||
Component: Redesign of API Versioning
|
||||
Responsibility: ?
|
||||
Time frame: 1 month
|
||||
|
||||
|
||||
Component: Thread Safety
|
||||
Identify the extensions that are not thread safe by design
|
||||
or due to dependant libraries and identify them as such.
|
||||
If possible try to resolve thread safety issue via code
|
||||
improvements (if php code or patches will be accepted by
|
||||
library maintainers). For situations where thread safety
|
||||
cannot easily be acheived a flag in the extension API is
|
||||
set so PHP can identify non-thread safe extensions. These
|
||||
extensions will not be loaded in a ZTS compiled binary
|
||||
(unless it is cli/cgi).
|
||||
|
||||
Responsibility: ?
|
||||
Time frame: ?
|
||||
|
||||
|
||||
Component: SAPI
|
||||
Environment variables defined in the CGI spec need to be
|
||||
verified in each SAPI module that they conform to the CGI
|
||||
spec correctly. If they do not, the SAPI module needs to
|
||||
fix the variable prior to script execution. Having this
|
||||
conformity will aid in having PHP scripts run correctly
|
||||
under different sapi modules.
|
||||
|
||||
Responsibility: Shane Caraveo & each sapi module owner
|
||||
Timeframe: ? (but shouldn't be much effort, most modules are probably ok)
|
||||
|
||||
|
||||
Component: Input Filtering
|
||||
- Implement a SAPI input filter hook that will get called
|
||||
just before registering a variable in the
|
||||
treat_data/post_handler hooks. (done)
|
||||
- Make sure this is also done in mbstring (done)
|
||||
- Provide access functions, or perhaps a new
|
||||
$_RAW_GET/POST/Cookie set of superglobals to get at the
|
||||
unfiltered data
|
||||
- Provide a .ini directive which allows people to set their
|
||||
input filter to one of the built-in strip_tags,
|
||||
htmlspecialchars or whatever other internal function might
|
||||
be useful here.
|
||||
- (The main benefit of this is to make it easier for people
|
||||
to solve the XSS problem once and for all without having
|
||||
to go through every line of their code and adding input
|
||||
validation/filtering everywhere)
|
||||
Responsibility: Rasmus
|
||||
Timeframe: Yesterday
|
||||
|
||||
|
||||
Component: RPC Abstraction Layer
|
||||
Porting java, com, dotnet, xmlrpc, corba, soap and python, srm
|
||||
(are there more ?) to work with the new oo api and preferably
|
||||
by using ext/rpc.
|
||||
Responsibility: Harald
|
||||
Time frame: 2 months (but i have to wait for a few engine features first)
|
||||
|
||||
|
||||
Component: OO Extensions
|
||||
Each OO extension has to be revised and rewritten to fit into
|
||||
the new OO model. We should decide which extensions are a must
|
||||
to have for the release and which can be ported by the maintainer
|
||||
later as a separate pecl release.
|
||||
A list of extensions to be extended that have to be investigated:
|
||||
* browscap
|
||||
* aggregate
|
||||
* all *sql extensions (*_fetch_object)
|
||||
* domxml (seems like christian is rewriting it anyways)
|
||||
* ming
|
||||
Responsibility: Harald (, extension maintainers)
|
||||
|
||||
|
||||
Component: Abstract Data Types (ADT)
|
||||
Responsibility: Sterling, Harald
|
||||
Time frame: ?
|
||||
|
||||
|
||||
Component: MySQL Extension
|
||||
Complete rewrite, leveraging the new MySQL 4 / MySQL 5
|
||||
features.
|
||||
Responsibility: Georg Richter, Zak Greant
|
||||
Timeframe: ?
|
||||
|
||||
|
||||
Component: XML
|
||||
- Rewrite DOMXML and incorporate all (or most of) W3C-DOM2.
|
||||
- Use the new ZE2 features (Exceptions, setter/getter).
|
||||
- Add SAX(2), XML Schema.
|
||||
- XSLT, HTML, XPath, XPointer, DTD Validation will still be
|
||||
supported, have to find a meaningful API for it.
|
||||
- Break BC, warn users now.
|
||||
- Look at the libxml2 patch by lukas schröder and see if we can prevent
|
||||
memory leaks with it (anyway, getting rid of mem-leaks and intelligent
|
||||
memory management is on top prio...)
|
||||
- In the longer term, domxml (or another name, as with todays features
|
||||
domxml is a little bit misleading) shall be the main xml-class, which
|
||||
covers most of what's needed for decent XML support in PHP ;)
|
||||
But there is certainly place for others like Sablotron etc.
|
||||
Responsibility: Christian Stocker
|
||||
Timeframe: ?
|
||||
|
||||
|
||||
Component: Test Suite
|
||||
Extending the test suite with atleast a test for every
|
||||
function in an extension that doesn't require external
|
||||
resources. Also developing an automated test thing which
|
||||
cvs ups's, compiles and tests the build on a daily base on
|
||||
as much platforms/extensions as possible.
|
||||
|
||||
The test suite will also be extended to support threaded
|
||||
testing and testing for differing sapi modules (via http
|
||||
calls or other methods).
|
||||
Reponsibility: Derick (, extension maintainers)
|
||||
Time frame: 3 months
|
||||
@@ -1,3 +0,0 @@
|
||||
- clean up .cvsignores
|
||||
- purge Makefile.ins and replace PHP_EXTENSION in config.m4s
|
||||
with appropiate calls to PHP_NEW_EXTENSION
|
||||
+114
@@ -0,0 +1,114 @@
|
||||
This is an overview over existing segfaults in the current PHP source
|
||||
tree.
|
||||
|
||||
|
||||
Fixed:
|
||||
|
||||
mb_convert_encoding (Moriyoshi)
|
||||
socket_iovec_alloc (Rasmus)
|
||||
exif_imagetype,exif_thumbnail (Rasmus)
|
||||
dbase_open (Rasmus)
|
||||
array_pad (Rasmus)
|
||||
setlocale (Rasmus)
|
||||
unregister_tick_function (Rasmus)
|
||||
bcsub (Rasmus)
|
||||
str_repeat (Ilia)
|
||||
imagecopyresized (Ilia)
|
||||
mhash_keygen_s2k (Ilia)
|
||||
bundled gd (Ilia)
|
||||
mb_ereg, mb_ereg_match, mb_eregi, mb_split (Moriyoshi)
|
||||
xml_parser_create (Moriyoshi)
|
||||
ob_start (Sascha)
|
||||
imagecreate/-truecolor (Sascha)
|
||||
flock (Sascha)
|
||||
register_shutdown_function (Sascha)
|
||||
mb_strcut('', [number greater than the length of first arg]) (Moriyoshi)
|
||||
ext/exif, ext/dba (Marcus)
|
||||
php_base64_encode (Moriyoshi)
|
||||
|
||||
Open:
|
||||
|
||||
the dbase extension (1)
|
||||
socket_select (2)
|
||||
pack (3)
|
||||
|
||||
(1) heap corruption, mostly visible in malloc-related calls. Whether you see
|
||||
this or not might depend on your libc/compiler. Hard to track down,
|
||||
because the result of the corruption might be quite delayed.
|
||||
|
||||
Reproducable with glibc-2.3/gcc 3.2.2 by:
|
||||
|
||||
cat <<X | php do_crash
|
||||
dbase_add_record
|
||||
dbase_close
|
||||
dbase_create
|
||||
dbase_delete_record
|
||||
dbase_get_record
|
||||
dbase_get_record_with_names
|
||||
dbase_numfields
|
||||
dbase_numrecords
|
||||
dbase_open
|
||||
X
|
||||
|
||||
(2) heap corruption, dies in efree()/execute()
|
||||
|
||||
Methodology
|
||||
|
||||
1. Use a plain PHP_4_3 tree
|
||||
2. Use the config.nice from ammendment 1.
|
||||
3. Download the test script from:
|
||||
|
||||
<URL:http://schumann.cx/do_crash.txt>
|
||||
|
||||
4a. Use the scripts funcparse.awk/genfunclist.sh from phpdoc/scripts
|
||||
for creating a plain text function list. Feed that list to
|
||||
the script. Avoid calls like pcntl_fork. Manually remove functions
|
||||
which take too long to finish/eat up all memory.
|
||||
|
||||
4b. For testing a single function, echo the name of the function to
|
||||
the script like this:
|
||||
|
||||
echo dbase_open | php do_crash.txt
|
||||
|
||||
(3) multiple integer overflows, ex. pack("d4294967297", 2);
|
||||
|
||||
Amendment 1.
|
||||
|
||||
CFLAGS='-O0 -g' \
|
||||
'../src/php4/configure' \
|
||||
'--enable-pcntl' \
|
||||
'--enable-shmop' \
|
||||
'--enable-sysvsem' \
|
||||
'--enable-sysvshm' \
|
||||
'--enable-wddx' \
|
||||
'--enable-yp' \
|
||||
'--enable-filepro' \
|
||||
'--enable-ftp' \
|
||||
'--enable-dba' \
|
||||
'--enable-dbase' \
|
||||
'--enable-dio' \
|
||||
'--enable-exif' \
|
||||
'--enable-mbstring' \
|
||||
'--enable-mbregex' \
|
||||
'--enable-sockets' \
|
||||
'--enable-bcmath' \
|
||||
'--enable-calendar' \
|
||||
'--enable-pcntl' \
|
||||
'--enable-shmop' \
|
||||
'--enable-sysvsem' \
|
||||
'--enable-sysvshm' \
|
||||
'--enable-wddx' \
|
||||
'--enable-yp' \
|
||||
'--enable-filepro' \
|
||||
'--enable-ftp' \
|
||||
'--enable-dba' \
|
||||
'--enable-dbase' \
|
||||
'--enable-dio' \
|
||||
'--enable-exif' \
|
||||
'--enable-mbstring' \
|
||||
'--enable-mbregex' \
|
||||
'--enable-sockets' \
|
||||
'--enable-bcmath' \
|
||||
'--enable-calendar' \
|
||||
"$@"
|
||||
|
||||
+10
-40
@@ -158,9 +158,15 @@ TSRM_API void tsrm_shutdown(void)
|
||||
|
||||
next_p = p->next;
|
||||
for (j=0; j<p->count; j++) {
|
||||
/* Disabled - calling dtors in tsrm_shutdown makes
|
||||
modules registering TSRM ids to crash, if they have
|
||||
dtors, since the module is unloaded before tsrm_shutdown
|
||||
is called. Can be re-enabled after tsrm_free_id is
|
||||
implemented.
|
||||
if (resource_types_table && resource_types_table[j].dtor) {
|
||||
resource_types_table[j].dtor(p->storage[j], &p->storage);
|
||||
}
|
||||
*/
|
||||
free(p->storage[j]);
|
||||
}
|
||||
free(p->storage);
|
||||
@@ -294,15 +300,6 @@ TSRM_API void *ts_resource_ex(ts_rsrc_id id, THREAD_T *th_id)
|
||||
int hash_value;
|
||||
tsrm_tls_entry *thread_resources;
|
||||
|
||||
#ifdef NETWARE
|
||||
/* The below if loop is added for NetWare to fix an abend while unloading PHP
|
||||
* when an Apache unload command is issued on the system console.
|
||||
* While exiting from PHP, at the end for some reason, this function is called
|
||||
* with tsrm_tls_table = NULL. When this happened, the server abends when
|
||||
* tsrm_tls_table is accessed since it is NULL.
|
||||
*/
|
||||
if(tsrm_tls_table) {
|
||||
#endif
|
||||
if (!th_id) {
|
||||
#if defined(PTHREADS)
|
||||
/* Fast path for looking up the resources for the current
|
||||
@@ -365,9 +362,6 @@ TSRM_API void *ts_resource_ex(ts_rsrc_id id, THREAD_T *th_id)
|
||||
* changes to the structure as we read it.
|
||||
*/
|
||||
TSRM_SAFE_RETURN_RSRC(thread_resources->storage, id, thread_resources->count);
|
||||
#ifdef NETWARE
|
||||
} /* if(tsrm_tls_table) */
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
@@ -435,12 +429,7 @@ TSRM_API THREAD_T tsrm_thread_id(void)
|
||||
#ifdef TSRM_WIN32
|
||||
return GetCurrentThreadId();
|
||||
#elif defined(NETWARE)
|
||||
/* There seems to be some problem with the LibC call: NXThreadGetId().
|
||||
* Due to this, the PHPMyAdmin application is abending in PHP calls.
|
||||
* Used the call, kCurrentThread instead and it works fine.
|
||||
*/
|
||||
/* return NXThreadGetId(); */
|
||||
return kCurrentThread();
|
||||
return NXThreadGetId();
|
||||
#elif defined(GNUPTH)
|
||||
return pth_self();
|
||||
#elif defined(PTHREADS)
|
||||
@@ -462,23 +451,16 @@ TSRM_API MUTEX_T tsrm_mutex_alloc(void)
|
||||
{
|
||||
MUTEX_T mutexp;
|
||||
#ifdef NETWARE
|
||||
#ifndef USE_MPK
|
||||
/* To use the Recursive Mutex Locking of LibC */
|
||||
long flags = NX_MUTEX_RECURSIVE;
|
||||
long flags = 0; /* Don't require NX_MUTEX_RECURSIVE, I guess */
|
||||
NXHierarchy_t order = 0;
|
||||
NX_LOCK_INFO_ALLOC (lockInfo, "PHP-TSRM", 0);
|
||||
#endif
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifdef TSRM_WIN32
|
||||
mutexp = malloc(sizeof(CRITICAL_SECTION));
|
||||
InitializeCriticalSection(mutexp);
|
||||
#elif defined(NETWARE)
|
||||
#ifdef USE_MPK
|
||||
mutexp = kMutexAlloc((BYTE*)"PHP-TSRM");
|
||||
#else
|
||||
mutexp = NXMutexAlloc(flags, order, &lockInfo);
|
||||
#endif
|
||||
mutexp = NXMutexAlloc(flags, order, &lockInfo); /* return value ignored for now */
|
||||
#elif defined(GNUPTH)
|
||||
mutexp = (MUTEX_T) malloc(sizeof(*mutexp));
|
||||
pth_mutex_init(mutexp);
|
||||
@@ -511,11 +493,7 @@ TSRM_API void tsrm_mutex_free(MUTEX_T mutexp)
|
||||
DeleteCriticalSection(mutexp);
|
||||
free(mutexp);
|
||||
#elif defined(NETWARE)
|
||||
#ifdef USE_MPK
|
||||
kMutexFree(mutexp);
|
||||
#else
|
||||
NXMutexFree(mutexp);
|
||||
#endif
|
||||
#elif defined(GNUPTH)
|
||||
free(mutexp);
|
||||
#elif defined(PTHREADS)
|
||||
@@ -546,11 +524,7 @@ TSRM_API int tsrm_mutex_lock(MUTEX_T mutexp)
|
||||
EnterCriticalSection(mutexp);
|
||||
return 1;
|
||||
#elif defined(NETWARE)
|
||||
#ifdef USE_MPK
|
||||
return kMutexLock(mutexp);
|
||||
#else
|
||||
return NXLock(mutexp);
|
||||
#endif
|
||||
#elif defined(GNUPTH)
|
||||
return pth_mutex_acquire(mutexp, 0, NULL);
|
||||
#elif defined(PTHREADS)
|
||||
@@ -577,11 +551,7 @@ TSRM_API int tsrm_mutex_unlock(MUTEX_T mutexp)
|
||||
LeaveCriticalSection(mutexp);
|
||||
return 1;
|
||||
#elif defined(NETWARE)
|
||||
#ifdef USE_MPK
|
||||
return kMutexUnlock(mutexp);
|
||||
#else
|
||||
return NXUnlock(mutexp);
|
||||
#endif
|
||||
#elif defined(GNUPTH)
|
||||
return pth_mutex_release(mutexp);
|
||||
#elif defined(PTHREADS)
|
||||
|
||||
-16
@@ -37,18 +37,10 @@
|
||||
#ifdef ZTS
|
||||
|
||||
#ifdef TSRM_WIN32
|
||||
# ifndef TSRM_INCLUDE_FULL_WINDOWS_HEADERS
|
||||
# define WIN32_LEAN_AND_MEAN
|
||||
# endif
|
||||
# include <windows.h>
|
||||
# include <shellapi.h>
|
||||
#elif defined(NETWARE)
|
||||
# include <nks/thread.h>
|
||||
#ifdef USE_MPK
|
||||
# include <mpklib4php.h>
|
||||
#else
|
||||
# include <nks/synch.h>
|
||||
#endif
|
||||
#elif defined(GNUPTH)
|
||||
# include <pth.h>
|
||||
#elif defined(PTHREADS)
|
||||
@@ -68,11 +60,7 @@ typedef int ts_rsrc_id;
|
||||
# define MUTEX_T CRITICAL_SECTION *
|
||||
#elif defined(NETWARE)
|
||||
# define THREAD_T NXThreadId_t
|
||||
#ifdef USE_MPK
|
||||
# define MUTEX_T MUTEX
|
||||
#else
|
||||
# define MUTEX_T NXMutex_t *
|
||||
#endif
|
||||
#elif defined(GNUPTH)
|
||||
# define THREAD_T pth_t
|
||||
# define MUTEX_T pth_mutex_t *
|
||||
@@ -150,8 +138,6 @@ TSRM_API void *tsrm_set_new_thread_end_handler(tsrm_thread_end_func_t new_thread
|
||||
#define TSRM_UNSHUFFLE_RSRC_ID(rsrc_id) ((rsrc_id)-1)
|
||||
|
||||
#define TSRMLS_FETCH() void ***tsrm_ls = (void ***) ts_resource_ex(0, NULL)
|
||||
#define TSRMLS_FETCH_FROM_CTX(ctx) void ***tsrm_ls = (void ***) ctx
|
||||
#define TSRMLS_SET_CTX(ctx) (void ***) ctx = tsrm_ls
|
||||
#define TSRMG(id, type, element) (((type) (*((void ***) tsrm_ls))[TSRM_UNSHUFFLE_RSRC_ID(id)])->element)
|
||||
#define TSRMLS_D void ***tsrm_ls
|
||||
#define TSRMLS_DC , TSRMLS_D
|
||||
@@ -165,8 +151,6 @@ TSRM_API void *tsrm_set_new_thread_end_handler(tsrm_thread_end_func_t new_thread
|
||||
#else /* non ZTS */
|
||||
|
||||
#define TSRMLS_FETCH()
|
||||
#define TSRMLS_FETCH_FROM_CTX(ctx)
|
||||
#define TSRMLS_SET_CTX(ctx)
|
||||
#define TSRMLS_D void
|
||||
#define TSRMLS_DC
|
||||
#define TSRMLS_C
|
||||
|
||||
@@ -3,9 +3,7 @@
|
||||
|
||||
#define HAVE_UTIME 1
|
||||
|
||||
/* Though we have alloca(), this seems to be causing some problem
|
||||
* with the stack pointer. Hence not using it
|
||||
*/
|
||||
/*#define HAVE_ALLOCA 1*/
|
||||
/* Though we have alloca(), this seems to be causing some problem with the stack pointer -- hence not using it */
|
||||
/* #define HAVE_ALLOCA 1 */
|
||||
|
||||
#endif
|
||||
@@ -25,9 +25,7 @@
|
||||
#pragma alloca
|
||||
# else
|
||||
# ifndef alloca /* predefined by HP cc +Olibcalls */
|
||||
# ifndef NETWARE
|
||||
char *alloca ();
|
||||
# endif
|
||||
# endif
|
||||
# endif
|
||||
# endif
|
||||
|
||||
+155
-135
@@ -4,16 +4,15 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1997-2003 The PHP Group |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 3.0 of the PHP license, |
|
||||
| This source file is subject to version 2.02 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. |
|
||||
| available at through the world-wide-web at |
|
||||
| http://www.php.net/license/2_02.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. |
|
||||
+----------------------------------------------------------------------+
|
||||
| Authors: Venkat Raghavan S <rvenkat@novell.com> |
|
||||
| Anantha Kesari H Y <hyanantha@novell.com> |
|
||||
+----------------------------------------------------------------------+
|
||||
*/
|
||||
|
||||
@@ -40,9 +39,8 @@
|
||||
|
||||
#include "mktemp.h"
|
||||
|
||||
/* strtok() call in LibC is abending when used in a different address space
|
||||
* -- hence using PHP's version itself for now
|
||||
*/
|
||||
/* strtok() call in LibC is abending when used in a different address space -- hence using
|
||||
PHP's version itself for now : Venkat (30/4/02) */
|
||||
#include "tsrm_strtok_r.h"
|
||||
#define tsrm_strtok_r(a,b,c) strtok((a),(b))
|
||||
|
||||
@@ -52,189 +50,211 @@
|
||||
|
||||
TSRM_API FILE* popen(const char *commandline, const char *type)
|
||||
{
|
||||
char *command = NULL, *argv[MAX_ARGS] = {'\0'}, **env = NULL;
|
||||
char *command = NULL, *argv[MAX_ARGS] = {'\0'}, **env = NULL;
|
||||
char *tempName = "sys:/php/temp/phpXXXXXX.tmp";
|
||||
char *filePath = NULL;
|
||||
char *ptr = NULL;
|
||||
int ptrLen = 0, argc = 0, i = 0, envCount = 0, err = 0;
|
||||
char *filePath = NULL;
|
||||
char *ptr = NULL;
|
||||
int ptrLen = 0, argc = 0, i = 0, envCount = 0, err = 0;
|
||||
FILE *stream = NULL;
|
||||
#if defined(USE_PIPE_OPEN) || defined(USE_MKFIFO)
|
||||
int pipe_handle;
|
||||
int mode = O_RDONLY;
|
||||
int pipe_handle;
|
||||
int mode = O_RDONLY;
|
||||
#else
|
||||
NXHandle_t pipe_handle;
|
||||
NXMode_t mode = NX_O_RDONLY;
|
||||
NXHandle_t pipe_handle;
|
||||
NXMode_t mode = NX_O_RDONLY;
|
||||
#endif
|
||||
NXExecEnvSpec_t envSpec;
|
||||
NXNameSpec_t nameSpec;
|
||||
NXVmId_t newVM = 0;
|
||||
NXExecEnvSpec_t envSpec;
|
||||
NXNameSpec_t nameSpec;
|
||||
NXVmId_t newVM = 0;
|
||||
|
||||
/* Check for validity of input parameters */
|
||||
if (!commandline || !type)
|
||||
return NULL;
|
||||
/* Check for validity of input parameters */
|
||||
if (!commandline || !type)
|
||||
return NULL;
|
||||
|
||||
/* Get temporary file name */
|
||||
filePath = mktemp(tempName);
|
||||
/* Get temporary file name */
|
||||
filePath = mktemp(tempName);
|
||||
/*consoleprintf ("PHP | popen: file path = %s, mode = %s\n", filePath, type);*/
|
||||
if (!filePath)
|
||||
return NULL;
|
||||
|
||||
/* Set pipe mode according to type -- for now allow only "r" or "w" */
|
||||
if (strcmp(type, "r") == 0)
|
||||
/* Set pipe mode according to type -- for now allow only "r" or "w" */
|
||||
if (strcmp(type, "r") == 0)
|
||||
#if defined(USE_PIPE_OPEN) || defined(USE_MKFIFO)
|
||||
mode = O_RDONLY;
|
||||
mode = O_RDONLY;
|
||||
#else
|
||||
mode = NX_O_RDONLY;
|
||||
mode = NX_O_RDONLY;
|
||||
#endif
|
||||
else if (strcmp(type, "w") == 0)
|
||||
else if (strcmp(type, "w") == 0)
|
||||
#if defined(USE_PIPE_OPEN) || defined(USE_MKFIFO)
|
||||
mode = O_WRONLY;
|
||||
mode = O_WRONLY;
|
||||
#else
|
||||
mode = NX_O_WRONLY;
|
||||
mode = NX_O_WRONLY;
|
||||
#endif
|
||||
else
|
||||
return NULL;
|
||||
else
|
||||
return NULL;
|
||||
|
||||
#ifdef USE_PIPE_OPEN
|
||||
pipe_handle = pipe_open(filePath, mode);
|
||||
if (pipe_handle == -1)
|
||||
return NULL;
|
||||
pipe_handle = pipe_open(filePath, mode);
|
||||
/*consoleprintf ("PHP | popen: pipe_open() returned %d\n", pipe_handle);*/
|
||||
if (pipe_handle == -1)
|
||||
return NULL;
|
||||
#elif defined(USE_MKFIFO)
|
||||
pipe_handle = mkfifo(filePath, mode);
|
||||
if (pipe_handle == -1)
|
||||
return NULL;
|
||||
pipe_handle = mkfifo(filePath, mode);
|
||||
consoleprintf ("PHP | popen: mkfifo() returned %d\n", pipe_handle);
|
||||
if (pipe_handle == -1)
|
||||
return NULL;
|
||||
#else
|
||||
/* - NetWare doesn't require first parameter
|
||||
* - Allowing LibC to choose the buffer size for now
|
||||
*/
|
||||
err = NXFifoOpen(0, filePath, mode, 0, &pipe_handle);
|
||||
if (err)
|
||||
return NULL;
|
||||
/*
|
||||
- NetWare doesn't require first parameter
|
||||
- Allowing LibC to choose the buffer size for now
|
||||
*/
|
||||
err = NXFifoOpen(0, filePath, mode, 0, &pipe_handle);
|
||||
/*consoleprintf ("PHP | popen: NXFifoOpen() returned %d\n", err);*/
|
||||
if (err)
|
||||
return NULL;
|
||||
#endif
|
||||
|
||||
/* Copy the environment variables in preparation for the spawn call */
|
||||
envCount = NXGetEnvCount() + 1; /* add one for NULL */
|
||||
env = (char **) NXMemAlloc(sizeof(char *) * envCount, 0);
|
||||
if (!env)
|
||||
return NULL;
|
||||
/* Copy the environment variables in preparation for the spawn call */
|
||||
|
||||
err = NXCopyEnv(env, envCount);
|
||||
if (err) {
|
||||
NXMemFree (env);
|
||||
return NULL;
|
||||
}
|
||||
envCount = NXGetEnvCount() + 1; /* add one for NULL */
|
||||
env = (char**)NXMemAlloc(sizeof(char*) * envCount, 0);
|
||||
if (!env)
|
||||
return NULL;
|
||||
|
||||
/* Separate commandline string into words */
|
||||
ptr = tsrm_strtok_r((char*)commandline, WHITESPACE, NULL);
|
||||
ptrLen = strlen(ptr);
|
||||
err = NXCopyEnv(env, envCount);
|
||||
consoleprintf ("PHP | popen: NXCopyEnv() returned %d\n", err);
|
||||
if (err)
|
||||
{
|
||||
NXMemFree (env);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
command = (char*)malloc(ptrLen + 1);
|
||||
if (!command) {
|
||||
NXMemFree (env);
|
||||
return NULL;
|
||||
}
|
||||
/* Separate commandline string into words */
|
||||
consoleprintf ("PHP | popen: commandline = %s\n", commandline);
|
||||
ptr = tsrm_strtok_r((char*)commandline, WHITESPACE, NULL);
|
||||
ptrLen = strlen(ptr);
|
||||
|
||||
strcpy (command, ptr);
|
||||
command = (char*)malloc(ptrLen + 1);
|
||||
if (!command)
|
||||
{
|
||||
NXMemFree (env);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
ptr = tsrm_strtok_r(NULL, WHITESPACE, NULL);
|
||||
while (ptr && (argc < MAX_ARGS)) {
|
||||
ptrLen = strlen(ptr);
|
||||
strcpy (command, ptr);
|
||||
|
||||
argv[argc] = (char*)malloc(ptrLen + 1);
|
||||
if (!argv[argc]) {
|
||||
NXMemFree (env);
|
||||
if (command)
|
||||
free (command);
|
||||
ptr = tsrm_strtok_r(NULL, WHITESPACE, NULL);
|
||||
while (ptr && (argc < MAX_ARGS))
|
||||
{
|
||||
ptrLen = strlen(ptr);
|
||||
|
||||
for (i = 0; i < argc; i++) {
|
||||
if (argv[i])
|
||||
free (argv[i]);
|
||||
}
|
||||
argv[argc] = (char*)malloc(ptrLen + 1);
|
||||
if (!argv[argc])
|
||||
{
|
||||
NXMemFree (env);
|
||||
|
||||
return NULL;
|
||||
}
|
||||
if (command)
|
||||
free (command);
|
||||
|
||||
strcpy (argv[argc], ptr);
|
||||
argc++;
|
||||
ptr = tsrm_strtok_r(NULL, WHITESPACE, NULL);
|
||||
}
|
||||
for (i = 0; i < argc; i++)
|
||||
{
|
||||
if (argv[i])
|
||||
free (argv[i]);
|
||||
}
|
||||
|
||||
/* Setup the execution environment and spawn new process */
|
||||
envSpec.esFlags = 0; /* Not used */
|
||||
envSpec.esArgc = argc;
|
||||
envSpec.esArgv = (void **) argv;
|
||||
envSpec.esEnv = (void **) env;
|
||||
return NULL;
|
||||
}
|
||||
|
||||
/* envSpec.esStdin.ssType = */
|
||||
envSpec.esStdout.ssType = NX_OBJ_FIFO;
|
||||
envSpec.esStderr.ssType = NX_OBJ_FILE;
|
||||
strcpy (argv[argc], ptr);
|
||||
|
||||
/* 'ssHandle' is not a struct/union/class member */
|
||||
argc++;
|
||||
|
||||
ptr = tsrm_strtok_r(NULL, WHITESPACE, NULL);
|
||||
}
|
||||
consoleprintf ("PHP | popen: commandline string parsed into tokens\n");
|
||||
/* Setup the execution environment and spawn new process */
|
||||
|
||||
envSpec.esFlags = 0; /* Not used */
|
||||
envSpec.esArgc = argc;
|
||||
envSpec.esArgv = (void**)argv;
|
||||
envSpec.esEnv = (void**)env;
|
||||
|
||||
envSpec.esStdin.ssType =
|
||||
envSpec.esStdout.ssType = NX_OBJ_FIFO;
|
||||
envSpec.esStderr.ssType = NX_OBJ_FILE;
|
||||
/*
|
||||
envSpec.esStdin.ssHandle =
|
||||
envSpec.esStdout.ssHandle =
|
||||
envSpec.esStderr.ssHandle = -1;
|
||||
envSpec.esStdin.ssHandle =
|
||||
envSpec.esStdout.ssHandle =
|
||||
envSpec.esStderr.ssHandle = -1;
|
||||
*/
|
||||
envSpec.esStdin.ssPathCtx = NULL;
|
||||
envSpec.esStdout.ssPathCtx = NULL;
|
||||
envSpec.esStderr.ssPathCtx = NULL;
|
||||
envSpec.esStdin.ssPathCtx =
|
||||
envSpec.esStdout.ssPathCtx =
|
||||
envSpec.esStderr.ssPathCtx = NULL;
|
||||
|
||||
#if defined(USE_PIPE_OPEN) || defined(USE_MKFIFO)
|
||||
if (mode == O_RDONLY) {
|
||||
if (mode == O_RDONLY)
|
||||
#else
|
||||
if (mode == NX_O_RDONLY) {
|
||||
if (mode == NX_O_RDONLY)
|
||||
#endif
|
||||
envSpec.esStdin.ssPath = filePath;
|
||||
envSpec.esStdout.ssPath = stdout;
|
||||
} else { /* Write Only */
|
||||
envSpec.esStdin.ssPath = stdin;
|
||||
envSpec.esStdout.ssPath = filePath;
|
||||
}
|
||||
{
|
||||
envSpec.esStdin.ssPath = filePath;
|
||||
envSpec.esStdout.ssPath = stdout;
|
||||
}
|
||||
else /* Write Only */
|
||||
{
|
||||
envSpec.esStdin.ssPath = stdin;
|
||||
envSpec.esStdout.ssPath = filePath;
|
||||
}
|
||||
|
||||
envSpec.esStderr.ssPath = stdout;
|
||||
envSpec.esStderr.ssPath = stdout;
|
||||
|
||||
nameSpec.ssType = NX_OBJ_FIFO;
|
||||
/* nameSpec.ssHandle = 0; */ /* 'ssHandle' is not a struct/union/class member */
|
||||
nameSpec.ssPathCtx = NULL; /* Not used */
|
||||
nameSpec.ssPath = argv[0];
|
||||
err = NXVmSpawn(&nameSpec, &envSpec, 0, &newVM);
|
||||
if (!err)
|
||||
/* Get file pointer corresponding to the pipe (file) opened */
|
||||
stream = fdopen(pipe_handle, type);
|
||||
nameSpec.ssType = NX_OBJ_FIFO;
|
||||
/* nameSpec.ssHandle = 0; */ /* Not used */
|
||||
nameSpec.ssPathCtx = NULL; /* Not used */
|
||||
nameSpec.ssPath = argv[0];
|
||||
consoleprintf ("PHP | popen: environment setup\n");
|
||||
err = NXVmSpawn(&nameSpec, &envSpec, 0, &newVM);
|
||||
consoleprintf ("PHP | popen: NXVmSpawn() returned %d\n", err);
|
||||
if (!err)
|
||||
/* Get file pointer corresponding to the pipe (file) opened */
|
||||
stream = fdopen(pipe_handle, type);
|
||||
|
||||
/* Clean-up */
|
||||
if (env)
|
||||
NXMemFree (env);
|
||||
/* Clean-up */
|
||||
|
||||
if (pipe_handle)
|
||||
if (env)
|
||||
NXMemFree (env);
|
||||
|
||||
if (pipe_handle)
|
||||
#if defined(USE_PIPE_OPEN) || defined(USE_MKFIFO)
|
||||
close(pipe_handle);
|
||||
close(pipe_handle);
|
||||
#else
|
||||
NXClose(pipe_handle);
|
||||
NXClose(pipe_handle);
|
||||
#endif
|
||||
|
||||
if (command)
|
||||
free (command);
|
||||
if (command)
|
||||
free (command);
|
||||
|
||||
for (i = 0; i < argc; i++) {
|
||||
if (argv[i])
|
||||
free (argv[i]);
|
||||
}
|
||||
|
||||
return stream;
|
||||
for (i = 0; i < argc; i++)
|
||||
{
|
||||
if (argv[i])
|
||||
free (argv[i]);
|
||||
}
|
||||
consoleprintf ("PHP | popen: all clean-up done, returning...\n");
|
||||
return stream;
|
||||
}
|
||||
|
||||
TSRM_API int pclose(FILE* stream)
|
||||
{
|
||||
int err = 0;
|
||||
NXHandle_t fd = 0;
|
||||
int err = 0;
|
||||
NXHandle_t fd = 0;
|
||||
|
||||
/* Get the process associated with this pipe (file) handle and terminate it */
|
||||
fd = fileno(stream);
|
||||
NXClose (fd);
|
||||
/* Get the process associated with this pipe (file) handle and terminate it */
|
||||
fd = fileno(stream);
|
||||
NXClose (fd);
|
||||
|
||||
err = fclose(stream);
|
||||
err = fclose(stream);
|
||||
|
||||
return err;
|
||||
return err;
|
||||
}
|
||||
|
||||
#endif /* NETWARE */
|
||||
#endif
|
||||
+3
-4
@@ -4,16 +4,15 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1997-2003 The PHP Group |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 3.0 of the PHP license, |
|
||||
| This source file is subject to version 2.02 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. |
|
||||
| available at through the world-wide-web at |
|
||||
| http://www.php.net/license/2_02.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. |
|
||||
+----------------------------------------------------------------------+
|
||||
| Authors: Venkat Raghavan S <rvenkat@novell.com> |
|
||||
| Anantha Kesari H Y <hyanantha@novell.com> |
|
||||
+----------------------------------------------------------------------+
|
||||
*/
|
||||
|
||||
|
||||
+11
-33
@@ -4,10 +4,10 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1997-2003 The PHP Group |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 3.0 of the PHP license, |
|
||||
| This source file is subject to version 2.02 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. |
|
||||
| available at through the world-wide-web at |
|
||||
| http://www.php.net/license/2_02.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. |
|
||||
@@ -49,7 +49,7 @@
|
||||
|
||||
#include "TSRM.h"
|
||||
|
||||
/* Only need mutex for popen() in Windows and NetWare because it doesn't chdir() on UNIX */
|
||||
/* Only need mutex for popen() in Windows and NetWare, because it doesn't chdir() on UNIX */
|
||||
#if (defined(TSRM_WIN32) || defined(NETWARE)) && defined(ZTS)
|
||||
MUTEX_T cwd_mutex;
|
||||
#endif
|
||||
@@ -210,7 +210,7 @@ CWD_API void virtual_cwd_startup(void)
|
||||
cwd_globals_ctor(&cwd_globals TSRMLS_CC);
|
||||
#endif
|
||||
|
||||
#if (defined(TSRM_WIN32) || defined(NETWARE)) && defined(ZTS)
|
||||
#if defined(TSRM_WIN32) && defined(ZTS)
|
||||
cwd_mutex = tsrm_mutex_alloc();
|
||||
#endif
|
||||
}
|
||||
@@ -220,7 +220,7 @@ CWD_API void virtual_cwd_shutdown(void)
|
||||
#ifndef ZTS
|
||||
cwd_globals_dtor(&cwd_globals TSRMLS_CC);
|
||||
#endif
|
||||
#if (defined(TSRM_WIN32) || defined(NETWARE)) && defined(ZTS)
|
||||
#if defined(TSRM_WIN32) && defined(ZTS)
|
||||
tsrm_mutex_free(cwd_mutex);
|
||||
#endif
|
||||
|
||||
@@ -331,29 +331,6 @@ CWD_API int virtual_file_ex(cwd_state *state, const char *path, verify_path_func
|
||||
}
|
||||
free(tmp);
|
||||
}
|
||||
#endif
|
||||
#if defined(TSRM_WIN32)
|
||||
{
|
||||
char *dummy = NULL;
|
||||
char *new_path;
|
||||
int new_path_length;
|
||||
|
||||
new_path_length = GetLongPathName(path, dummy, 0) + 1;
|
||||
if (new_path_length == 0) {
|
||||
return 1;
|
||||
}
|
||||
new_path = (char *) malloc(new_path_length);
|
||||
if (!new_path) {
|
||||
return 1;
|
||||
}
|
||||
|
||||
if (GetLongPathName(path, new_path, new_path_length) != 0) {
|
||||
path = new_path;
|
||||
path_length = new_path_length;
|
||||
} else {
|
||||
free(new_path);
|
||||
}
|
||||
}
|
||||
#endif
|
||||
free_path = path_copy = tsrm_strndup(path, path_length);
|
||||
|
||||
@@ -366,6 +343,9 @@ CWD_API int virtual_file_ex(cwd_state *state, const char *path, verify_path_func
|
||||
copy_amount = COPY_WHEN_ABSOLUTE(path_copy);
|
||||
is_absolute = 1;
|
||||
#ifdef TSRM_WIN32
|
||||
} else if (IS_UNC_PATH(path_copy, path_length)) {
|
||||
copy_amount = 2;
|
||||
is_absolute = 1;
|
||||
} else if (IS_SLASH(path_copy[0])) {
|
||||
copy_amount = 2;
|
||||
#endif
|
||||
@@ -562,6 +542,7 @@ CWD_API FILE *virtual_fopen(const char *path, const char *mode TSRMLS_DC)
|
||||
return f;
|
||||
}
|
||||
|
||||
#if !defined(TSRM_WIN32)
|
||||
CWD_API int virtual_access(const char *pathname, int mode TSRMLS_DC)
|
||||
{
|
||||
cwd_state new_state;
|
||||
@@ -570,16 +551,13 @@ CWD_API int virtual_access(const char *pathname, int mode TSRMLS_DC)
|
||||
CWD_STATE_COPY(&new_state, &CWDG(cwd));
|
||||
virtual_file_ex(&new_state, pathname, NULL, 1);
|
||||
|
||||
#if defined(TSRM_WIN32)
|
||||
ret = tsrm_win32_access(new_state.cwd, mode);
|
||||
#else
|
||||
ret = access(new_state.cwd, mode);
|
||||
#endif
|
||||
|
||||
CWD_STATE_FREE(&new_state);
|
||||
|
||||
return ret;
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
#if HAVE_UTIME
|
||||
|
||||
+8
-24
@@ -4,10 +4,10 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1997-2003 The PHP Group |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 3.0 of the PHP license, |
|
||||
| This source file is subject to version 2.02 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. |
|
||||
| available at through the world-wide-web at |
|
||||
| http://www.php.net/license/2_02.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. |
|
||||
@@ -57,8 +57,9 @@ typedef unsigned short mode_t;
|
||||
#define IS_SLASH_P(c) (*(c) == '/' || \
|
||||
(*(c) == '\\' && !IsDBCSLeadByte(*(c-1))))
|
||||
|
||||
/* COPY_WHEN_ABSOLUTE is 2 under Win32 because by chance both regular absolute paths
|
||||
in the file system and UNC paths need copying of two characters */
|
||||
/* COPY_WHEN_ABSOLUTE also takes path as argument because netware needs it
|
||||
* to account for volume name that is unique to NetWare absolute paths
|
||||
*/
|
||||
#define COPY_WHEN_ABSOLUTE(path) 2
|
||||
#define IS_UNC_PATH(path, len) \
|
||||
(len >= 2 && IS_SLASH(path[0]) && IS_SLASH(path[1]))
|
||||
@@ -73,7 +74,6 @@ typedef unsigned short mode_t;
|
||||
#define DEFAULT_SLASH '/'
|
||||
#define DEFAULT_DIR_SEPARATOR ';'
|
||||
#define IS_SLASH(c) ((c) == '/' || (c) == '\\')
|
||||
#define IS_SLASH_P(c) IS_SLASH(*(c))
|
||||
#define COPY_WHEN_ABSOLUTE(path) \
|
||||
(strchr(path, ':') - path + 1) /* Take the volume name which ends with a colon */
|
||||
#define IS_ABSOLUTE_PATH(path, len) \
|
||||
@@ -154,21 +154,9 @@ CWD_API int virtual_mkdir(const char *pathname, mode_t mode TSRMLS_DC);
|
||||
CWD_API int virtual_rmdir(const char *pathname TSRMLS_DC);
|
||||
CWD_API DIR *virtual_opendir(const char *pathname TSRMLS_DC);
|
||||
CWD_API FILE *virtual_popen(const char *command, const char *type TSRMLS_DC);
|
||||
|
||||
#if !defined(TSRM_WIN32)
|
||||
CWD_API int virtual_access(const char *pathname, int mode TSRMLS_DC);
|
||||
#if defined(TSRM_WIN32)
|
||||
/* these are not defined in win32 headers */
|
||||
#ifndef W_OK
|
||||
#define W_OK 0x02
|
||||
#endif
|
||||
#ifndef R_OK
|
||||
#define R_OK 0x04
|
||||
#endif
|
||||
#ifndef X_OK
|
||||
#define X_OK 0x01
|
||||
#endif
|
||||
#ifndef F_OK
|
||||
#define F_OK 0x00
|
||||
#endif
|
||||
#endif
|
||||
|
||||
/* On AIX & Tru64 when a file does not exist realpath() returns
|
||||
@@ -264,11 +252,7 @@ typedef struct _virtual_cwd_globals {
|
||||
#define VCWD_RMDIR(pathname) rmdir(pathname)
|
||||
#define VCWD_OPENDIR(pathname) opendir(pathname)
|
||||
#define VCWD_POPEN(command, type) popen(command, type)
|
||||
#if defined(TSRM_WIN32)
|
||||
#define VCWD_ACCESS(pathname, mode) tsrm_win32_access(pathname, mode)
|
||||
#else
|
||||
#define VCWD_ACCESS(pathname, mode) access(pathname, mode)
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_REALPATH
|
||||
#if defined(__osf__) || defined(_AIX)
|
||||
|
||||
+4
-20
@@ -4,10 +4,10 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1997-2003 The PHP Group |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 3.0 of the PHP license, |
|
||||
| This source file is subject to version 2.02 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. |
|
||||
| available at through the world-wide-web at |
|
||||
| http://www.php.net/license/2_02.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. |
|
||||
@@ -24,8 +24,6 @@
|
||||
#include <process.h>
|
||||
#include <time.h>
|
||||
|
||||
#define TSRM_INCLUDE_FULL_WINDOWS_HEADERS
|
||||
|
||||
#include "TSRM.h"
|
||||
|
||||
#ifdef TSRM_WIN32
|
||||
@@ -83,19 +81,6 @@ TSRM_API void tsrm_win32_shutdown(void)
|
||||
#endif
|
||||
}
|
||||
|
||||
TSRM_API int tsrm_win32_access(const char *pathname, int mode)
|
||||
{
|
||||
SHFILEINFO sfi;
|
||||
|
||||
if (mode == 1 /*X_OK*/) {
|
||||
return access(pathname, 0) == 0 &&
|
||||
SHGetFileInfo(pathname, 0, &sfi, sizeof(SHFILEINFO), SHGFI_EXETYPE) != 0 ? 0 : -1;
|
||||
} else {
|
||||
return access(pathname, mode);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
static process_pair *process_get(FILE *stream TSRMLS_DC)
|
||||
{
|
||||
process_pair *ptr;
|
||||
@@ -383,5 +368,4 @@ TSRM_API char *realpath(char *orig_path, char *buffer)
|
||||
}
|
||||
return buffer;
|
||||
}
|
||||
|
||||
#endif
|
||||
#endif
|
||||
+4
-5
@@ -4,10 +4,10 @@
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1997-2003 The PHP Group |
|
||||
+----------------------------------------------------------------------+
|
||||
| This source file is subject to version 3.0 of the PHP license, |
|
||||
| This source file is subject to version 2.02 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. |
|
||||
| available at through the world-wide-web at |
|
||||
| http://www.php.net/license/2_02.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. |
|
||||
@@ -95,7 +95,6 @@ TSRM_API void tsrm_win32_shutdown(void);
|
||||
TSRM_API FILE *popen_ex(const char *command, const char *type, const char *cwd, char *env);
|
||||
TSRM_API FILE *popen(const char *command, const char *type);
|
||||
TSRM_API int pclose(FILE *stream);
|
||||
TSRM_API int tsrm_win32_access(const char *pathname, int mode);
|
||||
|
||||
TSRM_API int shmget(int key, int size, int flags);
|
||||
TSRM_API void *shmat(int key, const void *shmaddr, int flags);
|
||||
@@ -103,4 +102,4 @@ TSRM_API int shmdt(const void *shmaddr);
|
||||
TSRM_API int shmctl(int key, int cmd, struct shmid_ds *buf);
|
||||
|
||||
TSRM_API char *realpath(char *orig_path, char *buffer);
|
||||
#endif
|
||||
#endif
|
||||
-15201
File diff suppressed because it is too large.
Load diff
@@ -1,186 +0,0 @@
|
||||
// $Header$
|
||||
|
||||
// FlexLexer.h -- define interfaces for lexical analyzer classes generated
|
||||
// by flex
|
||||
|
||||
// Copyright (c) 1993 The Regents of the University of California.
|
||||
// All rights reserved.
|
||||
//
|
||||
// This code is derived from software contributed to Berkeley by
|
||||
// Kent Williams and Tom Epperly.
|
||||
//
|
||||
// Redistribution and use in source and binary forms with or without
|
||||
// modification are permitted provided that: (1) source distributions retain
|
||||
// this entire copyright notice and comment, and (2) distributions including
|
||||
// binaries display the following acknowledgement: ``This product includes
|
||||
// software developed by the University of California, Berkeley and its
|
||||
// contributors'' in the documentation or other materials provided with the
|
||||
// distribution and in all advertising materials mentioning features or use
|
||||
// of this software. Neither the name of the University nor the names of
|
||||
// its contributors may be used to endorse or promote products derived from
|
||||
// this software without specific prior written permission.
|
||||
|
||||
// THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR IMPLIED
|
||||
// WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF
|
||||
// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
|
||||
|
||||
// This file defines FlexLexer, an abstract class which specifies the
|
||||
// external interface provided to flex C++ lexer objects, and yyFlexLexer,
|
||||
// which defines a particular lexer class.
|
||||
//
|
||||
// If you want to create multiple lexer classes, you use the -P flag
|
||||
// to rename each yyFlexLexer to some other xxFlexLexer. You then
|
||||
// include <FlexLexer.h> in your other sources once per lexer class:
|
||||
//
|
||||
// #undef yyFlexLexer
|
||||
// #define yyFlexLexer xxFlexLexer
|
||||
// #include <FlexLexer.h>
|
||||
//
|
||||
// #undef yyFlexLexer
|
||||
// #define yyFlexLexer zzFlexLexer
|
||||
// #include <FlexLexer.h>
|
||||
// ...
|
||||
|
||||
#ifndef FLEXLEXER_H
|
||||
// Never included before - need to define base class.
|
||||
#define FLEXLEXER_H
|
||||
#include <iostream.h>
|
||||
|
||||
extern "C++" {
|
||||
|
||||
struct yy_buffer_state;
|
||||
typedef int yy_state_type;
|
||||
|
||||
class FlexLexer {
|
||||
public:
|
||||
virtual ~FlexLexer() { }
|
||||
|
||||
const char* YYText() { return yytext; }
|
||||
int YYLeng() { return yyleng; }
|
||||
|
||||
virtual void
|
||||
yy_switch_to_buffer( struct yy_buffer_state* new_buffer ) = 0;
|
||||
virtual struct yy_buffer_state*
|
||||
yy_create_buffer( istream* s, int size ) = 0;
|
||||
virtual void yy_delete_buffer( struct yy_buffer_state* b ) = 0;
|
||||
virtual void yyrestart( istream* s ) = 0;
|
||||
|
||||
virtual int yylex() = 0;
|
||||
|
||||
// Call yylex with new input/output sources.
|
||||
int yylex( istream* new_in, ostream* new_out = 0 )
|
||||
{
|
||||
switch_streams( new_in, new_out );
|
||||
return yylex();
|
||||
}
|
||||
|
||||
// Switch to new input/output streams. A nil stream pointer
|
||||
// indicates "keep the current one".
|
||||
virtual void switch_streams( istream* new_in = 0,
|
||||
ostream* new_out = 0 ) = 0;
|
||||
|
||||
int lineno() const { return yylineno; }
|
||||
|
||||
int debug() const { return yy_flex_debug; }
|
||||
void set_debug( int flag ) { yy_flex_debug = flag; }
|
||||
|
||||
protected:
|
||||
char* yytext;
|
||||
int yyleng;
|
||||
int yylineno; // only maintained if you use %option yylineno
|
||||
int yy_flex_debug; // only has effect with -d or "%option debug"
|
||||
};
|
||||
|
||||
}
|
||||
#endif
|
||||
|
||||
#if defined(yyFlexLexer) || ! defined(yyFlexLexerOnce)
|
||||
// Either this is the first time through (yyFlexLexerOnce not defined),
|
||||
// or this is a repeated include to define a different flavor of
|
||||
// yyFlexLexer, as discussed in the flex man page.
|
||||
#define yyFlexLexerOnce
|
||||
|
||||
class yyFlexLexer : public FlexLexer {
|
||||
public:
|
||||
// arg_yyin and arg_yyout default to the cin and cout, but we
|
||||
// only make that assignment when initializing in yylex().
|
||||
yyFlexLexer( istream* arg_yyin = 0, ostream* arg_yyout = 0 );
|
||||
|
||||
virtual ~yyFlexLexer();
|
||||
|
||||
void yy_switch_to_buffer( struct yy_buffer_state* new_buffer );
|
||||
struct yy_buffer_state* yy_create_buffer( istream* s, int size );
|
||||
void yy_delete_buffer( struct yy_buffer_state* b );
|
||||
void yyrestart( istream* s );
|
||||
|
||||
virtual int yylex();
|
||||
virtual void switch_streams( istream* new_in, ostream* new_out );
|
||||
|
||||
protected:
|
||||
virtual int LexerInput( char* buf, int max_size );
|
||||
virtual void LexerOutput( const char* buf, int size );
|
||||
virtual void LexerError( const char* msg );
|
||||
|
||||
void yyunput( int c, char* buf_ptr );
|
||||
int yyinput();
|
||||
|
||||
void yy_load_buffer_state();
|
||||
void yy_init_buffer( struct yy_buffer_state* b, istream* s );
|
||||
void yy_flush_buffer( struct yy_buffer_state* b );
|
||||
|
||||
int yy_start_stack_ptr;
|
||||
int yy_start_stack_depth;
|
||||
int* yy_start_stack;
|
||||
|
||||
void yy_push_state( int new_state );
|
||||
void yy_pop_state();
|
||||
int yy_top_state();
|
||||
|
||||
yy_state_type yy_get_previous_state();
|
||||
yy_state_type yy_try_NUL_trans( yy_state_type current_state );
|
||||
int yy_get_next_buffer();
|
||||
|
||||
istream* yyin; // input source for default LexerInput
|
||||
ostream* yyout; // output sink for default LexerOutput
|
||||
|
||||
struct yy_buffer_state* yy_current_buffer;
|
||||
|
||||
// yy_hold_char holds the character lost when yytext is formed.
|
||||
char yy_hold_char;
|
||||
|
||||
// Number of characters read into yy_ch_buf.
|
||||
int yy_n_chars;
|
||||
|
||||
// Points to current character in buffer.
|
||||
char* yy_c_buf_p;
|
||||
|
||||
int yy_init; // whether we need to initialize
|
||||
int yy_start; // start state number
|
||||
|
||||
// Flag which is used to allow yywrap()'s to do buffer switches
|
||||
// instead of setting up a fresh yyin. A bit of a hack ...
|
||||
int yy_did_buffer_switch_on_eof;
|
||||
|
||||
// The following are not always needed, but may be depending
|
||||
// on use of certain flex features (like REJECT or yymore()).
|
||||
|
||||
yy_state_type yy_last_accepting_state;
|
||||
char* yy_last_accepting_cpos;
|
||||
|
||||
yy_state_type* yy_state_buf;
|
||||
yy_state_type* yy_state_ptr;
|
||||
|
||||
char* yy_full_match;
|
||||
int* yy_full_state;
|
||||
int yy_full_lp;
|
||||
|
||||
int yy_lp;
|
||||
int yy_looking_for_trail_begin;
|
||||
|
||||
int yy_more_flag;
|
||||
int yy_more_len;
|
||||
int yy_more_offset;
|
||||
int yy_prev_more_offset;
|
||||
};
|
||||
|
||||
#endif
|
||||
@@ -1,56 +0,0 @@
|
||||
--------------------------------------------------------------------
|
||||
The Zend Engine License, Version 2.00
|
||||
Copyright (c) 1999-2003 Zend Technologies Ltd. All rights reserved.
|
||||
--------------------------------------------------------------------
|
||||
|
||||
Redistribution and use in source and binary forms, with or without
|
||||
modification, is permitted provided that the following conditions
|
||||
are met:
|
||||
|
||||
1. Redistributions of source code must retain the above copyright
|
||||
notice, this list of conditions and the following disclaimer.
|
||||
|
||||
2. Redistributions in binary form must reproduce the above
|
||||
copyright notice, this list of conditions and the following
|
||||
disclaimer in the documentation and/or other materials provided
|
||||
with the distribution.
|
||||
|
||||
3. The names "Zend" and "Zend Engine" must not be used to endorse
|
||||
or promote products derived from this software without prior
|
||||
permission from Zend Technologies Ltd. For written permission,
|
||||
please contact license@zend.com.
|
||||
|
||||
4. Zend Technologies Ltd. may publish revised and/or new versions
|
||||
of the license from time to time. Each version will be given a
|
||||
distinguishing version number.
|
||||
Once covered code has been published under a particular version
|
||||
of the license, you may always continue to use it under the
|
||||
terms of that version. You may also choose to use such covered
|
||||
code under the terms of any subsequent version of the license
|
||||
published by Zend Technologies Ltd. No one other than Zend
|
||||
Technologies Ltd. has the right to modify the terms applicable
|
||||
to covered code created under this License.
|
||||
|
||||
5. Redistributions of any form whatsoever must retain the following
|
||||
acknowledgment:
|
||||
"This product includes the Zend Engine, freely available at
|
||||
http://www.zend.com"
|
||||
|
||||
6. All advertising materials mentioning features or use of this
|
||||
software must display the following acknowledgment:
|
||||
"The Zend Engine is freely available at http://www.zend.com"
|
||||
|
||||
THIS SOFTWARE IS PROVIDED BY ZEND TECHNOLOGIES LTD. ``AS IS'' AND
|
||||
ANY EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
|
||||
THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
|
||||
PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL ZEND
|
||||
TECHNOLOGIES LTD. BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
|
||||
USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
|
||||
ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
|
||||
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
|
||||
OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
||||
SUCH DAMAGE.
|
||||
|
||||
--------------------------------------------------------------------
|
||||
@@ -1,53 +0,0 @@
|
||||
## Process this file with automake to produce Makefile.in -*- makefile -*-
|
||||
|
||||
#CLEANFILES = zend_language_parser.c zend_language_parser.h zend_language_scanner.c zend_language_parser.output zend_ini_parser.c zend_ini_parser.h zend_ini_scanner.c zend_ini_parser.output
|
||||
|
||||
AUTOMAKE_OPTIONS=foreign
|
||||
noinst_LTLIBRARIES=libZend.la
|
||||
|
||||
libZend_la_SOURCES=\
|
||||
zend_language_parser.y zend_language_scanner.l \
|
||||
zend_ini_parser.y zend_ini_scanner.l \
|
||||
zend_alloc.c zend_compile.c zend_constants.c zend_dynamic_array.c \
|
||||
zend_execute.c zend_execute_API.c zend_highlight.c zend_llist.c \
|
||||
zend_opcode.c zend_operators.c zend_ptr_stack.c zend_stack.c \
|
||||
zend_variables.c zend.c zend_API.c zend_extensions.c zend_hash.c \
|
||||
zend_list.c zend_indent.c zend_builtin_functions.c zend_sprintf.c \
|
||||
zend_ini.c zend_qsort.c zend_objects.c zend_object_handlers.c \
|
||||
zend_objects_API.c zend_ts_hash.c zend_stream.c zend_mm.c \
|
||||
zend_default_classes.c zend_reflection_api.c \
|
||||
zend_iterators.c zend_interfaces.c
|
||||
|
||||
libZend_la_LDFLAGS =
|
||||
libZend_la_LIBADD = @ZEND_EXTRA_LIBS@
|
||||
|
||||
# automake isn't too clever about "non-standard" use of lex and yacc
|
||||
|
||||
$(libZend_la_OBJECTS): zend_language_parser.h
|
||||
|
||||
zend_ini_scanner.lo: zend_ini_parser.h
|
||||
|
||||
# Language parser/scanner rules
|
||||
|
||||
zend_language_scanner.c: $(srcdir)/zend_language_scanner.l
|
||||
$(LEX) -Pzend -S$(srcdir)/flex.skl -o$@ -i $(srcdir)/zend_language_scanner.l
|
||||
|
||||
zend_language_parser.h: zend_language_parser.c
|
||||
zend_language_parser.c: $(srcdir)/zend_language_parser.y
|
||||
$(YACC) -p zend -v -d $(srcdir)/zend_language_parser.y -o zend_language_parser.c
|
||||
|
||||
# INI parser/scanner rules
|
||||
|
||||
zend_ini_parser.c: $(srcdir)/zend_ini_parser.y
|
||||
$(YACC) -p ini_ -v -d $(srcdir)/zend_ini_parser.y -o zend_ini_parser.c
|
||||
|
||||
zend_ini_scanner.c: $(srcdir)/zend_ini_scanner.l
|
||||
$(LEX) -Pini_ -S$(srcdir)/flex.skl -o$@ -i $(srcdir)/zend_ini_scanner.l
|
||||
|
||||
zend_ini_parser.h: zend_ini_parser.c
|
||||
|
||||
depend:
|
||||
|
||||
zend_execute.lo: $(srcdir)/zend_execute.c
|
||||
$(LIBTOOL) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(CPPFLAGS) $(INLINE_CFLAGS) -c $(srcdir)/zend_execute.c
|
||||
|
||||
@@ -1,195 +0,0 @@
|
||||
Creating an object
|
||||
------------------
|
||||
|
||||
Object can be created in the following ways:
|
||||
|
||||
1. As a result of a function call. E.g.:
|
||||
|
||||
$foo = create_new_foo("parameter");
|
||||
$foo->run();
|
||||
|
||||
The function should create a new zval, create new object and get the
|
||||
handle for it, set handle and handler table as needed. Note that the
|
||||
handle is the only ID of the object, so it should be enough to
|
||||
identify it.
|
||||
|
||||
2. Overriding create_object handler for class. E.g.:
|
||||
|
||||
$foo = new Java("some.Class.here", "parameter");
|
||||
$foo->run();
|
||||
|
||||
The create_object handler function should create a new zval, create
|
||||
new object and get the handle for it, set handle and handler table as
|
||||
needed, and also provide constructor method that would handle
|
||||
constructor call. The get_constructor handler table entry should be
|
||||
used for that. Do not rely class entry's constructor, unless you refer
|
||||
to it from get_constructor handler.
|
||||
|
||||
Object maintenance
|
||||
------------------
|
||||
|
||||
The handlers add_ref and del_ref are called when a new zval referring
|
||||
to the object is created. This does not create a new object - both
|
||||
zvals still refer to the same object.
|
||||
|
||||
clone_obj handler should create a new object, identical to an old one,
|
||||
but being a separate entity.
|
||||
|
||||
delete_obj should destroy an object, all references to it become
|
||||
invalid.
|
||||
|
||||
Object access - read
|
||||
--------------------
|
||||
|
||||
read_property is used to read object's property. This value is not
|
||||
meant to be changed. The handler returns zval * with the value.
|
||||
|
||||
Object access - write
|
||||
---------------------
|
||||
|
||||
write_property is used to directly write object's property by
|
||||
name. This handler is used to assign property variables or to change them
|
||||
in operations like += or ++ (unless get_property_zval_ptr is also set).
|
||||
|
||||
get_property_zval_ptr is used to obtain pointer to modifyable zval for
|
||||
operations like += or ++. This should be used only if your object model
|
||||
stores properties as real zval's that can be modified from outside.
|
||||
Otherwise this handler should be NULL and the engine will use
|
||||
read_property and write_property instead.
|
||||
|
||||
get_property_ptr is used to obtain zval ** for future writing to
|
||||
it. If your object properties are stored as zval*, return real place
|
||||
where the property is stored. If the aren't, the best way is to create
|
||||
proxy object and handle it via get and set methods (see below).
|
||||
This method is meant to be used for send-by-reference and assign-by-reference
|
||||
use of object properties. If you don;t want to implement property
|
||||
referencing for your objects, you can set this handler to NULL.
|
||||
|
||||
get and set handlers are used when engine needs to access the object
|
||||
as a value. E.g., in the following situation:
|
||||
|
||||
$foo =& $obj->bar;
|
||||
$foo = 1;
|
||||
|
||||
if $foo is an object (e.g., proxy object from get_property_ptr) it
|
||||
would be accessed using write handler.
|
||||
|
||||
Object access - method call
|
||||
---------------------------
|
||||
|
||||
get_method handler is used to find method description by name. It
|
||||
should set right type, function name and parameter mask for the
|
||||
method. If the type is ZEND_OVERLOADED_FUNCTION, the method would be
|
||||
called via call_method handler, otherwise it would be called with
|
||||
standard Zend means.
|
||||
|
||||
get_constructor performs the same function as get_method, but for the
|
||||
object constructor.
|
||||
|
||||
call_method handler is used to perform method call. Parameters are
|
||||
passed like to any other Zend internal function.
|
||||
|
||||
Object - comparison
|
||||
-------------------
|
||||
|
||||
Objects can be compared via compare_objects handler. This is used with
|
||||
== operation, === compares objects by handles, i.e., return true if
|
||||
and only if it's really the same object. Note that objects from
|
||||
different object types (i.e., having different handlers) can not be
|
||||
compared.
|
||||
|
||||
Objects - reflection
|
||||
--------------------
|
||||
|
||||
get_class_name is used to retrieve class name of the object.
|
||||
get_class_entry returns class entry (zend_class_entry) for the object,
|
||||
in case there exists PHP class for it.
|
||||
No other reflection functions are currently implemented.
|
||||
|
||||
Objects - data structures and handlers
|
||||
---------------------------------------
|
||||
|
||||
The object is represented by the following structure:
|
||||
|
||||
struct _zend_object_value {
|
||||
zend_object_handle handle;
|
||||
zend_object_handlers *handlers;
|
||||
};
|
||||
|
||||
handle is an ID of the object among the objects of the same type (not
|
||||
class!). The type of the object and how it behaves is determined by
|
||||
the handler table.
|
||||
|
||||
typedef struct _zend_object_handlers {
|
||||
zend_object_add_ref_t add_ref;
|
||||
zend_object_del_ref_t del_ref;
|
||||
zend_object_delete_obj_t delete_obj;
|
||||
zend_object_clone_obj_t clone_obj;
|
||||
zend_object_read_property_t read_property;
|
||||
zend_object_write_property_t write_property;
|
||||
zend_object_get_property_ptr_t get_property_ptr;
|
||||
zend_object_get_property_zval_ptr_t get_property_zval_ptr;
|
||||
zend_object_get_t get;
|
||||
zend_object_set_t set;
|
||||
zend_object_has_property_t has_property;
|
||||
zend_object_unset_property_t unset_property;
|
||||
zend_object_get_properties_t get_properties;
|
||||
zend_object_get_method_t get_method;
|
||||
zend_object_call_method_t call_method;
|
||||
zend_object_get_constructor_t get_constructor;
|
||||
zend_object_get_class_entry_t get_class_entry;
|
||||
zend_object_get_class_name_t get_class_name;
|
||||
zend_object_compare_t compare_objects;
|
||||
} zend_object_handlers;
|
||||
|
||||
See zend_object_handlers.h for prototypes. All objects are passed as zval's.
|
||||
|
||||
Handlers explained:
|
||||
|
||||
add_ref - called when a copy of the object handle is created.
|
||||
|
||||
del_ref - called when a copy of the object handle is destroyed.
|
||||
|
||||
delete_obj - called when an object needs to be destroyed.
|
||||
|
||||
clone_obj - called when a new object identical to an old one should be
|
||||
created (unlike Zend Engine 1, this never happens unless explicitly
|
||||
asked for).
|
||||
|
||||
read_property - returns zval *, containing the value of the
|
||||
property. Is used when value of the property should be retrieved for
|
||||
reading.
|
||||
|
||||
write_property - assigns value to certain property of the object.
|
||||
|
||||
get_property_zval_ptr - retrieves zval** for being directly modified by
|
||||
the engine. If your properties are not zval's, don't define it.
|
||||
|
||||
get_property_ptr - retrieves zval** for the property of the value, to
|
||||
be used for read and write. If object properties are not zval's
|
||||
natively, this method should create and return proxy object for use
|
||||
with get and set methods.
|
||||
|
||||
get - retrieves zval* for object contents. To be used mainly with
|
||||
proxy objects from get_property_ptr, but also may be used for
|
||||
convert_to_* functions.
|
||||
|
||||
set - sets value for object contents. To be used mainly with
|
||||
proxy objects from get_property_ptr.
|
||||
|
||||
has_property - checks if the object has certain property set.
|
||||
|
||||
unset_property - removes value for the property of the object
|
||||
|
||||
get_method - retrieves description of the method
|
||||
|
||||
call_method - calls the method (parameters should be put on stack like
|
||||
for any other PHP internal function).
|
||||
|
||||
get_constructor - get description for the object constructor method
|
||||
|
||||
get_class_entry - should return the class entry for the object
|
||||
|
||||
get_class_name - get the name of the class the object belongs to
|
||||
|
||||
compare_objects - compares if two objects are equal
|
||||
@@ -1,136 +0,0 @@
|
||||
Revamped object model using object handles
|
||||
===========================================
|
||||
|
||||
Background
|
||||
----------
|
||||
|
||||
In the Zend Engine 1.0 (and its predecessor the PHP 3 scripting
|
||||
engine) the object model's design is that instantiated objects are
|
||||
language values. This means that when programmers are performing
|
||||
operations, such variable assignment and passing parameters to
|
||||
functions, objects are handled very similarly to the way other
|
||||
primitive types are handled such as integers and strings.
|
||||
Semantically this means that the whole object is being copied. The
|
||||
approach Java takes is different where one refers to objects by handle
|
||||
and not by value (one can think of a handle as an objects' ID).
|
||||
|
||||
Need
|
||||
----
|
||||
|
||||
Unfortunately, the approach taken up to now has severely limited the
|
||||
Zend Engine's object oriented model, both feature and simplicity
|
||||
wise. One of the main problems with the former approach is that object
|
||||
instantiation and duplication is very hard to control, a problem which
|
||||
can not only lead to inefficient development but also often to strange
|
||||
run-time behavior. Changing the object model to a handle oriented
|
||||
model will allow the addressing of many needs such as destructors,
|
||||
de-referencing method return values, tight control of object
|
||||
duplication and more.
|
||||
|
||||
Overview
|
||||
--------
|
||||
|
||||
The proposed object model is very much influenced by the Java
|
||||
model. In general, when you create a new object you will be getting a
|
||||
handle to the object instead of the object itself. When this handle is
|
||||
sent to functions, assigned and copied it is only the handle which is
|
||||
copied/sent/assigned. The object itself is never copied nor
|
||||
duplicated. This results in all handles of this object to always point
|
||||
at the same object making it a very consistent solution and saving
|
||||
unnecessary duplication and confusing behavior.
|
||||
|
||||
Functionality
|
||||
-------------
|
||||
|
||||
After this change the basic use of objects will be almost identical to
|
||||
previous versions of the scripting engine. However, you won't bump
|
||||
into awkward and confusing copying & destructing of objects. In order
|
||||
to create and use a new object instance you will do the following:
|
||||
$object = new MyClass(); $object->method();
|
||||
|
||||
The previous code will assign $object the handle of a new instance of
|
||||
the class MyClass and call one of its methods.
|
||||
|
||||
|
||||
Consider the following code:
|
||||
|
||||
1 class MyClass
|
||||
2 {
|
||||
3 function setMember($value)
|
||||
4 {
|
||||
5 $this->member = $value;
|
||||
6 }
|
||||
7
|
||||
8 function getMember()
|
||||
9 {
|
||||
10 return $this->member;
|
||||
11 }
|
||||
12 }
|
||||
13
|
||||
14 function foo($obj)
|
||||
15 {
|
||||
16 $obj->setMember("foo");
|
||||
17 }
|
||||
18
|
||||
19 $object = new MyClass();
|
||||
20 $object->setMember("bar");
|
||||
21 foo($object);
|
||||
22 print $object->getMember();
|
||||
|
||||
Without the new Java-like handles, at line 20 the objects' data member
|
||||
member is set to the string value of "bar". Because of the internal
|
||||
representation of objects in the Zend Engine 1.0, the object is marked
|
||||
as a reference, and when it is sent by value to the function foo, it
|
||||
is duplicated (!). Therefore, the call to foo() on line 21 will
|
||||
result in the $obj->setMember("foo") call being called on a duplicate
|
||||
of $object. Line 22 will then result in "bar" being printed.
|
||||
|
||||
This is how the scripting engine has worked until today. Most
|
||||
developers are probably unaware of the fact that they aren't always
|
||||
talking to the same object but often duplicates; others may have
|
||||
realized this can usually be solved by always passing objects by
|
||||
reference (unless a replica is actually desired, which is uncommon).
|
||||
|
||||
The new object model will allow for a much more intuitive
|
||||
implementation of the code. On line 21, the object's handle (ID) is
|
||||
passed to foo() by value. Inside foo(), the object is fetched
|
||||
according to this handle and, therefore, the setMember() method is
|
||||
called on the originally instantiated object and not a copy. Line 22
|
||||
will therefore result in "foo" being printed. This approach gives
|
||||
developers tighter control of when objects are created and duplicated.
|
||||
An additional not-as-important benefit is that the object handle will
|
||||
be passed to foo() by value, which most probably will also save
|
||||
unnecessary duplication of the value containing the ID itself and thus
|
||||
additionally improving run-time performance.
|
||||
|
||||
This was just a simple description of why the new object model solves
|
||||
awkward behavior and makes object handling much easier, intuitive and
|
||||
efficient. The importance of this change goes far beyond what is
|
||||
mentioned in this section as you will see in further sections which
|
||||
describe new features with a majority of them being based on this
|
||||
change.
|
||||
|
||||
Compatibility Notes
|
||||
--------------------
|
||||
|
||||
Many PHP programmers aren't even aware of the copying quirks of the
|
||||
current object model and, therefore, there is a relatively good chance
|
||||
that the amount of PHP applications that will work out of the box or
|
||||
after a very small amount of modifications would be high.
|
||||
|
||||
To simplify migration, version 2.0 will support an optional
|
||||
'auto-clone' feature, which will perform a cloning of the object
|
||||
whenever it would have been copied in version 1.0. Optionally, it
|
||||
will also be possible to request that the engine will emit an E_NOTICE
|
||||
message whenever such an automatic clone occurs, in order to allow
|
||||
developers to gradually migrate to the version 2.0-style behavior
|
||||
(without automatic clones).
|
||||
|
||||
Dependencies
|
||||
------------
|
||||
|
||||
The new object model is not dependent on other features. Many of the
|
||||
other Zend Engine 2.0 features, such as the $foo->bar()->barbara()
|
||||
syntax, destructors and others completely rely on this new object
|
||||
model.
|
||||
|
||||
@@ -1,169 +0,0 @@
|
||||
Title: Zend 2.0 Namespaces
|
||||
Version: $Revision$
|
||||
Status: draft
|
||||
Maintainer: Stig S. Bakken <ssb@php.net>
|
||||
Created: 2001-09-08
|
||||
Modified: 2001-09-08
|
||||
|
||||
|
||||
1. Background/Need
|
||||
==================
|
||||
|
||||
PHP and Zend 1.0 have come to a point where a lot of reusable code is
|
||||
being written; from simple functions and classes to entire application
|
||||
frameworks. It is becoming increasingly difficult to avoid symbol
|
||||
name collisions with the current scoping methods.
|
||||
|
||||
The symbol scopes available in Zend 1.0 are the global scope, the
|
||||
class scope and the function scope. All scopes but classes may
|
||||
contain variables, only the class and global scopes may contain
|
||||
functions, while only the global scope may contain constants and
|
||||
classes. This means that all of Zend 1.0's scoping methods are
|
||||
inherently limited for solving symbol name collision problems.
|
||||
|
||||
|
||||
2. Overview
|
||||
===========
|
||||
|
||||
Namespaces in Zend 2.0 provide a way to manage the symbol collision
|
||||
problem by making it possible to define multiple symbol tables able to
|
||||
contain all types of symbols. Zend will get the notion of a current
|
||||
namespace, defaulting to the current global one. The current name
|
||||
space may be changed on a file-by-file basis. Symbols in other name
|
||||
spaces than the current one may be referenced using a new namespace
|
||||
operator. It will be possible to "import" symbols from one namespace
|
||||
into another.
|
||||
|
||||
|
||||
3. Functionality
|
||||
================
|
||||
|
||||
3.1. Namespace Syntax
|
||||
=====================
|
||||
|
||||
The namespace operator ":" is used to refer to symbols in other
|
||||
namespaces than the current one:
|
||||
|
||||
Class: Namespace:class
|
||||
Function: Namespace:function
|
||||
Static method: Namespace:class::method
|
||||
Variable: $Namespace:variable
|
||||
Constant: Namespace:CONSTANT
|
||||
Class variable: $Namespace:class::variable
|
||||
|
||||
To refer to symbols in the global namespace, symbols are prefixed with
|
||||
only the namespace operator:
|
||||
|
||||
Class: :class
|
||||
Function: :function
|
||||
Static method: :class::method
|
||||
Variable: $:variable
|
||||
Constant: :CONSTANT
|
||||
Class variable: $:class::variable
|
||||
|
||||
Note: $:variable will effectively be just another syntax for
|
||||
$GLOBALS['variable'].
|
||||
|
||||
A namespace may have a name containing a ":", it is always the last
|
||||
":" character in the symbol qualifier that is the actual namespace
|
||||
operator:
|
||||
|
||||
Class: Name:Space:class
|
||||
Function: Name:Space:function
|
||||
Static method: Name:Space:class::method
|
||||
Variable: $Name:Space:variable
|
||||
Constant: Name:Space:CONSTANT
|
||||
Class variable: $Name:Space:class::variable
|
||||
|
||||
(Here, the ":" between "Name" and "Space" is part of the name, it is
|
||||
the one after "Space" that is the namespace operator.)
|
||||
|
||||
|
||||
3.2. Defining Namespaces
|
||||
========================
|
||||
|
||||
Individual files may define a namespace that will apply to the entire
|
||||
file. If no "namespace" operator occurs in the file, it will be in
|
||||
the global namespace:
|
||||
|
||||
1 namespace HTML;
|
||||
2
|
||||
3 class Form {
|
||||
4 function Form() {
|
||||
5 // constructor
|
||||
6 }
|
||||
7 // ...
|
||||
8 }
|
||||
|
||||
Or with the "nested" name syntax:
|
||||
|
||||
1 namespace HTML:Form;
|
||||
2
|
||||
3 class Image {
|
||||
4 var $src;
|
||||
5 function Image($src) {
|
||||
6 $this->src = $src;
|
||||
7 }
|
||||
8 // ...
|
||||
9 }
|
||||
|
||||
Code executed within the "HTML" namespace may refer to the Form class
|
||||
as just "Form". Code executed from within other namespaces has to
|
||||
refer to it as "HTML:Form". The "namespace" statement must occur
|
||||
before any other statements in the file.
|
||||
|
||||
# [ssb 2001-09-08]:
|
||||
# Should it be possible to "add" symbols to a namespace by including a
|
||||
# second file with the same namespace statement?
|
||||
|
||||
|
||||
3.3. Importing Symbols
|
||||
======================
|
||||
|
||||
It is possible to import symbols from another namespace into the
|
||||
current one with the "import" statement:
|
||||
|
||||
import * from HTML; // all symbols
|
||||
|
||||
import Form from HTML; // single symbols
|
||||
|
||||
import Form,Table from HTML; // multiple symbols
|
||||
|
||||
There is a potential for name clashes between symols of different
|
||||
types that have the same qualifier syntax. These are resolved in this
|
||||
order: class, function, constant.
|
||||
|
||||
Optionally, the symbol type may be explicitly given to import (as
|
||||
"class", "function", "variable" or "constant"):
|
||||
|
||||
import class Form from HTML;
|
||||
|
||||
And finally, you may import all symbols of a given type:
|
||||
|
||||
import constant * from HTML:Table;
|
||||
|
||||
The namespace with its symbols must already be defined before using
|
||||
"import".
|
||||
|
||||
|
||||
4. Compatibility Notes
|
||||
======================
|
||||
|
||||
Old code that does not take advantage of namespaces will run without
|
||||
modifications.
|
||||
|
||||
|
||||
5. Dependencies
|
||||
===============
|
||||
|
||||
The class variable syntax depends on this class variables being
|
||||
implemented in the new ZE2 object model.
|
||||
|
||||
|
||||
6. Acknowledgements
|
||||
===================
|
||||
|
||||
Andi Gutmans <andi@zend.com> and Zeev Suraski <zeev@zend.com> for
|
||||
initial ZE2 namespaces proposal
|
||||
|
||||
Dean Hall <php@apt7.com> for the initial symbol qualification syntax
|
||||
@@ -1,72 +0,0 @@
|
||||
Title: Loose type requirements for functions
|
||||
Version: $Revision$
|
||||
Status: draft
|
||||
Maintainer: Brian Moon <brianm@dealnews.com>
|
||||
Created: 2001-09-17
|
||||
Modified: 2001-09-17
|
||||
|
||||
|
||||
1. Background/Need
|
||||
==================
|
||||
|
||||
Many internal function of PHP will reject parameters because of their
|
||||
type (the array and variable function come to mind). For userland
|
||||
this is not an easy task as there is no uniform way to do it. An
|
||||
addition to the engine for requiring loose types would allow
|
||||
delevopers to know that the data passed to their functions is of the
|
||||
correct type and reduce the need for duplicating the same code in
|
||||
every function to check for the type of data.
|
||||
|
||||
|
||||
2. Overview
|
||||
===========
|
||||
|
||||
Loose typing mostly means evaluating the contents of the variable and
|
||||
not the type of the variable itself. The requirements for this would
|
||||
and should work much like several of the is_* functions do now.
|
||||
|
||||
The typing of parameters would be optional and those not typed would
|
||||
simply continue to be treated as they are now.
|
||||
|
||||
3. Functionality
|
||||
================
|
||||
|
||||
3.1. Allowed Types
|
||||
==================
|
||||
|
||||
Only loose types should be needed to ensure the data is usable by the
|
||||
function. Duplicating the functionallity of is_scalar, is_resource,
|
||||
is_array and is_object should give developers all the information they
|
||||
need to use a variable correctly.
|
||||
|
||||
3.2. Syntax
|
||||
===========
|
||||
|
||||
The current function syntax should be expanded to allow typing of
|
||||
variables inline in a C style.
|
||||
|
||||
function foo ($var){
|
||||
}
|
||||
|
||||
could be changed to require an array such as:
|
||||
|
||||
function foo (array $var){
|
||||
}
|
||||
|
||||
3.3. Errors
|
||||
===========
|
||||
|
||||
Mis-matches in type should be reported as fatal errors and should halt
|
||||
the execution of a script as that function can not be run and code
|
||||
following could not reliably run.
|
||||
|
||||
|
||||
4. Compatibility Notes
|
||||
======================
|
||||
|
||||
Old code that does not take advantage of this will run without
|
||||
modifications.
|
||||
|
||||
|
||||
|
||||
|
||||
-1034
File diff suppressed because it is too large.
Load diff
-602
@@ -1,602 +0,0 @@
|
||||
# Microsoft Developer Studio Project File - Name="Zend" - Package Owner=<4>
|
||||
# Microsoft Developer Studio Generated Build File, Format Version 6.00
|
||||
# ** DO NOT EDIT **
|
||||
|
||||
# TARGTYPE "Win32 (x86) Static Library" 0x0104
|
||||
|
||||
CFG=Zend - Win32 Release_inline
|
||||
!MESSAGE This is not a valid makefile. To build this project using NMAKE,
|
||||
!MESSAGE use the Export Makefile command and run
|
||||
!MESSAGE
|
||||
!MESSAGE NMAKE /f "Zend.mak".
|
||||
!MESSAGE
|
||||
!MESSAGE You can specify a configuration when running NMAKE
|
||||
!MESSAGE by defining the macro CFG on the command line. For example:
|
||||
!MESSAGE
|
||||
!MESSAGE NMAKE /f "Zend.mak" CFG="Zend - Win32 Release_inline"
|
||||
!MESSAGE
|
||||
!MESSAGE Possible choices for configuration are:
|
||||
!MESSAGE
|
||||
!MESSAGE "Zend - Win32 Release" (based on "Win32 (x86) Static Library")
|
||||
!MESSAGE "Zend - Win32 Debug" (based on "Win32 (x86) Static Library")
|
||||
!MESSAGE "Zend - Win32 Release_inline" (based on "Win32 (x86) Static Library")
|
||||
!MESSAGE
|
||||
|
||||
# Begin Project
|
||||
# PROP AllowPerConfigDependencies 0
|
||||
# PROP Scc_ProjName ""
|
||||
# PROP Scc_LocalPath ""
|
||||
CPP=cl.exe
|
||||
RSC=rc.exe
|
||||
|
||||
!IF "$(CFG)" == "Zend - Win32 Release"
|
||||
|
||||
# PROP BASE Use_MFC 0
|
||||
# PROP BASE Output_Dir "Release"
|
||||
# PROP BASE Intermediate_Dir "Release"
|
||||
# PROP BASE Target_Dir ""
|
||||
# PROP Use_MFC 0
|
||||
# PROP Output_Dir "Release"
|
||||
# PROP Intermediate_Dir "Release"
|
||||
# PROP Target_Dir ""
|
||||
# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDebug" /D "_MBCS" /D "_LIB" /YX /FD /c
|
||||
# ADD CPP /nologo /MD /W3 /GX /O2 /I "." /D "NDebug" /D "_LIB" /D "Zend_EXPORTS" /D ZEND_DEBUG=0 /D "LIBZEND_EXPORTS" /D "TSRM_EXPORTS" /D "WIN32" /D "_MBCS" /D "ZEND_WIN32" /FR /FD /c
|
||||
# SUBTRACT CPP /YX
|
||||
# ADD BASE RSC /l 0x40d /d "NDebug"
|
||||
# ADD RSC /l 0x40d /d "NDebug"
|
||||
BSC32=bscmake.exe
|
||||
# ADD BASE BSC32 /nologo
|
||||
# ADD BSC32 /nologo
|
||||
LIB32=link.exe -lib
|
||||
# ADD BASE LIB32 /nologo
|
||||
# ADD LIB32 /nologo
|
||||
|
||||
!ELSEIF "$(CFG)" == "Zend - Win32 Debug"
|
||||
|
||||
# PROP BASE Use_MFC 0
|
||||
# PROP BASE Output_Dir "Debug"
|
||||
# PROP BASE Intermediate_Dir "Debug"
|
||||
# PROP BASE Target_Dir ""
|
||||
# PROP Use_MFC 0
|
||||
# PROP Output_Dir "Debug"
|
||||
# PROP Intermediate_Dir "Debug"
|
||||
# PROP Target_Dir ""
|
||||
# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_Debug" /D "_MBCS" /D "_LIB" /YX /FD /GZ /c
|
||||
# ADD CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /I "." /D "_Debug" /D "_LIB" /D "LIBZEND_EXPORTS" /D "TSRM_EXPORTS" /D ZEND_DEBUG=1 /D "ZEND_WIN32" /D "WIN32" /D "_MBCS" /FR /YX /FD /GZ /c
|
||||
# ADD BASE RSC /l 0x40d /d "_Debug"
|
||||
# ADD RSC /l 0x40d /d "_Debug"
|
||||
BSC32=bscmake.exe
|
||||
# ADD BASE BSC32 /nologo
|
||||
# ADD BSC32 /nologo
|
||||
LIB32=link.exe -lib
|
||||
# ADD BASE LIB32 /nologo
|
||||
# ADD LIB32 /nologo
|
||||
|
||||
!ELSEIF "$(CFG)" == "Zend - Win32 Release_inline"
|
||||
|
||||
# PROP BASE Use_MFC 0
|
||||
# PROP BASE Output_Dir "Zend___Win32_Release_inline"
|
||||
# PROP BASE Intermediate_Dir "Zend___Win32_Release_inline"
|
||||
# PROP BASE Target_Dir ""
|
||||
# PROP Use_MFC 0
|
||||
# PROP Output_Dir "Release_inline"
|
||||
# PROP Intermediate_Dir "Release_inline"
|
||||
# PROP Target_Dir ""
|
||||
# ADD BASE CPP /nologo /MD /W3 /GX /O2 /I "." /D "NDebug" /D "_LIB" /D "Zend_EXPORTS" /D ZEND_DEBUG=0 /D "LIBZEND_EXPORTS" /D "TSRM_EXPORTS" /D "WIN32" /D "_MBCS" /FR /FD /c
|
||||
# SUBTRACT BASE CPP /YX
|
||||
# ADD CPP /nologo /MD /W3 /GX /O2 /I "." /D "NDebug" /D "_LIB" /D "Zend_EXPORTS" /D "LIBZEND_EXPORTS" /D "TSRM_EXPORTS" /D ZEND_DEBUG=0 /D "ZEND_WIN32_FORCE_INLINE" /D "WIN32" /D "_MBCS" /D "ZEND_WIN32" /FR /FD /c
|
||||
# SUBTRACT CPP /YX
|
||||
# ADD BASE RSC /l 0x40d /d "NDebug"
|
||||
# ADD RSC /l 0x40d /d "NDebug"
|
||||
BSC32=bscmake.exe
|
||||
# ADD BASE BSC32 /nologo
|
||||
# ADD BSC32 /nologo
|
||||
LIB32=link.exe -lib
|
||||
# ADD BASE LIB32 /nologo
|
||||
# ADD LIB32 /nologo
|
||||
|
||||
!ENDIF
|
||||
|
||||
# Begin Target
|
||||
|
||||
# Name "Zend - Win32 Release"
|
||||
# Name "Zend - Win32 Debug"
|
||||
# Name "Zend - Win32 Release_inline"
|
||||
# Begin Group "Source Files"
|
||||
|
||||
# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_alloc.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_API.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_builtin_functions.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_compile.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_constants.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_default_classes.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_interfaces.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_dynamic_array.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_execute.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_execute_API.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_extensions.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_hash.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_highlight.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_indent.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_ini.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_ini_parser.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_ini_scanner.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=".\zend_language_parser.c"
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=".\zend_language_scanner.c"
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_list.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_llist.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_mm.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_object_handlers.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_objects.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_objects_API.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_opcode.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_operators.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_ptr_stack.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
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
|
||||
|
||||
SOURCE=.\zend_stack.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_stream.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_ts_hash.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_variables.c
|
||||
# End Source File
|
||||
# End Group
|
||||
# Begin Group "Header Files"
|
||||
|
||||
# PROP Default_Filter "h;hpp;hxx;hm;inl"
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\FlexLexer.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_alloc.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_API.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_builtin_functions.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_compile.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_config.w32.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_constants.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_default_classes.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_interfaces.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_dynamic_array.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_errors.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_execute.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_execute_locks.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_extensions.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_fast_cache.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_globals.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_globals_macros.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_hash.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_highlight.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_indent.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_ini.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_ini_parser.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_ini_scanner.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_istdiostream.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=".\zend_language_parser.h"
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=".\zend_language_scanner.h"
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_list.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_llist.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_mm.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_modules.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_object_handlers.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_objects.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_objects_API.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_operators.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_ptr_stack.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
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
|
||||
|
||||
SOURCE=.\zend_stream.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_ts_hash.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_variables.h
|
||||
# End Source File
|
||||
# End Group
|
||||
# Begin Group "Parsers"
|
||||
|
||||
# PROP Default_Filter "y"
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_ini_parser.y
|
||||
|
||||
!IF "$(CFG)" == "Zend - Win32 Release"
|
||||
|
||||
!ELSEIF "$(CFG)" == "Zend - Win32 Debug"
|
||||
|
||||
# Begin Custom Build
|
||||
InputDir=.
|
||||
InputPath=.\zend_ini_parser.y
|
||||
|
||||
BuildCmds= \
|
||||
bison --output=zend_ini_parser.c -v -d -p ini_ zend_ini_parser.y
|
||||
|
||||
"$(InputDir)\zend_ini_parser.c" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
$(BuildCmds)
|
||||
|
||||
"$(InputDir)\zend_ini_parser.h" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
$(BuildCmds)
|
||||
# End Custom Build
|
||||
|
||||
!ELSEIF "$(CFG)" == "Zend - Win32 Release_inline"
|
||||
|
||||
!ENDIF
|
||||
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=".\zend_language_parser.y"
|
||||
|
||||
!IF "$(CFG)" == "Zend - Win32 Release"
|
||||
|
||||
# Begin Custom Build
|
||||
InputDir=.
|
||||
InputPath=".\zend_language_parser.y"
|
||||
|
||||
BuildCmds= \
|
||||
bison --output=zend_language_parser.c -v -d -p zend zend_language_parser.y
|
||||
|
||||
"$(InputDir)\zend_language_parser.c" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
$(BuildCmds)
|
||||
|
||||
"$(InputDir)\zend_language_parser.h" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
$(BuildCmds)
|
||||
# End Custom Build
|
||||
|
||||
!ELSEIF "$(CFG)" == "Zend - Win32 Debug"
|
||||
|
||||
# Begin Custom Build
|
||||
InputDir=.
|
||||
InputPath=".\zend_language_parser.y"
|
||||
|
||||
BuildCmds= \
|
||||
bison --output=zend_language_parser.c -v -d -p zend zend_language_parser.y
|
||||
|
||||
"$(InputDir)\zend_language_parser.c" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
$(BuildCmds)
|
||||
|
||||
"$(InputDir)\zend_language_parser.h" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
$(BuildCmds)
|
||||
# End Custom Build
|
||||
|
||||
!ELSEIF "$(CFG)" == "Zend - Win32 Release_inline"
|
||||
|
||||
# Begin Custom Build
|
||||
InputDir=.
|
||||
InputPath=".\zend_language_parser.y"
|
||||
|
||||
BuildCmds= \
|
||||
bison --output=zend_language_parser.c -v -d -p zend zend_language_parser.y
|
||||
|
||||
"$(InputDir)\zend_language_parser.c" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
$(BuildCmds)
|
||||
|
||||
"$(InputDir)\zend_language_parser.h" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
$(BuildCmds)
|
||||
# End Custom Build
|
||||
|
||||
!ENDIF
|
||||
|
||||
# End Source File
|
||||
# End Group
|
||||
# Begin Group "Scanners"
|
||||
|
||||
# PROP Default_Filter "l"
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\flex.skl
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_ini_scanner.l
|
||||
|
||||
!IF "$(CFG)" == "Zend - Win32 Release"
|
||||
|
||||
!ELSEIF "$(CFG)" == "Zend - Win32 Debug"
|
||||
|
||||
# Begin Custom Build
|
||||
InputPath=.\zend_ini_scanner.l
|
||||
|
||||
"zend_ini_scanner.c" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
flex -B -i -Sflex.skl -Pini_ -ozend_ini_scanner.c zend_ini_scanner.l
|
||||
|
||||
# End Custom Build
|
||||
|
||||
!ELSEIF "$(CFG)" == "Zend - Win32 Release_inline"
|
||||
|
||||
!ENDIF
|
||||
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=".\zend_language_scanner.l"
|
||||
|
||||
!IF "$(CFG)" == "Zend - Win32 Release"
|
||||
|
||||
# Begin Custom Build
|
||||
InputPath=".\zend_language_scanner.l"
|
||||
|
||||
"zend_language_scanner.c" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
flex -i -Pzend -ozend_language_scanner.c zend_language_scanner.l
|
||||
|
||||
# End Custom Build
|
||||
|
||||
!ELSEIF "$(CFG)" == "Zend - Win32 Debug"
|
||||
|
||||
# Begin Custom Build
|
||||
InputPath=".\zend_language_scanner.l"
|
||||
|
||||
"zend_language_scanner.c" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
flex -i -Pzend -ozend_language_scanner.c zend_language_scanner.l
|
||||
|
||||
# End Custom Build
|
||||
|
||||
!ELSEIF "$(CFG)" == "Zend - Win32 Release_inline"
|
||||
|
||||
# Begin Custom Build
|
||||
InputPath=".\zend_language_scanner.l"
|
||||
|
||||
"zend_language_scanner.c" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
flex -i -Pzend -ozend_language_scanner.c zend_language_scanner.l
|
||||
|
||||
# End Custom Build
|
||||
|
||||
!ENDIF
|
||||
|
||||
# End Source File
|
||||
# End Group
|
||||
# Begin Group "Text Files"
|
||||
|
||||
# PROP Default_Filter ""
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\ZEND_BUGS
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\ZEND_CHANGES
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\ZEND_TODO
|
||||
# End Source File
|
||||
# End Group
|
||||
# Begin Group "Resources"
|
||||
|
||||
# PROP Default_Filter ""
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend.ico
|
||||
# End Source File
|
||||
# End Group
|
||||
# End Target
|
||||
# End Project
|
||||
-250
@@ -1,250 +0,0 @@
|
||||
dnl
|
||||
dnl $Id$
|
||||
dnl
|
||||
dnl This file contains Zend specific autoconf functions.
|
||||
dnl
|
||||
|
||||
AC_DEFUN(LIBZEND_BISON_CHECK,[
|
||||
|
||||
if test "$YACC" != "bison -y"; then
|
||||
AC_MSG_WARN(You will need bison if you want to regenerate the Zend parser.)
|
||||
else
|
||||
AC_MSG_CHECKING(bison version)
|
||||
set `bison --version| grep 'GNU Bison' | cut -d ' ' -f 4 | sed -e 's/\./ /' | tr -d 'a-z'`
|
||||
if test "${1}" = "1" -a "${2}" -lt "28"; then
|
||||
AC_MSG_WARN(You will need bison 1.28 if you want to regenerate the Zend parser (found ${1}.${2}).)
|
||||
fi
|
||||
AC_MSG_RESULT(${1}.${2} (ok))
|
||||
fi
|
||||
|
||||
])
|
||||
|
||||
AC_DEFUN(LIBZEND_BASIC_CHECKS,[
|
||||
|
||||
AC_REQUIRE([AC_PROG_YACC])
|
||||
AC_REQUIRE([AC_PROG_CC])
|
||||
AC_REQUIRE([AC_PROG_CC_C_O])
|
||||
AC_REQUIRE([AC_PROG_LEX])
|
||||
AC_REQUIRE([AC_HEADER_STDC])
|
||||
|
||||
LIBZEND_BISON_CHECK
|
||||
|
||||
dnl Ugly hack to get around a problem with gcc on AIX.
|
||||
if test "$CC" = "gcc" -a "$ac_cv_prog_cc_g" = "yes" -a \
|
||||
"`uname -sv`" = "AIX 4"; then
|
||||
CFLAGS=`echo $CFLAGS | sed -e 's/-g//'`
|
||||
fi
|
||||
|
||||
dnl Hack to work around a Mac OS X cpp problem
|
||||
dnl Known versions needing this workaround are 5.3 and 5.4
|
||||
if test "$ac_cv_prog_gcc" = "yes" -a "`uname -s`" = "Rhapsody"; then
|
||||
CPPFLAGS="$CPPFLAGS -traditional-cpp"
|
||||
fi
|
||||
|
||||
AC_CHECK_HEADERS(
|
||||
limits.h \
|
||||
malloc.h \
|
||||
string.h \
|
||||
unistd.h \
|
||||
stdarg.h \
|
||||
sys/types.h \
|
||||
sys/time.h \
|
||||
signal.h \
|
||||
unix.h \
|
||||
stdlib.h \
|
||||
mach-o/dyld.h \
|
||||
dlfcn.h)
|
||||
|
||||
AC_TYPE_SIZE_T
|
||||
AC_TYPE_SIGNAL
|
||||
|
||||
AC_DEFUN(LIBZEND_LIBDL_CHECKS,[
|
||||
AC_CHECK_LIB(dl, dlopen, [LIBS="-ldl $LIBS"])
|
||||
AC_CHECK_FUNC(dlopen,[AC_DEFINE(HAVE_LIBDL, 1,[ ])])
|
||||
])
|
||||
|
||||
AC_DEFUN(LIBZEND_DLSYM_CHECK,[
|
||||
dnl
|
||||
dnl Ugly hack to check if dlsym() requires a leading underscore in symbol name.
|
||||
dnl
|
||||
AC_MSG_CHECKING([whether dlsym() requires a leading underscore in symbol names])
|
||||
_LT_AC_TRY_DLOPEN_SELF([
|
||||
AC_MSG_RESULT(no)
|
||||
], [
|
||||
AC_MSG_RESULT(yes)
|
||||
AC_DEFINE(DLSYM_NEEDS_UNDERSCORE, 1, [Define if dlsym() requires a leading underscore in symbol names. ])
|
||||
], [
|
||||
AC_MSG_RESULT(no)
|
||||
], [])
|
||||
])
|
||||
|
||||
dnl This is required for QNX and may be some BSD derived systems
|
||||
AC_CHECK_TYPE( uint, unsigned int )
|
||||
AC_CHECK_TYPE( ulong, unsigned long )
|
||||
|
||||
dnl Checks for library functions.
|
||||
AC_FUNC_VPRINTF
|
||||
AC_FUNC_MEMCMP
|
||||
AC_FUNC_ALLOCA
|
||||
AC_CHECK_FUNCS(memcpy strdup getpid kill strtod strtol finite fpclass)
|
||||
AC_ZEND_BROKEN_SPRINTF
|
||||
|
||||
AC_CHECK_FUNCS(finite isfinite isinf isnan)
|
||||
|
||||
ZEND_FP_EXCEPT
|
||||
|
||||
])
|
||||
|
||||
AC_DEFUN(LIBZEND_ENABLE_DEBUG,[
|
||||
|
||||
AC_ARG_ENABLE(debug,
|
||||
[ --enable-debug Compile with debugging symbols],[
|
||||
ZEND_DEBUG=$enableval
|
||||
],[
|
||||
ZEND_DEBUG=no
|
||||
])
|
||||
|
||||
])
|
||||
|
||||
AC_DEFUN(LIBZEND_OTHER_CHECKS,[
|
||||
|
||||
AC_ARG_ENABLE(maintainer-zts,
|
||||
[ --enable-maintainer-zts Enable thread safety - for code maintainers only],[
|
||||
ZEND_MAINTAINER_ZTS=$enableval
|
||||
],[
|
||||
ZEND_MAINTAINER_ZTS=no
|
||||
])
|
||||
|
||||
AC_ARG_ENABLE(inline-optimization,
|
||||
[ --disable-inline-optimization
|
||||
If building zend_execute.lo fails, try this switch.],[
|
||||
ZEND_INLINE_OPTIMIZATION=$enableval
|
||||
],[
|
||||
ZEND_INLINE_OPTIMIZATION=yes
|
||||
])
|
||||
|
||||
AC_ARG_ENABLE(memory-limit,
|
||||
[ --enable-memory-limit Compile with memory limit support. ], [
|
||||
ZEND_MEMORY_LIMIT=$enableval
|
||||
],[
|
||||
ZEND_MEMORY_LIMIT=no
|
||||
])
|
||||
|
||||
AC_ARG_ENABLE(zend-multibyte,
|
||||
[ --enable-zend-multibyte Compile with zend multibyte support. ], [
|
||||
ZEND_MULTIBYTE=$enableval
|
||||
],[
|
||||
ZEND_MULTIBYTE=no
|
||||
])
|
||||
|
||||
AC_MSG_CHECKING(whether to enable thread-safety)
|
||||
AC_MSG_RESULT($ZEND_MAINTAINER_ZTS)
|
||||
|
||||
AC_MSG_CHECKING(whether to enable inline optimization for GCC)
|
||||
AC_MSG_RESULT($ZEND_INLINE_OPTIMIZATION)
|
||||
|
||||
AC_MSG_CHECKING(whether to enable a memory limit)
|
||||
AC_MSG_RESULT($ZEND_MEMORY_LIMIT)
|
||||
|
||||
AC_MSG_CHECKING(whether to enable Zend debugging)
|
||||
AC_MSG_RESULT($ZEND_DEBUG)
|
||||
|
||||
AC_MSG_CHECKING(whether to enable Zend multibyte)
|
||||
AC_MSG_RESULT($ZEND_MULTIBYTE)
|
||||
|
||||
if test "$ZEND_DEBUG" = "yes"; then
|
||||
AC_DEFINE(ZEND_DEBUG,1,[ ])
|
||||
echo " $CFLAGS" | grep ' -g' >/dev/null || DEBUG_CFLAGS="-g"
|
||||
if test "$CFLAGS" = "-g -O2"; then
|
||||
CFLAGS=-g
|
||||
fi
|
||||
test -n "$GCC" && DEBUG_CFLAGS="$DEBUG_CFLAGS -Wall"
|
||||
test -n "$GCC" && test "$USE_MAINTAINER_MODE" = "yes" && \
|
||||
DEBUG_CFLAGS="$DEBUG_CFLAGS -Wmissing-prototypes -Wstrict-prototypes -Wmissing-declarations"
|
||||
else
|
||||
AC_DEFINE(ZEND_DEBUG,0,[ ])
|
||||
fi
|
||||
|
||||
test -n "$DEBUG_CFLAGS" && CFLAGS="$CFLAGS $DEBUG_CFLAGS"
|
||||
|
||||
if test "$ZEND_MAINTAINER_ZTS" = "yes"; then
|
||||
AC_DEFINE(ZTS,1,[ ])
|
||||
CFLAGS="$CFLAGS -DZTS"
|
||||
LIBZEND_CPLUSPLUS_CHECKS
|
||||
fi
|
||||
|
||||
if test "$ZEND_MEMORY_LIMIT" = "yes"; then
|
||||
AC_DEFINE(MEMORY_LIMIT, 1, [Memory limit])
|
||||
else
|
||||
AC_DEFINE(MEMORY_LIMIT, 0, [Memory limit])
|
||||
fi
|
||||
|
||||
if test "$ZEND_MULTIBYTE" = "yes"; then
|
||||
AC_DEFINE(ZEND_MULTIBYTE, 1, [ ])
|
||||
fi
|
||||
|
||||
changequote({,})
|
||||
if test -n "$GCC" && test "$ZEND_INLINE_OPTIMIZATION" != "yes"; then
|
||||
INLINE_CFLAGS=`echo $ac_n "$CFLAGS $ac_c" | sed s/-O[0-9s]*//`
|
||||
else
|
||||
INLINE_CFLAGS="$CFLAGS"
|
||||
fi
|
||||
changequote([,])
|
||||
|
||||
AC_C_INLINE
|
||||
|
||||
AC_SUBST(INLINE_CFLAGS)
|
||||
|
||||
|
||||
dnl test and set the alignment define for ZEND_MM
|
||||
dnl this also does the logarithmic test for ZEND_MM.
|
||||
AC_MSG_CHECKING(for MM alignment and log values)
|
||||
|
||||
AC_TRY_RUN([
|
||||
#include <stdio.h>
|
||||
|
||||
typedef union _mm_align_test {
|
||||
void *ptr;
|
||||
double dbl;
|
||||
long lng;
|
||||
} mm_align_test;
|
||||
|
||||
#if (defined (__GNUC__) && __GNUC__ >= 2)
|
||||
#define ZEND_MM_ALIGNMENT (__alignof__ (mm_align_test))
|
||||
#else
|
||||
#define ZEND_MM_ALIGNMENT (sizeof(mm_align_test))
|
||||
#endif
|
||||
|
||||
int main()
|
||||
{
|
||||
int i = ZEND_MM_ALIGNMENT;
|
||||
int zeros = 0;
|
||||
FILE *fp;
|
||||
|
||||
while (i & ~0x1) {
|
||||
zeros++;
|
||||
i = i >> 1;
|
||||
}
|
||||
|
||||
fp = fopen("conftest.zend", "w");
|
||||
fprintf(fp, "%d %d\n", ZEND_MM_ALIGNMENT, zeros);
|
||||
fclose(fp);
|
||||
|
||||
exit(0);
|
||||
}
|
||||
], [
|
||||
LIBZEND_MM_ALIGN=`cat conftest.zend | cut -d ' ' -f 1`
|
||||
LIBZEND_MM_ALIGN_LOG2=`cat conftest.zend | cut -d ' ' -f 2`
|
||||
AC_DEFINE_UNQUOTED(ZEND_MM_ALIGNMENT, $LIBZEND_MM_ALIGN, [ ])
|
||||
AC_DEFINE_UNQUOTED(ZEND_MM_ALIGNMENT_LOG2, $LIBZEND_MM_ALIGN_LOG2, [ ])
|
||||
])
|
||||
|
||||
AC_MSG_RESULT(done)
|
||||
|
||||
])
|
||||
|
||||
|
||||
AC_DEFUN(LIBZEND_CPLUSPLUS_CHECKS,[
|
||||
|
||||
])
|
||||
|
||||
@@ -1,258 +0,0 @@
|
||||
# Microsoft Developer Studio Generated Dependency File, included by ZendCore.mak
|
||||
|
||||
.\zend_alloc.c : \
|
||||
"..\..\..\program files\microsoft visual studio\vc98\include\basetsd.h"\
|
||||
".\zend_alloc.h"\
|
||||
".\zend_compile.h"\
|
||||
".\zend_config.w32.h"\
|
||||
".\zend_execute.h"\
|
||||
".\zend_llist.h"\
|
||||
".\zend_ptr_stack.h"\
|
||||
".\zend_stack.h"\
|
||||
".\zend.h"\
|
||||
".\zend_errors.h"\
|
||||
".\zend_globals.h"\
|
||||
".\zend_hash.h"\
|
||||
|
||||
|
||||
.\alloca.c : \
|
||||
"..\..\..\program files\microsoft visual studio\vc98\include\basetsd.h"\
|
||||
".\zend_config.w32.h"\
|
||||
".\zend.h"\
|
||||
".\zend_errors.h"\
|
||||
".\zend_hash.h"\
|
||||
|
||||
|
||||
.\zend_compile.c : \
|
||||
"..\..\..\program files\microsoft visual studio\vc98\include\basetsd.h"\
|
||||
".\zend_alloc.h"\
|
||||
".\zend_compile.h"\
|
||||
".\zend_config.w32.h"\
|
||||
".\zend_execute.h"\
|
||||
".\zend_llist.h"\
|
||||
".\zend_modules.h"\
|
||||
".\zend_operators.h"\
|
||||
".\zend_ptr_stack.h"\
|
||||
".\zend_stack.h"\
|
||||
".\zend_variables.h"\
|
||||
".\zend.h"\
|
||||
".\zend_API.h"\
|
||||
".\zend_errors.h"\
|
||||
".\zend_globals.h"\
|
||||
".\zend_hash.h"\
|
||||
".\zend_ini.h"\
|
||||
|
||||
|
||||
.\zend_constants.c : \
|
||||
"..\..\..\program files\microsoft visual studio\vc98\include\basetsd.h"\
|
||||
".\zend_alloc.h"\
|
||||
".\zend_config.w32.h"\
|
||||
".\zend_constants.h"\
|
||||
".\zend_operators.h"\
|
||||
".\zend_variables.h"\
|
||||
".\zend.h"\
|
||||
".\zend_errors.h"\
|
||||
".\zend_hash.h"\
|
||||
|
||||
|
||||
.\zend_execute.c : \
|
||||
"..\..\..\program files\microsoft visual studio\vc98\include\basetsd.h"\
|
||||
".\zend_alloc.h"\
|
||||
".\zend_compile.h"\
|
||||
".\zend_config.w32.h"\
|
||||
".\zend_constants.h"\
|
||||
".\zend_execute.h"\
|
||||
".\zend_llist.h"\
|
||||
".\zend_modules.h"\
|
||||
".\zend_operators.h"\
|
||||
".\zend_ptr_stack.h"\
|
||||
".\zend_stack.h"\
|
||||
".\zend_variables.h"\
|
||||
".\zend.h"\
|
||||
".\zend_API.h"\
|
||||
".\zend_errors.h"\
|
||||
".\zend_globals.h"\
|
||||
".\zend_hash.h"\
|
||||
".\zend_ini.h"\
|
||||
|
||||
|
||||
.\zend_highlight.c : \
|
||||
"..\..\..\program files\microsoft visual studio\vc98\include\basetsd.h"\
|
||||
".\zend_alloc.h"\
|
||||
".\zend_compile.h"\
|
||||
".\zend_config.w32.h"\
|
||||
".\zend_execute.h"\
|
||||
".\zend_highlight.h"\
|
||||
".\zend_llist.h"\
|
||||
".\zend_ptr_stack.h"\
|
||||
".\zend_stack.h"\
|
||||
".\zend_language_parser.tab.h"\
|
||||
".\zend.h"\
|
||||
".\zend_errors.h"\
|
||||
".\zend_globals.h"\
|
||||
".\zend_hash.h"\
|
||||
|
||||
|
||||
.\zend_llist.c : \
|
||||
"..\..\..\program files\microsoft visual studio\vc98\include\basetsd.h"\
|
||||
".\zend_alloc.h"\
|
||||
".\zend_config.w32.h"\
|
||||
".\zend_llist.h"\
|
||||
".\zend.h"\
|
||||
".\zend_errors.h"\
|
||||
".\zend_hash.h"\
|
||||
|
||||
|
||||
.\zend_opcode.c : \
|
||||
"..\..\..\program files\microsoft visual studio\vc98\include\basetsd.h"\
|
||||
".\zend_alloc.h"\
|
||||
".\zend_compile.h"\
|
||||
".\zend_config.w32.h"\
|
||||
".\zend_execute.h"\
|
||||
".\zend_llist.h"\
|
||||
".\zend_modules.h"\
|
||||
".\zend_operators.h"\
|
||||
".\zend_ptr_stack.h"\
|
||||
".\zend_stack.h"\
|
||||
".\zend_variables.h"\
|
||||
".\zend.h"\
|
||||
".\zend_API.h"\
|
||||
".\zend_errors.h"\
|
||||
".\zend_globals.h"\
|
||||
".\zend_hash.h"\
|
||||
".\zend_ini.h"\
|
||||
|
||||
|
||||
.\zend_operators.c : \
|
||||
"..\..\..\program files\microsoft visual studio\vc98\include\basetsd.h"\
|
||||
".\zend_alloc.h"\
|
||||
".\zend_compile.h"\
|
||||
".\zend_config.w32.h"\
|
||||
".\zend_execute.h"\
|
||||
".\zend_llist.h"\
|
||||
".\zend_operators.h"\
|
||||
".\zend_ptr_stack.h"\
|
||||
".\zend_stack.h"\
|
||||
".\zend_variables.h"\
|
||||
".\zend.h"\
|
||||
".\zend_errors.h"\
|
||||
".\zend_globals.h"\
|
||||
".\zend_hash.h"\
|
||||
|
||||
|
||||
.\zend_ptr_stack.c : \
|
||||
"..\..\..\program files\microsoft visual studio\vc98\include\basetsd.h"\
|
||||
".\zend_alloc.h"\
|
||||
".\zend_config.w32.h"\
|
||||
".\zend_ptr_stack.h"\
|
||||
".\zend.h"\
|
||||
".\zend_errors.h"\
|
||||
".\zend_hash.h"\
|
||||
|
||||
|
||||
.\zend_stack.c : \
|
||||
"..\..\..\program files\microsoft visual studio\vc98\include\basetsd.h"\
|
||||
".\zend_alloc.h"\
|
||||
".\zend_config.w32.h"\
|
||||
".\zend_stack.h"\
|
||||
".\zend.h"\
|
||||
".\zend_errors.h"\
|
||||
".\zend_hash.h"\
|
||||
|
||||
|
||||
.\zend_variables.c : \
|
||||
"..\..\..\program files\microsoft visual studio\vc98\include\basetsd.h"\
|
||||
".\zend_alloc.h"\
|
||||
".\zend_compile.h"\
|
||||
".\zend_config.w32.h"\
|
||||
".\zend_constants.h"\
|
||||
".\zend_execute.h"\
|
||||
".\zend_llist.h"\
|
||||
".\zend_modules.h"\
|
||||
".\zend_ptr_stack.h"\
|
||||
".\zend_stack.h"\
|
||||
".\zend_variables.h"\
|
||||
".\zend.h"\
|
||||
".\zend_API.h"\
|
||||
".\zend_errors.h"\
|
||||
".\zend_globals.h"\
|
||||
".\zend_hash.h"\
|
||||
".\zend_ini.h"\
|
||||
".\zend_list.h"\
|
||||
|
||||
|
||||
.\zend.c : \
|
||||
"..\..\..\program files\microsoft visual studio\vc98\include\basetsd.h"\
|
||||
".\zend_alloc.h"\
|
||||
".\zend_config.w32.h"\
|
||||
".\zend_operators.h"\
|
||||
".\zend_variables.h"\
|
||||
".\zend.h"\
|
||||
".\zend_errors.h"\
|
||||
".\zend_hash.h"\
|
||||
|
||||
|
||||
.\zend_API.c : \
|
||||
"..\..\..\program files\microsoft visual studio\vc98\include\basetsd.h"\
|
||||
".\zend_alloc.h"\
|
||||
".\zend_compile.h"\
|
||||
".\zend_config.w32.h"\
|
||||
".\zend_constants.h"\
|
||||
".\zend_execute.h"\
|
||||
".\zend_llist.h"\
|
||||
".\zend_modules.h"\
|
||||
".\zend_operators.h"\
|
||||
".\zend_ptr_stack.h"\
|
||||
".\zend_stack.h"\
|
||||
".\zend_variables.h"\
|
||||
".\zend.h"\
|
||||
".\zend_API.h"\
|
||||
".\zend_errors.h"\
|
||||
".\zend_globals.h"\
|
||||
".\zend_hash.h"\
|
||||
".\zend_ini.h"\
|
||||
".\zend_list.h"\
|
||||
|
||||
|
||||
.\zend_hash.c : \
|
||||
"..\..\..\program files\microsoft visual studio\vc98\include\basetsd.h"\
|
||||
".\zend_config.w32.h"\
|
||||
".\zend.h"\
|
||||
".\zend_errors.h"\
|
||||
".\zend_hash.h"\
|
||||
|
||||
|
||||
.\zend_ini.c : \
|
||||
"..\..\..\program files\microsoft visual studio\vc98\include\basetsd.h"\
|
||||
".\zend_alloc.h"\
|
||||
".\zend_config.w32.h"\
|
||||
".\zend.h"\
|
||||
".\zend_errors.h"\
|
||||
".\zend_hash.h"\
|
||||
".\zend_ini.h"\
|
||||
|
||||
|
||||
!IF "$(CFG)" == "ZendCore - Win32 Release"
|
||||
|
||||
!ELSEIF "$(CFG)" == "ZendCore - Win32 Debug"
|
||||
|
||||
!ENDIF
|
||||
|
||||
!IF "$(CFG)" == "ZendCore - Win32 Release"
|
||||
|
||||
!ELSEIF "$(CFG)" == "ZendCore - Win32 Debug"
|
||||
|
||||
!ENDIF
|
||||
|
||||
!IF "$(CFG)" == "ZendCore - Win32 Release"
|
||||
|
||||
!ELSEIF "$(CFG)" == "ZendCore - Win32 Debug"
|
||||
|
||||
!ENDIF
|
||||
|
||||
!IF "$(CFG)" == "ZendCore - Win32 Release"
|
||||
|
||||
!ELSEIF "$(CFG)" == "ZendCore - Win32 Debug"
|
||||
|
||||
!ENDIF
|
||||
|
||||
-727
@@ -1,727 +0,0 @@
|
||||
# Microsoft Developer Studio Project File - Name="ZendTS" - Package Owner=<4>
|
||||
# Microsoft Developer Studio Generated Build File, Format Version 6.00
|
||||
# ** DO NOT EDIT **
|
||||
|
||||
# TARGTYPE "Win32 (x86) Static Library" 0x0104
|
||||
|
||||
CFG=ZendTS - Win32 Release_TSDbg
|
||||
!MESSAGE This is not a valid makefile. To build this project using NMAKE,
|
||||
!MESSAGE use the Export Makefile command and run
|
||||
!MESSAGE
|
||||
!MESSAGE NMAKE /f "ZendTS.mak".
|
||||
!MESSAGE
|
||||
!MESSAGE You can specify a configuration when running NMAKE
|
||||
!MESSAGE by defining the macro CFG on the command line. For example:
|
||||
!MESSAGE
|
||||
!MESSAGE NMAKE /f "ZendTS.mak" CFG="ZendTS - Win32 Release_TSDbg"
|
||||
!MESSAGE
|
||||
!MESSAGE Possible choices for configuration are:
|
||||
!MESSAGE
|
||||
!MESSAGE "ZendTS - Win32 Release_TS" (based on "Win32 (x86) Static Library")
|
||||
!MESSAGE "ZendTS - Win32 Debug_TS" (based on "Win32 (x86) Static Library")
|
||||
!MESSAGE "ZendTS - Win32 Release_TS_inline" (based on "Win32 (x86) Static Library")
|
||||
!MESSAGE "ZendTS - Win32 Release_TSDbg" (based on "Win32 (x86) Static Library")
|
||||
!MESSAGE
|
||||
|
||||
# Begin Project
|
||||
# PROP AllowPerConfigDependencies 0
|
||||
# PROP Scc_ProjName ""
|
||||
# PROP Scc_LocalPath ""
|
||||
CPP=cl.exe
|
||||
RSC=rc.exe
|
||||
|
||||
!IF "$(CFG)" == "ZendTS - Win32 Release_TS"
|
||||
|
||||
# PROP BASE Use_MFC 0
|
||||
# PROP BASE Output_Dir "Release_TS"
|
||||
# PROP BASE Intermediate_Dir "Release_TS"
|
||||
# PROP BASE Target_Dir ""
|
||||
# PROP Use_MFC 0
|
||||
# PROP Output_Dir "Release_TS"
|
||||
# PROP Intermediate_Dir "Release_TS"
|
||||
# PROP Target_Dir ""
|
||||
# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDebug_TS" /D "_MBCS" /D "_LIB" /YX /FD /c
|
||||
# ADD CPP /nologo /MD /W3 /GX /O2 /I "." /D "NDebug_TS" /D ZEND_DEBUG=0 /D _WIN32_WINNT=0x400 /D "_LIB" /D "TSRM_EXPORTS" /D "LIBZEND_EXPORTS" /D "ZTS" /D "ZEND_WIN32" /D "WIN32" /D "_MBCS" /FR /FD /c
|
||||
# SUBTRACT CPP /YX
|
||||
# ADD BASE RSC /l 0x40d /d "NDebug_TS"
|
||||
# ADD RSC /l 0x40d /d "NDebug_TS"
|
||||
BSC32=bscmake.exe
|
||||
# ADD BASE BSC32 /nologo
|
||||
# ADD BSC32 /nologo
|
||||
LIB32=link.exe -lib
|
||||
# ADD BASE LIB32 /nologo
|
||||
# ADD LIB32 /nologo
|
||||
|
||||
!ELSEIF "$(CFG)" == "ZendTS - Win32 Debug_TS"
|
||||
|
||||
# PROP BASE Use_MFC 0
|
||||
# PROP BASE Output_Dir "Debug_TS"
|
||||
# PROP BASE Intermediate_Dir "Debug_TS"
|
||||
# PROP BASE Target_Dir ""
|
||||
# PROP Use_MFC 0
|
||||
# PROP Output_Dir "Debug_TS"
|
||||
# PROP Intermediate_Dir "Debug_TS"
|
||||
# PROP Target_Dir ""
|
||||
# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_Debug_TS" /D "_MBCS" /D "_LIB" /YX /FD /GZ /c
|
||||
# ADD CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /I "." /D "_Debug_TS" /D ZEND_DEBUG=1 /D "_LIB" /D "TSRM_EXPORTS" /D "LIBZEND_EXPORTS" /D "ZTS" /D "ZEND_WIN32" /D "WIN32" /D "_MBCS" /FR /YX /FD /GZ /c
|
||||
# ADD BASE RSC /l 0x40d /d "_Debug_TS"
|
||||
# ADD RSC /l 0x40d /d "_Debug_TS"
|
||||
BSC32=bscmake.exe
|
||||
# ADD BASE BSC32 /nologo
|
||||
# ADD BSC32 /nologo
|
||||
LIB32=link.exe -lib
|
||||
# ADD BASE LIB32 /nologo
|
||||
# ADD LIB32 /nologo
|
||||
|
||||
!ELSEIF "$(CFG)" == "ZendTS - Win32 Release_TS_inline"
|
||||
|
||||
# PROP BASE Use_MFC 0
|
||||
# PROP BASE Output_Dir "ZendTS___Win32_Release_TS_inline"
|
||||
# PROP BASE Intermediate_Dir "ZendTS___Win32_Release_TS_inline"
|
||||
# PROP BASE Target_Dir ""
|
||||
# PROP Use_MFC 0
|
||||
# PROP Output_Dir "Release_TS_inline"
|
||||
# PROP Intermediate_Dir "Release_TS_inline"
|
||||
# PROP Target_Dir ""
|
||||
# ADD BASE CPP /nologo /MD /W3 /GX /O2 /I "." /D "NDebug_TS" /D "_LIB" /D "TSRM_EXPORTS" /D "LIBZEND_EXPORTS" /D "ZTS" /D "WIN32" /D "_MBCS" /D ZEND_DEBUG=0 /FR /FD /c
|
||||
# SUBTRACT BASE CPP /YX
|
||||
# ADD CPP /nologo /MD /W3 /GX /O2 /I "." /D "NDebug_TS" /D ZEND_DEBUG=0 /D "ZEND_WIN32_FORCE_INLINE" /D _WIN32_WINNT=0x400 /D "_LIB" /D "TSRM_EXPORTS" /D "LIBZEND_EXPORTS" /D "ZTS" /D "ZEND_WIN32" /D "WIN32" /D "_MBCS" /FR /FD /c
|
||||
# SUBTRACT CPP /YX
|
||||
# ADD BASE RSC /l 0x40d /d "NDebug_TS"
|
||||
# ADD RSC /l 0x40d /d "NDebug_TS"
|
||||
BSC32=bscmake.exe
|
||||
# ADD BASE BSC32 /nologo
|
||||
# ADD BSC32 /nologo
|
||||
LIB32=link.exe -lib
|
||||
# ADD BASE LIB32 /nologo
|
||||
# ADD LIB32 /nologo
|
||||
|
||||
!ELSEIF "$(CFG)" == "ZendTS - Win32 Release_TSDbg"
|
||||
|
||||
# PROP BASE Use_MFC 0
|
||||
# PROP BASE Output_Dir "ZendTS___Win32_Release_TSDbg"
|
||||
# PROP BASE Intermediate_Dir "ZendTS___Win32_Release_TSDbg"
|
||||
# PROP BASE Target_Dir ""
|
||||
# PROP Use_MFC 0
|
||||
# PROP Output_Dir "Release_TSDbg"
|
||||
# PROP Intermediate_Dir "Release_TSDbg"
|
||||
# PROP Target_Dir ""
|
||||
# ADD BASE CPP /nologo /MD /W3 /GX /O2 /I "." /D "NDebug_TS" /D ZEND_DEBUG=0 /D _WIN32_WINNT=0x400 /D "_LIB" /D "TSRM_EXPORTS" /D "LIBZEND_EXPORTS" /D "ZTS" /D "ZEND_WIN32" /D "WIN32" /D "_MBCS" /FR /FD /c
|
||||
# SUBTRACT BASE CPP /YX
|
||||
# ADD CPP /nologo /MD /W3 /GX /Zi /Od /I "." /D "NDebug_TS" /D ZEND_DEBUG=0 /D _WIN32_WINNT=0x400 /D "_LIB" /D "TSRM_EXPORTS" /D "LIBZEND_EXPORTS" /D "ZTS" /D "ZEND_WIN32" /D "WIN32" /D "_MBCS" /FR /FD /c
|
||||
# SUBTRACT CPP /YX
|
||||
# ADD BASE RSC /l 0x40d /d "NDebug_TS"
|
||||
# ADD RSC /l 0x40d /d "NDebug_TS"
|
||||
BSC32=bscmake.exe
|
||||
# ADD BASE BSC32 /nologo
|
||||
# ADD BSC32 /nologo
|
||||
LIB32=link.exe -lib
|
||||
# ADD BASE LIB32 /nologo
|
||||
# ADD LIB32 /nologo
|
||||
|
||||
!ENDIF
|
||||
|
||||
# Begin Target
|
||||
|
||||
# Name "ZendTS - Win32 Release_TS"
|
||||
# Name "ZendTS - Win32 Debug_TS"
|
||||
# Name "ZendTS - Win32 Release_TS_inline"
|
||||
# Name "ZendTS - Win32 Release_TSDbg"
|
||||
# Begin Group "Source Files"
|
||||
|
||||
# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_alloc.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_API.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_builtin_functions.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_compile.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_constants.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_default_classes.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_interfaces.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_dynamic_array.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_execute.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_execute_API.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_extensions.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_hash.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_highlight.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_indent.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_ini.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_ini_parser.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_ini_scanner.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_iterators.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=".\zend_language_parser.c"
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=".\zend_language_scanner.c"
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_list.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_llist.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_mm.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_object_handlers.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_objects.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_objects_API.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_opcode.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_operators.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_ptr_stack.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
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
|
||||
|
||||
SOURCE=.\zend_stack.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_stream.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_ts_hash.c
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_variables.c
|
||||
# End Source File
|
||||
# End Group
|
||||
# Begin Group "Header Files"
|
||||
|
||||
# PROP Default_Filter "h;hpp;hxx;hm;inl"
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\FlexLexer.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_alloc.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_API.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_builtin_functions.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_compile.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_config.w32.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_constants.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_default_classes.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_interfaces.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_dynamic_array.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_errors.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_execute.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_extensions.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_fast_cache.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_globals.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_globals_macros.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_hash.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_highlight.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_indent.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_ini.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_ini_parser.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_ini_scanner.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_istdiostream.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_iterators.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=".\zend_language_parser.h"
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=".\zend_language_scanner.h"
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_list.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_llist.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_mm.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_modules.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_object_handlers.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_objects.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_objects_API.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_operators.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_ptr_stack.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
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
|
||||
|
||||
SOURCE=.\zend_stream.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_ts_hash.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_variables.h
|
||||
# End Source File
|
||||
# End Group
|
||||
# Begin Group "Parsers"
|
||||
|
||||
# PROP Default_Filter "y"
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_ini_parser.y
|
||||
|
||||
!IF "$(CFG)" == "ZendTS - Win32 Release_TS"
|
||||
|
||||
# Begin Custom Build
|
||||
InputDir=.
|
||||
InputPath=.\zend_ini_parser.y
|
||||
|
||||
BuildCmds= \
|
||||
bison --output=zend_ini_parser.c -v -d -p ini_ zend_ini_parser.y
|
||||
|
||||
"$(InputDir)\zend_ini_parser.c" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
$(BuildCmds)
|
||||
|
||||
"$(InputDir)\zend_ini_parser.h" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
$(BuildCmds)
|
||||
# End Custom Build
|
||||
|
||||
!ELSEIF "$(CFG)" == "ZendTS - Win32 Debug_TS"
|
||||
|
||||
# Begin Custom Build
|
||||
InputDir=.
|
||||
InputPath=.\zend_ini_parser.y
|
||||
|
||||
BuildCmds= \
|
||||
bison --output=zend_ini_parser.c -v -d -p ini_ zend_ini_parser.y
|
||||
|
||||
"$(InputDir)\zend_ini_parser.c" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
$(BuildCmds)
|
||||
|
||||
"$(InputDir)\zend_ini_parser.h" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
$(BuildCmds)
|
||||
# End Custom Build
|
||||
|
||||
!ELSEIF "$(CFG)" == "ZendTS - Win32 Release_TS_inline"
|
||||
|
||||
# Begin Custom Build
|
||||
InputDir=.
|
||||
InputPath=.\zend_ini_parser.y
|
||||
|
||||
BuildCmds= \
|
||||
bison --output=zend_ini_parser.c -v -d -p ini_ zend_ini_parser.y
|
||||
|
||||
"$(InputDir)\zend_ini_parser.c" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
$(BuildCmds)
|
||||
|
||||
"$(InputDir)\zend_ini_parser.h" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
$(BuildCmds)
|
||||
# End Custom Build
|
||||
|
||||
!ELSEIF "$(CFG)" == "ZendTS - Win32 Release_TSDbg"
|
||||
|
||||
# Begin Custom Build
|
||||
InputDir=.
|
||||
InputPath=.\zend_ini_parser.y
|
||||
|
||||
BuildCmds= \
|
||||
bison --output=zend_ini_parser.c -v -d -p ini_ zend_ini_parser.y
|
||||
|
||||
"$(InputDir)\zend_ini_parser.c" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
$(BuildCmds)
|
||||
|
||||
"$(InputDir)\zend_ini_parser.h" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
$(BuildCmds)
|
||||
# End Custom Build
|
||||
|
||||
!ENDIF
|
||||
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=".\zend_language_parser.y"
|
||||
|
||||
!IF "$(CFG)" == "ZendTS - Win32 Release_TS"
|
||||
|
||||
# Begin Custom Build
|
||||
InputDir=.
|
||||
InputPath=".\zend_language_parser.y"
|
||||
|
||||
BuildCmds= \
|
||||
bison --output=zend_language_parser.c -v -d -p zend zend_language_parser.y
|
||||
|
||||
"$(InputDir)\zend_language_parser.c" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
$(BuildCmds)
|
||||
|
||||
"$(InputDir)\zend_language_parser.h" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
$(BuildCmds)
|
||||
# End Custom Build
|
||||
|
||||
!ELSEIF "$(CFG)" == "ZendTS - Win32 Debug_TS"
|
||||
|
||||
# Begin Custom Build
|
||||
InputDir=.
|
||||
InputPath=".\zend_language_parser.y"
|
||||
|
||||
BuildCmds= \
|
||||
bison --output=zend_language_parser.c -v -d -p zend zend_language_parser.y
|
||||
|
||||
"$(InputDir)\zend_language_parser.c" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
$(BuildCmds)
|
||||
|
||||
"$(InputDir)\zend_language_parser.h" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
$(BuildCmds)
|
||||
# End Custom Build
|
||||
|
||||
!ELSEIF "$(CFG)" == "ZendTS - Win32 Release_TS_inline"
|
||||
|
||||
# Begin Custom Build
|
||||
InputDir=.
|
||||
InputPath=".\zend_language_parser.y"
|
||||
|
||||
BuildCmds= \
|
||||
bison --output=zend_language_parser.c -v -d -p zend zend_language_parser.y
|
||||
|
||||
"$(InputDir)\zend_language_parser.c" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
$(BuildCmds)
|
||||
|
||||
"$(InputDir)\zend_language_parser.h" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
$(BuildCmds)
|
||||
# End Custom Build
|
||||
|
||||
!ELSEIF "$(CFG)" == "ZendTS - Win32 Release_TSDbg"
|
||||
|
||||
# Begin Custom Build
|
||||
InputDir=.
|
||||
InputPath=".\zend_language_parser.y"
|
||||
|
||||
BuildCmds= \
|
||||
bison --output=zend_language_parser.c -v -d -p zend zend_language_parser.y
|
||||
|
||||
"$(InputDir)\zend_language_parser.c" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
$(BuildCmds)
|
||||
|
||||
"$(InputDir)\zend_language_parser.h" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
$(BuildCmds)
|
||||
# End Custom Build
|
||||
|
||||
!ENDIF
|
||||
|
||||
# End Source File
|
||||
# End Group
|
||||
# Begin Group "Scanners"
|
||||
|
||||
# PROP Default_Filter "l"
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\flex.skl
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_ini_scanner.l
|
||||
|
||||
!IF "$(CFG)" == "ZendTS - Win32 Release_TS"
|
||||
|
||||
# Begin Custom Build
|
||||
InputPath=.\zend_ini_scanner.l
|
||||
|
||||
"zend_ini_scanner.c" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
flex -B -i -Sflex.skl -Pini_ -ozend_ini_scanner.c zend_ini_scanner.l
|
||||
|
||||
# End Custom Build
|
||||
|
||||
!ELSEIF "$(CFG)" == "ZendTS - Win32 Debug_TS"
|
||||
|
||||
# Begin Custom Build
|
||||
InputPath=.\zend_ini_scanner.l
|
||||
|
||||
"zend_ini_scanner.c" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
flex -B -i -Sflex.skl -Pini_ -ozend_ini_scanner.c zend_ini_scanner.l
|
||||
|
||||
# End Custom Build
|
||||
|
||||
!ELSEIF "$(CFG)" == "ZendTS - Win32 Release_TS_inline"
|
||||
|
||||
# Begin Custom Build
|
||||
InputPath=.\zend_ini_scanner.l
|
||||
|
||||
"zend_ini_scanner.c" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
flex -B -i -Sflex.skl -Pini_ -ozend_ini_scanner.c zend_ini_scanner.l
|
||||
|
||||
# End Custom Build
|
||||
|
||||
!ELSEIF "$(CFG)" == "ZendTS - Win32 Release_TSDbg"
|
||||
|
||||
# Begin Custom Build
|
||||
InputPath=.\zend_ini_scanner.l
|
||||
|
||||
"zend_ini_scanner.c" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
flex -B -i -Sflex.skl -Pini_ -ozend_ini_scanner.c zend_ini_scanner.l
|
||||
|
||||
# End Custom Build
|
||||
|
||||
!ENDIF
|
||||
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=".\zend_language_scanner.l"
|
||||
|
||||
!IF "$(CFG)" == "ZendTS - Win32 Release_TS"
|
||||
|
||||
# Begin Custom Build
|
||||
InputPath=".\zend_language_scanner.l"
|
||||
|
||||
"zend_language_scanner.c" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
flex -B -i -Sflex.skl -Pzend -ozend_language_scanner.c zend_language_scanner.l
|
||||
|
||||
# End Custom Build
|
||||
|
||||
!ELSEIF "$(CFG)" == "ZendTS - Win32 Debug_TS"
|
||||
|
||||
# Begin Custom Build
|
||||
InputPath=".\zend_language_scanner.l"
|
||||
|
||||
"zend_language_scanner.c" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
flex -B -i -Sflex.skl -Pzend -ozend_language_scanner.c zend_language_scanner.l
|
||||
|
||||
# End Custom Build
|
||||
|
||||
!ELSEIF "$(CFG)" == "ZendTS - Win32 Release_TS_inline"
|
||||
|
||||
# Begin Custom Build
|
||||
InputPath=".\zend_language_scanner.l"
|
||||
|
||||
"zend_language_scanner.c" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
flex -B -i -Sflex.skl -Pzend -ozend_language_scanner.c zend_language_scanner.l
|
||||
|
||||
# End Custom Build
|
||||
|
||||
!ELSEIF "$(CFG)" == "ZendTS - Win32 Release_TSDbg"
|
||||
|
||||
# Begin Custom Build
|
||||
InputPath=".\zend_language_scanner.l"
|
||||
|
||||
"zend_language_scanner.c" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
flex -B -i -Sflex.skl -Pzend -ozend_language_scanner.c zend_language_scanner.l
|
||||
|
||||
# End Custom Build
|
||||
|
||||
!ENDIF
|
||||
|
||||
# End Source File
|
||||
# End Group
|
||||
# Begin Group "Text Files"
|
||||
|
||||
# PROP Default_Filter ""
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\LICENSE
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\ZEND_BUGS
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\ZEND_CHANGES
|
||||
# End Source File
|
||||
# End Group
|
||||
# Begin Group "Resources"
|
||||
|
||||
# PROP Default_Filter ""
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend.ico
|
||||
# End Source File
|
||||
# End Group
|
||||
# End Target
|
||||
# End Project
|
||||
-105
@@ -1,105 +0,0 @@
|
||||
/*
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2003 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 |
|
||||
| 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 |
|
||||
| obtain it through the world-wide-web, please send a note to |
|
||||
| license@zend.com so we can mail you a copy immediately. |
|
||||
+----------------------------------------------------------------------+
|
||||
| Authors: Andi Gutmans <andi@zend.com> |
|
||||
| Zeev Suraski <zeev@zend.com> |
|
||||
+----------------------------------------------------------------------+
|
||||
*/
|
||||
|
||||
/* $Id$ */
|
||||
|
||||
#define ZEND_API
|
||||
#define ZEND_DLEXPORT
|
||||
#define ZEND_DLIMPORT
|
||||
|
||||
#ifndef NETWARE
|
||||
@TOP@
|
||||
#endif
|
||||
|
||||
#undef uint
|
||||
#undef ulong
|
||||
|
||||
/* Define if you want to enable memory limit support */
|
||||
#define MEMORY_LIMIT 0
|
||||
|
||||
#ifndef NETWARE
|
||||
@BOTTOM@
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_STDLIB_H
|
||||
# include <stdlib.h>
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_SYS_TYPES_H
|
||||
# include <sys/types.h>
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_IEEEFP_H
|
||||
# include <ieeefp.h>
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_STRING_H
|
||||
# include <string.h>
|
||||
#else
|
||||
# include <strings.h>
|
||||
#endif
|
||||
|
||||
#if ZEND_BROKEN_SPRINTF
|
||||
int zend_sprintf(char *buffer, const char *format, ...);
|
||||
#else
|
||||
# define zend_sprintf sprintf
|
||||
#endif
|
||||
|
||||
#include <math.h>
|
||||
|
||||
#ifndef zend_isnan
|
||||
#ifdef HAVE_ISNAN
|
||||
#define zend_isnan(a) isnan(a)
|
||||
#elif defined(NAN)
|
||||
#define zend_isnan(a) (((a)==NAN)?1:0)
|
||||
#elif defined(HAVE_FPCLASS)
|
||||
#define zend_isnan(a) ((fpclass(a) == FP_SNAN) || (fpclass(a) == FP_QNAN))
|
||||
#else
|
||||
#define zend_isnan(a) 0
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_ISINF
|
||||
#define zend_isinf(a) isinf(a)
|
||||
#elif defined(INFINITY)
|
||||
/* Might not work, but is required by ISO C99 */
|
||||
#define zend_isinf(a) (((a)==INFINITY)?1:0)
|
||||
#elif defined(HAVE_FPCLASS)
|
||||
#define zend_isinf(a) ((fpclass(a) == FP_PINF) || (fpclass(a) == FP_NINF))
|
||||
#else
|
||||
#define zend_isinf(a) 0
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_FINITE
|
||||
#define zend_finite(a) finite(a)
|
||||
#elif defined(HAVE_ISFINITE) || defined(isfinite)
|
||||
#define zend_finite(a) isfinite(a)
|
||||
#elif defined(fpclassify)
|
||||
#define zend_finite(a) ((fpclassify((a))!=FP_INFINITE&&fpclassify((a))!=FP_NAN)?1:0)
|
||||
#else
|
||||
#define zend_finite(a) (zend_isnan(a) ? 0 : zend_isinf(a) ? 0 : 1)
|
||||
#endif
|
||||
|
||||
/*
|
||||
* Local variables:
|
||||
* tab-width: 4
|
||||
* c-basic-offset: 4
|
||||
* indent-tabs-mode: t
|
||||
* End:
|
||||
*/
|
||||
@@ -1,47 +0,0 @@
|
||||
dnl $Id$
|
||||
dnl
|
||||
dnl This file contains local autoconf functions.
|
||||
|
||||
AC_DEFUN(ZEND_FP_EXCEPT,[
|
||||
AC_CACHE_CHECK(whether fp_except is defined, ac_cv_type_fp_except,[
|
||||
AC_TRY_COMPILE([
|
||||
#include <floatingpoint.h>
|
||||
],[
|
||||
fp_except x = (fp_except) 0;
|
||||
],[
|
||||
ac_cv_type_fp_except=yes
|
||||
],[
|
||||
ac_cv_type_fp_except=no
|
||||
],[
|
||||
ac_cv_type_fp_except=no
|
||||
])])
|
||||
if test "$ac_cv_type_fp_except" = "yes"; then
|
||||
AC_DEFINE(HAVE_FP_EXCEPT, 1, [whether floatingpoint.h defines fp_except])
|
||||
fi
|
||||
])
|
||||
|
||||
dnl
|
||||
dnl Check for broken sprintf()
|
||||
dnl
|
||||
AC_DEFUN(AC_ZEND_BROKEN_SPRINTF,[
|
||||
AC_CACHE_CHECK(whether sprintf is broken, ac_cv_broken_sprintf,[
|
||||
AC_TRY_RUN([main() {char buf[20];exit(sprintf(buf,"testing 123")!=11); }],[
|
||||
ac_cv_broken_sprintf=no
|
||||
],[
|
||||
ac_cv_broken_sprintf=yes
|
||||
],[
|
||||
ac_cv_broken_sprintf=no
|
||||
])
|
||||
])
|
||||
if test "$ac_cv_broken_sprintf" = "yes"; then
|
||||
ac_result=1
|
||||
else
|
||||
ac_result=0
|
||||
fi
|
||||
AC_DEFINE_UNQUOTED(ZEND_BROKEN_SPRINTF, $ac_result, [Whether sprintf is broken])
|
||||
])
|
||||
|
||||
AC_DEFUN(AM_SET_LIBTOOL_VARIABLE,[
|
||||
LIBTOOL='$(SHELL) $(top_builddir)/libtool $1'
|
||||
])
|
||||
|
||||
@@ -1,43 +0,0 @@
|
||||
# Makefile to generate build tools
|
||||
#
|
||||
# Standard usage:
|
||||
# make -f build.mk
|
||||
#
|
||||
# Written by Sascha Schumann
|
||||
#
|
||||
# $Id$
|
||||
|
||||
|
||||
LT_TARGETS = ltmain.sh ltconfig
|
||||
|
||||
config_h_in = zend_config.h.in
|
||||
|
||||
makefile_am_files = Makefile.am
|
||||
makefile_in_files = $(makefile_am_files:.am=.in)
|
||||
makefile_files = $(makefile_am_files:e.am=e)
|
||||
|
||||
targets = $(makefile_in_files) $(LT_TARGETS) configure $(config_h_in)
|
||||
|
||||
all: $(targets)
|
||||
|
||||
clean:
|
||||
rm -f $(targets)
|
||||
|
||||
$(LT_TARGETS):
|
||||
rm -f $(LT_TARGETS)
|
||||
libtoolize --automake $(AMFLAGS) -f
|
||||
|
||||
$(makefile_in_files): $(makefile_am_files)
|
||||
automake -a -i $(AMFLAGS) $(makefile_files)
|
||||
|
||||
aclocal.m4: configure.in acinclude.m4
|
||||
aclocal
|
||||
|
||||
$(config_h_in): configure.in acconfig.h
|
||||
# explicitly remove target since autoheader does not seem to work
|
||||
# correctly otherwise (timestamps are not updated)
|
||||
@rm -f $@
|
||||
autoheader
|
||||
|
||||
configure: aclocal.m4 configure.in
|
||||
autoconf
|
||||
@@ -1,33 +0,0 @@
|
||||
#!/bin/sh
|
||||
|
||||
case "$1" in
|
||||
--copy)
|
||||
automake_flags=--copy
|
||||
shift
|
||||
;;
|
||||
esac
|
||||
|
||||
libtoolize --force --automake $automake_flags
|
||||
|
||||
mv aclocal.m4 aclocal.m4.old 2>/dev/null
|
||||
aclocal
|
||||
if cmp aclocal.m4.old aclocal.m4 > /dev/null 2>&1; then
|
||||
echo "buildconf: keeping ${1}aclocal.m4"
|
||||
mv aclocal.m4.old aclocal.m4
|
||||
else
|
||||
echo "buildconf: created or modified ${1}aclocal.m4"
|
||||
fi
|
||||
|
||||
autoheader
|
||||
|
||||
automake --add-missing --include-deps $automake_flags
|
||||
|
||||
mv configure configure.old 2>/dev/null
|
||||
autoconf
|
||||
if cmp configure.old configure > /dev/null 2>&1; then
|
||||
echo "buildconf: keeping ${1}configure"
|
||||
mv configure.old configure
|
||||
else
|
||||
echo "buildconf: created or modified ${1}configure"
|
||||
fi
|
||||
|
||||
@@ -1,47 +0,0 @@
|
||||
dnl $Id$
|
||||
dnl Process this file with autoconf to produce a configure script.
|
||||
|
||||
AC_INIT(zend.c)
|
||||
AM_INIT_AUTOMAKE(zend, 0.80A, nodefine)
|
||||
AM_CONFIG_HEADER(zend_config.h)
|
||||
AM_SANITY_CHECK
|
||||
AM_MAINTAINER_MODE
|
||||
AC_PROG_CC
|
||||
AM_PROG_LEX
|
||||
AM_PROG_CC_STDC
|
||||
ZEND_VERSION=$VERSION
|
||||
|
||||
dnl We want this one before the checks, so the checks can modify CFLAGS.
|
||||
test -z "$CFLAGS" && auto_cflags=1
|
||||
|
||||
sinclude(Zend.m4)
|
||||
|
||||
LIBZEND_BASIC_CHECKS
|
||||
LIBZEND_LIBDL_CHECKS
|
||||
LIBZEND_DLSYM_CHECK
|
||||
|
||||
AM_PROG_LIBTOOL
|
||||
if test "$enable_debug" != "yes"; then
|
||||
AM_SET_LIBTOOL_VARIABLE([--silent])
|
||||
fi
|
||||
|
||||
dnl
|
||||
dnl Check for /usr/pkg/{lib,include} which is where NetBSD puts binary
|
||||
dnl and source packages. This should be harmless on other OSs.
|
||||
dnl
|
||||
if test -d /usr/pkg/include -a -d /usr/pkg/lib ; then
|
||||
CFLAGS="$CFLAGS -I/usr/pkg/include"
|
||||
LDFLAGS="$LDFLAGS -L/usr/pkg/lib"
|
||||
fi
|
||||
|
||||
LIBZEND_ENABLE_DEBUG
|
||||
LIBZEND_OTHER_CHECKS
|
||||
|
||||
ZEND_EXTRA_LIBS="$LIBS"
|
||||
LIBS=""
|
||||
AC_SUBST(ZEND_EXTRA_LIBS)
|
||||
AC_OUTPUT(Makefile)
|
||||
|
||||
# Local Variables:
|
||||
# tab-width: 4
|
||||
# End:
|
||||
-1648
File diff suppressed because it is too large.
Load diff
@@ -1,22 +0,0 @@
|
||||
--TEST--
|
||||
Bug #19859 (__call() does not catch call_user_func_array() calls)
|
||||
--SKIPIF--
|
||||
<?php if (version_compare(zend_version(), '2.0.0-dev', '<')) die('skip ZendEngine 2 is needed'); ?>
|
||||
--FILE--
|
||||
<?php
|
||||
class test
|
||||
{
|
||||
function __call($method,$args)
|
||||
{
|
||||
print "test::__call invoked for method '$method'\n";
|
||||
}
|
||||
}
|
||||
$x = new test;
|
||||
$x->fake(1);
|
||||
call_user_func_array(array($x,'fake'),array(1));
|
||||
call_user_func(array($x,'fake'),2);
|
||||
?>
|
||||
--EXPECT--
|
||||
test::__call invoked for method 'fake'
|
||||
test::__call invoked for method 'fake'
|
||||
test::__call invoked for method 'fake'
|
||||
@@ -1,43 +0,0 @@
|
||||
--TEST--
|
||||
Bug #20240 (order of destructor calls)
|
||||
--SKIPIF--
|
||||
<?php if (version_compare(zend_version(), '2.0.0-dev', '<')) die('skip ZendEngine 2 is needed'); ?>
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
class test
|
||||
{
|
||||
public $member;
|
||||
|
||||
function test() {
|
||||
$this->member = 1;
|
||||
register_shutdown_function(array($this, 'destructor'));
|
||||
}
|
||||
|
||||
function destructor() {
|
||||
print __METHOD__ . "\n";
|
||||
}
|
||||
|
||||
function __destruct() {
|
||||
print __METHOD__ . "\n";
|
||||
}
|
||||
|
||||
function add() {
|
||||
$this->member += 1;
|
||||
print $this->member."\n";
|
||||
}
|
||||
}
|
||||
|
||||
$t = new test();
|
||||
|
||||
$t->add();
|
||||
$t->add();
|
||||
|
||||
echo "Done\n";
|
||||
?>
|
||||
--EXPECT--
|
||||
2
|
||||
3
|
||||
Done
|
||||
test::destructor
|
||||
test::__destruct
|
||||
@@ -1,26 +0,0 @@
|
||||
--TEST--
|
||||
Bug #20242 (Method call in front of class definition)
|
||||
--SKIPIF--
|
||||
<?php if (version_compare(zend_version(), '2.0.0-dev', '>=')) die('skip ZendEngine 2 does not support this'); ?>
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
// THIS IS A WON'T FIX FOR ZE2
|
||||
|
||||
test::show_static();
|
||||
|
||||
$t = new test;
|
||||
$t->show_method();
|
||||
|
||||
class test {
|
||||
static function show_static() {
|
||||
echo "static\n";
|
||||
}
|
||||
function show_method() {
|
||||
echo "method\n";
|
||||
}
|
||||
}
|
||||
?>
|
||||
--EXPECT--
|
||||
static
|
||||
method
|
||||
@@ -1,37 +0,0 @@
|
||||
--TEST--
|
||||
Bug #21478 (Zend/zend_alloc.c :: shutdown_memory_manager produces segfault)
|
||||
--SKIPIF--
|
||||
<?php
|
||||
if (version_compare(zend_version(), '2.0.0-dev', '<')) die('skip ZendEngine 2 is needed');
|
||||
if (!function_exists('stream_filter_register')) die('skip stream_filter_register() not available');
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
class debugfilter extends php_user_filter {
|
||||
function filter($in, $out, &$consumed, $closing) {
|
||||
while ($bucket = stream_bucket_make_writeable($in)) {
|
||||
$bucket->data = strtoupper($bucket->data);
|
||||
stream_bucket_append($out, $bucket);
|
||||
$consumed += strlen($bucket->data);
|
||||
}
|
||||
return PSFS_PASS_ON;
|
||||
}
|
||||
}
|
||||
|
||||
stream_filter_register("myfilter","debugfilter");
|
||||
|
||||
$fp = fopen(dirname(__FILE__)."/test.txt","w");
|
||||
stream_filter_append($fp, "myfilter");
|
||||
stream_filter_append($fp, "myfilter");
|
||||
stream_filter_append($fp, "myfilter");
|
||||
fwrite($fp, "This is a test.\n");
|
||||
print "Done.\n";
|
||||
fclose($fp);
|
||||
// Uncommenting the following 'print' line causes the segfault to stop occuring
|
||||
// print "2\n";
|
||||
readfile(dirname(__FILE__)."/test.txt");
|
||||
unlink(dirname(__FILE__)."/test.txt");
|
||||
?>
|
||||
--EXPECT--
|
||||
Done.
|
||||
THIS IS A TEST.
|
||||
@@ -1,39 +0,0 @@
|
||||
--TEST--
|
||||
Bug #21888 (protected property and protected method of the same name)
|
||||
--SKIPIF--
|
||||
<?php
|
||||
if (version_compare(zend_version(), '2.0.0-dev', '<')) die('skip ZendEngine 2 is needed');
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
class mom {
|
||||
|
||||
protected $prot = "protected property\n";
|
||||
|
||||
protected function prot() {
|
||||
print "protected method\n";
|
||||
}
|
||||
}
|
||||
|
||||
class child extends mom {
|
||||
|
||||
public function callMom() {
|
||||
$this->prot();
|
||||
}
|
||||
|
||||
public function viewMom() {
|
||||
print $this->prot;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
$c = new child();
|
||||
$c->callMom();
|
||||
$c->viewMom();
|
||||
?>
|
||||
--EXPECT--
|
||||
protected method
|
||||
protected property
|
||||
--EXPECT--
|
||||
protected method
|
||||
protected property
|
||||
@@ -1,31 +0,0 @@
|
||||
--TEST--
|
||||
bug #22725 (A derived class can call a parent's protected method that calls a private method)
|
||||
--SKIPIF--
|
||||
<?php if (version_compare(zend_version(), '2.0.0-dev', '<')) die('skip ZendEngine 2 needed'); ?>
|
||||
--FILE--
|
||||
<?php
|
||||
class Foo {
|
||||
private function aPrivateMethod() {
|
||||
echo "Foo::aPrivateMethod() called.\n";
|
||||
}
|
||||
|
||||
protected function aProtectedMethod() {
|
||||
echo "Foo::aProtectedMethod() called.\n";
|
||||
$this->aPrivateMethod();
|
||||
}
|
||||
}
|
||||
|
||||
class Bar extends Foo {
|
||||
public function aPublicMethod() {
|
||||
echo "Bar::aPublicMethod() called.\n";
|
||||
$this->aProtectedMethod();
|
||||
}
|
||||
}
|
||||
|
||||
$o = new Bar;
|
||||
$o->aPublicMethod();
|
||||
?>
|
||||
--EXPECT--
|
||||
Bar::aPublicMethod() called.
|
||||
Foo::aProtectedMethod() called.
|
||||
Foo::aPrivateMethod() called.
|
||||
@@ -1,24 +0,0 @@
|
||||
--TEST--
|
||||
Bug #22836 (returning references to NULL)
|
||||
--SKIPIF--
|
||||
<?php if (version_compare(zend_version(), '2.0.0-dev', '<')) die('skip ZendEngine 2 is needed'); ?>
|
||||
--FILE--
|
||||
<?php
|
||||
function &f()
|
||||
{
|
||||
$x = "foo";
|
||||
var_dump($x);
|
||||
print "'$x'\n";
|
||||
return ($a);
|
||||
}
|
||||
for ($i = 0; $i < 8; $i++) {
|
||||
$h =& f();
|
||||
}
|
||||
?>
|
||||
--EXPECTF--
|
||||
string(3) "foo"
|
||||
'foo'
|
||||
|
||||
Notice: Undefined variable: a in %s on line %d
|
||||
|
||||
Fatal error: Only variables or references can be returned by reference in %s on line %d
|
||||
@@ -1,24 +0,0 @@
|
||||
--TEST--
|
||||
Bug #24436 (isset()/empty() produce errors with non-existent variables in classes)
|
||||
--SKIPIF--
|
||||
<?php if (version_compare(zend_version(), '2.0.0-dev', '<')) die('skip ZendEngine 2 is needed'); ?>
|
||||
--INI--
|
||||
error_reporting=2047
|
||||
--FILE--
|
||||
<?php
|
||||
class test {
|
||||
function __construct() {
|
||||
if (empty($this->test[0][0])) { print "test1\n";}
|
||||
if (!isset($this->test[0][0])) { print "test2\n";}
|
||||
if (empty($this->test)) { print "test1\n";}
|
||||
if (!isset($this->test)) { print "test2\n";}
|
||||
}
|
||||
}
|
||||
|
||||
$test1 = new test();
|
||||
?>
|
||||
--EXPECT--
|
||||
test1
|
||||
test2
|
||||
test1
|
||||
test2
|
||||
@@ -1,30 +0,0 @@
|
||||
--TEST--
|
||||
Bug #24635 (crash on dtor calling other functions)
|
||||
--SKIPIF--
|
||||
<?php if (version_compare(zend_version(), '2.0.0-dev', '<')) die('skip ZendEngine 2 is needed'); ?>
|
||||
--FILE--
|
||||
<?php
|
||||
class SiteClass {
|
||||
function __construct() { $this->page = new PageClass(); }
|
||||
}
|
||||
class PageClass {
|
||||
function Display() {
|
||||
$section = new SectionClass("PageClass::Display");
|
||||
}
|
||||
}
|
||||
class SectionClass {
|
||||
function __construct($comment) {
|
||||
$this->Comment = $comment;
|
||||
}
|
||||
function __destruct() {
|
||||
out($this->Comment); // this line doesn't crash PHP
|
||||
out("\n<!-- End Section: " . $this->Comment . "-->"); // this line
|
||||
}
|
||||
}
|
||||
function out($code) { return; }
|
||||
$site = new SiteClass();
|
||||
$site->page->Display();
|
||||
echo "OK\n";
|
||||
?>
|
||||
--EXPECT--
|
||||
OK
|
||||
@@ -1,13 +0,0 @@
|
||||
--TEST--
|
||||
Bug #24699 (Memory Leak with per-class constants)
|
||||
--SKIPIF--
|
||||
<?php if (version_compare(zend_version(), '2.0.0-dev', '<')) die('skip ZendEngine 2 is needed'); ?>
|
||||
--FILE--
|
||||
<?php
|
||||
class TEST { const FOO = SEEK_CUR; };
|
||||
class TEST2 { const FOO = 1; };
|
||||
class TEST3 { const FOO = PHP_VERSION; };
|
||||
print TEST::FOO."\n";
|
||||
?>
|
||||
--EXPECT--
|
||||
1
|
||||
@@ -1,28 +0,0 @@
|
||||
--TEST--
|
||||
Bug #24884 (calling $this->__clone(); crashes php)
|
||||
--SKIPIF--
|
||||
<?php if (version_compare(zend_version(), '2.0.0-dev', '<')) die('skip ZendEngine 2 needed'); ?>
|
||||
--FILE--
|
||||
<?php
|
||||
class Test {
|
||||
function __copy()
|
||||
{
|
||||
$string = PHP_VERSION;
|
||||
$version = $string{0};
|
||||
if($string < 5)
|
||||
{
|
||||
return $this;
|
||||
}
|
||||
else
|
||||
{
|
||||
return $this->__clone();
|
||||
}
|
||||
}
|
||||
}
|
||||
$test = new Test();
|
||||
$test2 = $test->__copy();
|
||||
var_dump($test2);
|
||||
?>
|
||||
--EXPECT--
|
||||
object(test)#2 (0) {
|
||||
}
|
||||
@@ -1,19 +0,0 @@
|
||||
--TEST--
|
||||
Bug #26010 (private / protected variables get exposed by get_object_vars())
|
||||
--FILE--
|
||||
<?php
|
||||
class foo {
|
||||
private $private = 'private';
|
||||
protected $protected = 'protected';
|
||||
public $public = 'public';
|
||||
}
|
||||
$data = new foo();
|
||||
$obj_vars = get_object_vars($data);
|
||||
var_dump($obj_vars);
|
||||
?>
|
||||
--EXPECT--
|
||||
array(1) {
|
||||
["public"]=>
|
||||
string(6) "public"
|
||||
}
|
||||
|
||||
@@ -1,67 +0,0 @@
|
||||
--TEST--
|
||||
Bug #26166: __toString() crash when no values returned
|
||||
--FILE--
|
||||
<?php
|
||||
class Foo
|
||||
{
|
||||
function __toString()
|
||||
{
|
||||
return "Hello World!\n";
|
||||
}
|
||||
}
|
||||
|
||||
class Bar
|
||||
{
|
||||
private $obj;
|
||||
|
||||
function __construct()
|
||||
{
|
||||
$this->obj = new Foo();
|
||||
}
|
||||
|
||||
function __toString()
|
||||
{
|
||||
return $this->obj->__toString();
|
||||
}
|
||||
}
|
||||
|
||||
$o = new Bar;
|
||||
echo $o;
|
||||
|
||||
echo "===THROW===\n";
|
||||
|
||||
class Error
|
||||
{
|
||||
function __toString() {
|
||||
throw new Exception("This is an error!");
|
||||
}
|
||||
}
|
||||
|
||||
$o = new Error;
|
||||
try {
|
||||
echo $o;
|
||||
}
|
||||
catch (Exception $e) {
|
||||
echo "Got the exception\n";
|
||||
}
|
||||
|
||||
echo "===NONE===\n";
|
||||
|
||||
class None
|
||||
{
|
||||
function __toString() {
|
||||
}
|
||||
}
|
||||
|
||||
$o = new None;
|
||||
echo $o;
|
||||
|
||||
?>
|
||||
===DONE===
|
||||
--EXPECTF--
|
||||
Hello World!
|
||||
===THROW===
|
||||
Got the exception
|
||||
===NONE===
|
||||
|
||||
Fatal error: Method none::__toString() must return a string value in %sbug26166.php on line %d
|
||||
@@ -1,13 +0,0 @@
|
||||
--TEST--
|
||||
Bug #26281 (switch() crash when condition is a string offset)
|
||||
--FILE--
|
||||
<?php
|
||||
$x = 'abc';
|
||||
switch ($x{0}) {
|
||||
case 'a':
|
||||
echo "no crash\n";
|
||||
break;
|
||||
}
|
||||
?>
|
||||
--EXPECT--
|
||||
no crash
|
||||
@@ -1,34 +0,0 @@
|
||||
--TEST--
|
||||
Scoping in destructor call
|
||||
--SKIPIF--
|
||||
<?php if (version_compare(zend_version(), '2.0.0-dev', '<')) die('skip ZendEngine 2 needed'); ?>
|
||||
--FILE--
|
||||
<?php
|
||||
class T
|
||||
{
|
||||
private $var = array();
|
||||
|
||||
public function add($a)
|
||||
{
|
||||
array_push($this->var, $a);
|
||||
}
|
||||
|
||||
public function __destruct()
|
||||
{
|
||||
print_r($this->var);
|
||||
}
|
||||
}
|
||||
|
||||
class TT extends T
|
||||
{
|
||||
}
|
||||
$t = new TT();
|
||||
$t->add("Hello");
|
||||
$t->add("World");
|
||||
?>
|
||||
--EXPECT--
|
||||
Array
|
||||
(
|
||||
[0] => Hello
|
||||
[1] => World
|
||||
)
|
||||
@@ -1,275 +0,0 @@
|
||||
Example 1: A singleton (static members)
|
||||
=======================================
|
||||
|
||||
<?php
|
||||
|
||||
class Counter {
|
||||
var $counter = 0;
|
||||
|
||||
function increment_and_print()
|
||||
{
|
||||
print ++$this->counter;
|
||||
print "\n";
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
class SingletonCounter {
|
||||
static $m_instance = NULL;
|
||||
|
||||
function Instance()
|
||||
{
|
||||
if (self::$m_instance == NULL) {
|
||||
self::$m_instance = new Counter();
|
||||
}
|
||||
return self::$m_instance;
|
||||
}
|
||||
}
|
||||
|
||||
SingletonCounter::Instance()->increment_and_print();
|
||||
SingletonCounter::Instance()->increment_and_print();
|
||||
SingletonCounter::Instance()->increment_and_print();
|
||||
|
||||
?>
|
||||
|
||||
Example 2: Factory method (derefencing objects returned from functions)
|
||||
=======================================================================
|
||||
|
||||
<?php
|
||||
|
||||
class Circle {
|
||||
function draw()
|
||||
{
|
||||
print "Circle\n";
|
||||
}
|
||||
}
|
||||
|
||||
class Square {
|
||||
function draw()
|
||||
{
|
||||
print "Square\n";
|
||||
}
|
||||
}
|
||||
|
||||
function ShapeFactoryMethod($shape)
|
||||
{
|
||||
switch ($shape) {
|
||||
case "Circle":
|
||||
return new Circle();
|
||||
case "Square":
|
||||
return new Square();
|
||||
}
|
||||
}
|
||||
|
||||
ShapeFactoryMethod("Circle")->draw();
|
||||
ShapeFactoryMethod("Square")->draw();
|
||||
|
||||
|
||||
?>
|
||||
|
||||
Example 3: Class constants and class scope
|
||||
==========================================
|
||||
|
||||
<?php
|
||||
|
||||
class ErrorCodes {
|
||||
const FATAL = "Fatal error\n";
|
||||
const WARNING = "Warning\n";
|
||||
const INFO = "Informational message\n";
|
||||
|
||||
function print_fatal_error_codes()
|
||||
{
|
||||
print "FATAL = " . FATAL;
|
||||
print "self::FATAL = " . self::FATAL;
|
||||
}
|
||||
}
|
||||
|
||||
/* Call the static function and move into the ErrorCodes scope */
|
||||
ErrorCodes::print_fatal_error_codes();
|
||||
|
||||
?>
|
||||
|
||||
Example 4: Regular object method using both local and global functions
|
||||
======================================================================
|
||||
|
||||
<?php
|
||||
|
||||
class HelloWorld {
|
||||
const HELLO_WORLD = "Hello, World!\n";
|
||||
|
||||
function get_hello_world()
|
||||
{
|
||||
return HELLO_WORLD;
|
||||
}
|
||||
|
||||
function length_of_hello_world()
|
||||
{
|
||||
$str = $this->get_hello_world();
|
||||
return strlen($str);
|
||||
}
|
||||
}
|
||||
|
||||
$obj = new HelloWorld();
|
||||
print "length_of_hello_world() = " . $obj->length_of_hello_world();
|
||||
print "\n";
|
||||
?>
|
||||
|
||||
Example 5: Multiple derefencing of objects returned from methods
|
||||
================================================================
|
||||
|
||||
<?php
|
||||
|
||||
|
||||
class Name {
|
||||
function Name($_name)
|
||||
{
|
||||
$this->name = $_name;
|
||||
}
|
||||
|
||||
function display()
|
||||
{
|
||||
print $this->name;
|
||||
print "\n";
|
||||
}
|
||||
}
|
||||
|
||||
class Person {
|
||||
function Person($_name, $_address)
|
||||
{
|
||||
$this->name = new Name($_name);
|
||||
}
|
||||
|
||||
function getName()
|
||||
{
|
||||
return $this->name;
|
||||
}
|
||||
}
|
||||
|
||||
$person = new Person("John", "New York");
|
||||
$person->getName()->display();
|
||||
|
||||
?>
|
||||
|
||||
Example 6: Exception handling
|
||||
=============================
|
||||
|
||||
<?
|
||||
class MyException {
|
||||
function MyException($_error) {
|
||||
$this->error = $_error;
|
||||
}
|
||||
|
||||
function getException()
|
||||
{
|
||||
return $this->error;
|
||||
}
|
||||
}
|
||||
|
||||
function ThrowException()
|
||||
{
|
||||
throw new MyException("'This is an exception!'");
|
||||
}
|
||||
|
||||
|
||||
try {
|
||||
} catch (MyException $exception) {
|
||||
print "There was an exception: " . $exception->getException();
|
||||
print "\n";
|
||||
}
|
||||
|
||||
try {
|
||||
ThrowException();
|
||||
} catch (MyException $exception) {
|
||||
print "There was an exception: " . $exception->getException();
|
||||
print "\n";
|
||||
}
|
||||
|
||||
?>
|
||||
|
||||
Example 7: __clone()
|
||||
===================
|
||||
|
||||
<?
|
||||
class MyCloneable {
|
||||
static $id = 0;
|
||||
|
||||
function MyCloneable()
|
||||
{
|
||||
$this->id = self::$id++;
|
||||
}
|
||||
|
||||
function __clone()
|
||||
{
|
||||
$this->name = $that->name;
|
||||
$this->address = "New York";
|
||||
$this->id = self::$id++;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
$obj = new MyCloneable();
|
||||
|
||||
$obj->name = "Hello";
|
||||
$obj->address = "Tel-Aviv";
|
||||
|
||||
print $obj->id;
|
||||
print "\n";
|
||||
|
||||
$obj = $obj->__clone();
|
||||
|
||||
print $obj->id;
|
||||
print "\n";
|
||||
print $obj->name;
|
||||
print "\n";
|
||||
print $obj->address;
|
||||
print "\n";
|
||||
?>
|
||||
|
||||
Example 8: Unified constructors
|
||||
===============================
|
||||
|
||||
<?
|
||||
|
||||
class BaseClass {
|
||||
function __construct()
|
||||
{
|
||||
print "In BaseClass constructor\n";
|
||||
}
|
||||
}
|
||||
|
||||
class SubClass extends BaseClass {
|
||||
function __construct()
|
||||
{
|
||||
parent::__construct();
|
||||
print "In SubClass constructor\n";
|
||||
}
|
||||
}
|
||||
|
||||
$obj = new BaseClass();
|
||||
|
||||
$obj = new SubClass();
|
||||
|
||||
?>
|
||||
|
||||
Example 9: Destructors
|
||||
=======================
|
||||
|
||||
<?php
|
||||
|
||||
class MyDestructableClass {
|
||||
function __construct()
|
||||
{
|
||||
print "In constructor\n";
|
||||
$this->name = "MyDestructableClass";
|
||||
}
|
||||
|
||||
function __destruct()
|
||||
{
|
||||
print "Destroying " . $this->name . "\n";
|
||||
}
|
||||
}
|
||||
|
||||
$obj = new MyDestructableClass();
|
||||
|
||||
?>
|
||||
-1150
File diff suppressed because it is too large.
Load diff
-610
@@ -1,610 +0,0 @@
|
||||
/*
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2003 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 |
|
||||
| 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 |
|
||||
| obtain it through the world-wide-web, please send a note to |
|
||||
| license@zend.com so we can mail you a copy immediately. |
|
||||
+----------------------------------------------------------------------+
|
||||
| Authors: Andi Gutmans <andi@zend.com> |
|
||||
| Zeev Suraski <zeev@zend.com> |
|
||||
+----------------------------------------------------------------------+
|
||||
*/
|
||||
|
||||
/* $Id$ */
|
||||
|
||||
#ifndef ZEND_H
|
||||
#define ZEND_H
|
||||
|
||||
#define ZEND_VERSION "2.0.0-dev"
|
||||
|
||||
#define ZEND_ENGINE_2
|
||||
|
||||
#ifdef __cplusplus
|
||||
#define BEGIN_EXTERN_C() extern "C" {
|
||||
#define END_EXTERN_C() }
|
||||
#else
|
||||
#define BEGIN_EXTERN_C()
|
||||
#define END_EXTERN_C()
|
||||
#endif
|
||||
|
||||
#include <stdio.h>
|
||||
|
||||
/*
|
||||
* general definitions
|
||||
*/
|
||||
|
||||
#ifdef ZEND_WIN32
|
||||
# include "zend_config.w32.h"
|
||||
# define ZEND_PATHS_SEPARATOR ';'
|
||||
#elif defined(NETWARE)
|
||||
# include "zend_config.nw.h"
|
||||
# include "acconfig.h"
|
||||
#elif defined(__riscos__)
|
||||
# include "zend_config.h"
|
||||
# define ZEND_PATHS_SEPARATOR ';'
|
||||
#else
|
||||
# include "zend_config.h"
|
||||
# define ZEND_PATHS_SEPARATOR ':'
|
||||
#endif
|
||||
|
||||
|
||||
#ifdef ZEND_WIN32
|
||||
/* Only use this macro if you know for sure that all of the switches values
|
||||
are covered by its case statements */
|
||||
#define EMPTY_SWITCH_DEFAULT_CASE() \
|
||||
default: \
|
||||
__assume(0); \
|
||||
break;
|
||||
#else
|
||||
#define EMPTY_SWITCH_DEFAULT_CASE()
|
||||
#endif
|
||||
|
||||
/* all HAVE_XXX test have to be after the include of zend_config above */
|
||||
|
||||
#ifdef HAVE_UNIX_H
|
||||
# include <unix.h>
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_STDARG_H
|
||||
# include <stdarg.h>
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_DLFCN_H
|
||||
# include <dlfcn.h>
|
||||
#endif
|
||||
|
||||
#if HAVE_MACH_O_DYLD_H
|
||||
#include <mach-o/dyld.h>
|
||||
|
||||
/* MH_BUNDLE loading functions for Mac OS X / Darwin */
|
||||
void *zend_mh_bundle_load (char* bundle_path);
|
||||
int zend_mh_bundle_unload (void *bundle_handle);
|
||||
void *zend_mh_bundle_symbol(void *bundle_handle, const char *symbol_name);
|
||||
const char *zend_mh_bundle_error(void);
|
||||
|
||||
#endif /* HAVE_MACH_O_DYLD_H */
|
||||
|
||||
#if defined(HAVE_LIBDL)
|
||||
|
||||
# ifndef RTLD_LAZY
|
||||
# define RTLD_LAZY 1 /* Solaris 1, FreeBSD's (2.1.7.1 and older) */
|
||||
# endif
|
||||
|
||||
# ifndef RTLD_GLOBAL
|
||||
# define RTLD_GLOBAL 0
|
||||
# endif
|
||||
|
||||
# define DL_LOAD(libname) dlopen(libname, RTLD_LAZY | RTLD_GLOBAL)
|
||||
# define DL_UNLOAD dlclose
|
||||
# if defined(DLSYM_NEEDS_UNDERSCORE)
|
||||
# define DL_FETCH_SYMBOL(h,s) dlsym((h), "_" s)
|
||||
# else
|
||||
# define DL_FETCH_SYMBOL dlsym
|
||||
# endif
|
||||
# define DL_ERROR dlerror
|
||||
# define DL_HANDLE void *
|
||||
# define ZEND_EXTENSIONS_SUPPORT 1
|
||||
#elif defined(HAVE_MACH_O_DYLD_H)
|
||||
# define DL_LOAD(libname) zend_mh_bundle_load(libname)
|
||||
# define DL_UNLOAD(handle) zend_mh_bundle_unload(handle)
|
||||
# define DL_FETCH_SYMBOL(h,s) zend_mh_bundle_symbol(h,s)
|
||||
# define DL_ERROR zend_mh_bundle_error
|
||||
# define DL_HANDLE void *
|
||||
# define ZEND_EXTENSIONS_SUPPORT 1
|
||||
#elif defined(ZEND_WIN32)
|
||||
# define DL_LOAD(libname) LoadLibrary(libname)
|
||||
# define DL_FETCH_SYMBOL GetProcAddress
|
||||
# define DL_UNLOAD FreeLibrary
|
||||
# define DL_HANDLE HMODULE
|
||||
# define ZEND_EXTENSIONS_SUPPORT 1
|
||||
#else
|
||||
# define DL_HANDLE void *
|
||||
# define ZEND_EXTENSIONS_SUPPORT 0
|
||||
#endif
|
||||
|
||||
#if HAVE_ALLOCA_H && !defined(_ALLOCA_H)
|
||||
# include <alloca.h>
|
||||
#endif
|
||||
|
||||
/* AIX requires this to be the first thing in the file. */
|
||||
#ifndef __GNUC__
|
||||
# ifndef HAVE_ALLOCA_H
|
||||
# ifdef _AIX
|
||||
#pragma alloca
|
||||
# else
|
||||
# ifndef alloca /* predefined by HP cc +Olibcalls */
|
||||
char *alloca ();
|
||||
# endif
|
||||
# endif
|
||||
# endif
|
||||
#endif
|
||||
|
||||
#ifdef __GNUC__
|
||||
# define ZEND_GCC_VERSION (__GNUC__ * 1000 + __GNUC_MINOR__)
|
||||
#else
|
||||
# define ZEND_GCC_VERSION 0
|
||||
#endif
|
||||
|
||||
#if ZEND_GCC_VERSION >= 2096
|
||||
# define ZEND_ATTRIBUTE_MALLOC __attribute__ ((__malloc__))
|
||||
#else
|
||||
# define ZEND_ATTRIBUTE_MALLOC
|
||||
#endif
|
||||
|
||||
#if ZEND_GCC_VERSION >= 2007
|
||||
# define ZEND_ATTRIBUTE_FORMAT(type, idx, first) __attribute__ ((format(type, idx, first)))
|
||||
#else
|
||||
# define ZEND_ATTRIBUTE_FORMAT(type, idx, first)
|
||||
#endif
|
||||
|
||||
#if ZEND_GCC_VERSION >= 3002
|
||||
# define ZEND_ATTRIBUTE_PTR_FORMAT(type, idx, first) __attribute__ ((format(type, idx, first)))
|
||||
#else
|
||||
# define ZEND_ATTRIBUTE_PTR_FORMAT(type, idx, first)
|
||||
#endif
|
||||
|
||||
|
||||
#if (HAVE_ALLOCA || (defined (__GNUC__) && __GNUC__ >= 2)) && !(defined(ZTS) && defined(ZEND_WIN32)) && !(defined(ZTS) && defined(NETWARE)) && !(defined(ZTS) && defined(HPUX)) && !defined(__darwin__) && !defined(__APPLE__)
|
||||
# define do_alloca(p) alloca(p)
|
||||
# define free_alloca(p)
|
||||
#else
|
||||
# define do_alloca(p) emalloc(p)
|
||||
# define free_alloca(p) efree(p)
|
||||
#endif
|
||||
|
||||
#if ZEND_DEBUG
|
||||
#define ZEND_FILE_LINE_D char *__zend_filename, uint __zend_lineno
|
||||
#define ZEND_FILE_LINE_DC , ZEND_FILE_LINE_D
|
||||
#define ZEND_FILE_LINE_ORIG_D char *__zend_orig_filename, uint __zend_orig_lineno
|
||||
#define ZEND_FILE_LINE_ORIG_DC , ZEND_FILE_LINE_ORIG_D
|
||||
#define ZEND_FILE_LINE_RELAY_C __zend_filename, __zend_lineno
|
||||
#define ZEND_FILE_LINE_RELAY_CC , ZEND_FILE_LINE_RELAY_C
|
||||
#define ZEND_FILE_LINE_C __FILE__, __LINE__
|
||||
#define ZEND_FILE_LINE_CC , ZEND_FILE_LINE_C
|
||||
#define ZEND_FILE_LINE_EMPTY_C NULL, 0
|
||||
#define ZEND_FILE_LINE_EMPTY_CC , ZEND_FILE_LINE_EMPTY_C
|
||||
#define ZEND_FILE_LINE_ORIG_RELAY_C __zend_orig_filename, __zend_orig_lineno
|
||||
#define ZEND_FILE_LINE_ORIG_RELAY_CC , ZEND_FILE_LINE_ORIG_RELAY_C
|
||||
#else
|
||||
#define ZEND_FILE_LINE_D
|
||||
#define ZEND_FILE_LINE_DC
|
||||
#define ZEND_FILE_LINE_ORIG_D
|
||||
#define ZEND_FILE_LINE_ORIG_DC
|
||||
#define ZEND_FILE_LINE_RELAY_C
|
||||
#define ZEND_FILE_LINE_RELAY_CC
|
||||
#define ZEND_FILE_LINE_C
|
||||
#define ZEND_FILE_LINE_CC
|
||||
#define ZEND_FILE_LINE_EMPTY_C
|
||||
#define ZEND_FILE_LINE_EMPTY_CC
|
||||
#define ZEND_FILE_LINE_ORIG_RELAY_C
|
||||
#define ZEND_FILE_LINE_ORIG_RELAY_CC
|
||||
#endif /* ZEND_DEBUG */
|
||||
|
||||
#ifdef ZTS
|
||||
#define ZTS_V 1
|
||||
#else
|
||||
#define ZTS_V 0
|
||||
#endif
|
||||
|
||||
#include "zend_errors.h"
|
||||
#include "zend_alloc.h"
|
||||
|
||||
#include "zend_types.h"
|
||||
|
||||
#ifdef HAVE_LIMITS_H
|
||||
# include <limits.h>
|
||||
#endif
|
||||
|
||||
#ifndef LONG_MAX
|
||||
#define LONG_MAX 2147483647L
|
||||
#endif
|
||||
|
||||
#ifndef LONG_MIN
|
||||
#define LONG_MIN (- LONG_MAX - 1)
|
||||
#endif
|
||||
|
||||
#undef SUCCESS
|
||||
#undef FAILURE
|
||||
#define SUCCESS 0
|
||||
#define FAILURE -1 /* this MUST stay a negative number, or it may affect functions! */
|
||||
|
||||
|
||||
#include "zend_hash.h"
|
||||
#include "zend_ts_hash.h"
|
||||
#include "zend_llist.h"
|
||||
|
||||
#define INTERNAL_FUNCTION_PARAMETERS int ht, zval *return_value, zval *this_ptr, int return_value_used TSRMLS_DC
|
||||
#define INTERNAL_FUNCTION_PARAM_PASSTHRU ht, return_value, this_ptr, return_value_used TSRMLS_CC
|
||||
|
||||
|
||||
/*
|
||||
* zval
|
||||
*/
|
||||
typedef struct _zval_struct zval;
|
||||
typedef struct _zend_class_entry zend_class_entry;
|
||||
|
||||
typedef struct _zend_object {
|
||||
zend_class_entry *ce;
|
||||
HashTable *properties;
|
||||
unsigned int in_get:1;
|
||||
unsigned int in_set:1;
|
||||
} 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 */
|
||||
struct {
|
||||
char *val;
|
||||
int len;
|
||||
} str;
|
||||
HashTable *ht; /* hash table value */
|
||||
zend_object_value obj;
|
||||
} zvalue_value;
|
||||
|
||||
|
||||
struct _zval_struct {
|
||||
/* Variable information */
|
||||
zvalue_value value; /* value */
|
||||
zend_uint refcount;
|
||||
zend_uchar type; /* active type */
|
||||
zend_uchar is_ref;
|
||||
};
|
||||
|
||||
|
||||
/* excpt.h on Digital Unix 4.0 defines function_table */
|
||||
#undef function_table
|
||||
|
||||
/* A lot of stuff needs shifiting around in order to include zend_compile.h here */
|
||||
union _zend_function;
|
||||
|
||||
#define ZEND_CE_ABSTRACT ZEND_ACC_ABSTRACT /* same as ZEND_ACC_ABSTRACT */
|
||||
|
||||
#include "zend_iterators.h"
|
||||
|
||||
struct _zend_class_entry {
|
||||
char type;
|
||||
char *name;
|
||||
zend_uint name_length;
|
||||
struct _zend_class_entry *parent;
|
||||
int refcount;
|
||||
zend_bool constants_updated;
|
||||
zend_uint ce_flags;
|
||||
|
||||
HashTable function_table;
|
||||
HashTable default_properties;
|
||||
HashTable properties_info;
|
||||
HashTable *static_members;
|
||||
HashTable constants_table;
|
||||
struct _zend_function_entry *builtin_functions;
|
||||
|
||||
union _zend_function *constructor;
|
||||
union _zend_function *destructor;
|
||||
union _zend_function *clone;
|
||||
union _zend_function *__get;
|
||||
union _zend_function *__set;
|
||||
union _zend_function *__call;
|
||||
|
||||
zend_class_iterator_funcs iterator_funcs;
|
||||
|
||||
/* handlers */
|
||||
zend_object_value (*create_object)(zend_class_entry *class_type TSRMLS_DC);
|
||||
zend_object_iterator *(*get_iterator)(zend_class_entry *ce, zval *object TSRMLS_DC);
|
||||
int (*interface_gets_implemented)(zend_class_entry *iface, zend_class_entry *class_type TSRMLS_DC); /* a class implements this interface */
|
||||
|
||||
zend_class_entry **interfaces;
|
||||
zend_uint num_interfaces;
|
||||
|
||||
char *filename;
|
||||
zend_uint line_start;
|
||||
zend_uint line_end;
|
||||
char *doc_comment;
|
||||
zend_uint doc_comment_len;
|
||||
};
|
||||
|
||||
#include "zend_stream.h"
|
||||
typedef struct _zend_utility_functions {
|
||||
void (*error_function)(int type, const char *error_filename, const uint error_lineno, const char *format, va_list args) ZEND_ATTRIBUTE_PTR_FORMAT(printf, 4, 0);
|
||||
int (*printf_function)(const char *format, ...) ZEND_ATTRIBUTE_PTR_FORMAT(printf, 1, 2);
|
||||
int (*write_function)(const char *str, uint str_length);
|
||||
FILE *(*fopen_function)(const char *filename, char **opened_path);
|
||||
void (*message_handler)(long message, void *data);
|
||||
void (*block_interruptions)(void);
|
||||
void (*unblock_interruptions)(void);
|
||||
int (*get_configuration_directive)(char *name, uint name_length, zval *contents);
|
||||
void (*ticks_function)(int ticks);
|
||||
void (*on_timeout)(int seconds TSRMLS_DC);
|
||||
int (*stream_open_function)(const char *filename, zend_file_handle *handle TSRMLS_DC);
|
||||
int (*vspprintf_function)(char **pbuf, size_t max_len, const char *format, va_list ap);
|
||||
} zend_utility_functions;
|
||||
|
||||
|
||||
typedef struct _zend_utility_values {
|
||||
char *import_use_extension;
|
||||
uint import_use_extension_length;
|
||||
zend_bool html_errors;
|
||||
} zend_utility_values;
|
||||
|
||||
|
||||
typedef int (*zend_write_func_t)(const char *str, uint str_length);
|
||||
|
||||
|
||||
#undef MIN
|
||||
#undef MAX
|
||||
#define MAX(a, b) (((a)>(b))?(a):(b))
|
||||
#define MIN(a, b) (((a)<(b))?(a):(b))
|
||||
#define ZEND_STRL(str) (str), (sizeof(str)-1)
|
||||
#define ZEND_STRS(str) (str), (sizeof(str)-1)
|
||||
#define ZEND_NORMALIZE_BOOL(n) \
|
||||
((n) ? (((n)>0) ? 1 : -1) : 0)
|
||||
#define ZEND_TRUTH(x) ((x) ? 1 : 0)
|
||||
#define ZEND_LOG_XOR(a, b) (ZEND_TRUTH(a) ^ ZEND_TRUTH(b))
|
||||
|
||||
|
||||
|
||||
/* data types */
|
||||
#define IS_NULL 0
|
||||
#define IS_LONG 1
|
||||
#define IS_DOUBLE 2
|
||||
#define IS_STRING 3
|
||||
#define IS_ARRAY 4
|
||||
#define IS_OBJECT 5
|
||||
#define IS_BOOL 6
|
||||
#define IS_RESOURCE 7
|
||||
#define IS_CONSTANT 8
|
||||
#define IS_CONSTANT_ARRAY 9
|
||||
|
||||
/* Special data type to temporarily mark large numbers */
|
||||
#define FLAG_IS_BC 10 /* for parser internal use only */
|
||||
|
||||
/* Ugly hack to support constants as static array indices */
|
||||
#define IS_CONSTANT_INDEX 0x80
|
||||
|
||||
|
||||
/* overloaded elements data types */
|
||||
#define OE_IS_ARRAY (1<<0)
|
||||
#define OE_IS_OBJECT (1<<1)
|
||||
#define OE_IS_METHOD (1<<2)
|
||||
|
||||
|
||||
int zend_startup(zend_utility_functions *utility_functions, char **extensions, int start_builtin_functions);
|
||||
void zend_shutdown(TSRMLS_D);
|
||||
void zend_register_standard_ini_entries(TSRMLS_D);
|
||||
|
||||
#ifdef ZTS
|
||||
void zend_post_startup(TSRMLS_D);
|
||||
#endif
|
||||
|
||||
void zend_set_utility_values(zend_utility_values *utility_values);
|
||||
|
||||
BEGIN_EXTERN_C()
|
||||
ZEND_API void _zend_bailout(char *filename, uint lineno);
|
||||
END_EXTERN_C()
|
||||
|
||||
#define zend_bailout() _zend_bailout(__FILE__, __LINE__)
|
||||
|
||||
#define zend_try \
|
||||
{ \
|
||||
jmp_buf orig_bailout; \
|
||||
zend_bool orig_bailout_set=EG(bailout_set); \
|
||||
\
|
||||
EG(bailout_set) = 1; \
|
||||
memcpy(&orig_bailout, &EG(bailout), sizeof(jmp_buf)); \
|
||||
if (setjmp(EG(bailout))==0)
|
||||
#define zend_catch \
|
||||
else
|
||||
#define zend_end_try() \
|
||||
memcpy(&EG(bailout), &orig_bailout, sizeof(jmp_buf)); \
|
||||
EG(bailout_set) = orig_bailout_set; \
|
||||
}
|
||||
#define zend_first_try EG(bailout_set)=0; zend_try
|
||||
|
||||
ZEND_API char *get_zend_version(void);
|
||||
ZEND_API void zend_make_printable_zval(zval *expr, zval *expr_copy, int *use_copy);
|
||||
ZEND_API int zend_print_zval(zval *expr, int indent);
|
||||
ZEND_API int zend_print_zval_ex(zend_write_func_t write_func, zval *expr, int indent);
|
||||
ZEND_API void zend_print_zval_r(zval *expr, int indent TSRMLS_DC);
|
||||
ZEND_API void zend_print_flat_zval_r(zval *expr TSRMLS_DC);
|
||||
ZEND_API void zend_print_zval_r_ex(zend_write_func_t write_func, zval *expr, int indent TSRMLS_DC);
|
||||
ZEND_API void zend_output_debug_string(zend_bool trigger_break, char *format, ...) ZEND_ATTRIBUTE_FORMAT(printf, 2, 3);
|
||||
|
||||
void zend_activate(TSRMLS_D);
|
||||
void zend_deactivate(TSRMLS_D);
|
||||
void zend_activate_modules(TSRMLS_D);
|
||||
void zend_deactivate_modules(TSRMLS_D);
|
||||
void zend_exec_finished(TSRMLS_D);
|
||||
|
||||
#if ZEND_DEBUG
|
||||
#define Z_DBG(expr) (expr)
|
||||
#else
|
||||
#define Z_DBG(expr)
|
||||
#endif
|
||||
|
||||
ZEND_API extern char *empty_string;
|
||||
|
||||
ZEND_API void free_estring(char **str_p);
|
||||
|
||||
|
||||
#define STR_FREE(ptr) if (ptr && ptr!=empty_string) { efree(ptr); }
|
||||
#define STR_FREE_REL(ptr) if (ptr && ptr!=empty_string) { efree_rel(ptr); }
|
||||
|
||||
#define STR_REALLOC(ptr, size) \
|
||||
if (ptr!=empty_string) { \
|
||||
ptr = (char *) erealloc(ptr, size); \
|
||||
} else { \
|
||||
ptr = (char *) emalloc(size); \
|
||||
memset(ptr, 0, size); \
|
||||
}
|
||||
|
||||
/* output support */
|
||||
#define ZEND_WRITE(str, str_len) zend_write((str), (str_len))
|
||||
#define ZEND_PUTS(str) zend_write((str), strlen((str)))
|
||||
#define ZEND_PUTC(c) zend_write(&(c), 1), (c)
|
||||
|
||||
|
||||
BEGIN_EXTERN_C()
|
||||
extern ZEND_API int (*zend_printf)(const char *format, ...) ZEND_ATTRIBUTE_PTR_FORMAT(printf, 1, 2);
|
||||
extern ZEND_API zend_write_func_t zend_write;
|
||||
extern ZEND_API FILE *(*zend_fopen)(const char *filename, char **opened_path);
|
||||
extern ZEND_API void (*zend_block_interruptions)(void);
|
||||
extern ZEND_API void (*zend_unblock_interruptions)(void);
|
||||
extern ZEND_API void (*zend_ticks_function)(int ticks);
|
||||
extern ZEND_API void (*zend_error_cb)(int type, const char *error_filename, const uint error_lineno, const char *format, va_list args) ZEND_ATTRIBUTE_PTR_FORMAT(printf, 4, 0);
|
||||
extern void (*zend_on_timeout)(int seconds TSRMLS_DC);
|
||||
extern ZEND_API int (*zend_stream_open_function)(const char *filename, zend_file_handle *handle TSRMLS_DC);
|
||||
extern int (*zend_vspprintf)(char **pbuf, size_t max_len, const char *format, va_list ap);
|
||||
|
||||
|
||||
ZEND_API void zend_error(int type, const char *format, ...) ZEND_ATTRIBUTE_FORMAT(printf, 2, 3);
|
||||
|
||||
void zenderror(char *error);
|
||||
|
||||
/* The following #define is used for code duality in PHP for Engine 1 & 2 */
|
||||
#define ZEND_STANDARD_CLASS_DEF_PTR zend_standard_class_def
|
||||
extern ZEND_API zend_class_entry *zend_standard_class_def;
|
||||
extern ZEND_API zend_utility_values zend_uv;
|
||||
extern ZEND_API zval zval_used_for_init;
|
||||
|
||||
END_EXTERN_C()
|
||||
|
||||
#define ZEND_UV(name) (zend_uv.name)
|
||||
|
||||
|
||||
#define HANDLE_BLOCK_INTERRUPTIONS() if (zend_block_interruptions) { zend_block_interruptions(); }
|
||||
#define HANDLE_UNBLOCK_INTERRUPTIONS() if (zend_unblock_interruptions) { zend_unblock_interruptions(); }
|
||||
|
||||
BEGIN_EXTERN_C()
|
||||
ZEND_API void zend_message_dispatcher(long message, void *data);
|
||||
END_EXTERN_C()
|
||||
|
||||
ZEND_API int zend_get_configuration_directive(char *name, uint name_length, zval *contents);
|
||||
|
||||
|
||||
/* Messages for applications of Zend */
|
||||
#define ZMSG_FAILED_INCLUDE_FOPEN 1L
|
||||
#define ZMSG_FAILED_REQUIRE_FOPEN 2L
|
||||
#define ZMSG_FAILED_HIGHLIGHT_FOPEN 3L
|
||||
#define ZMSG_MEMORY_LEAK_DETECTED 4L
|
||||
#define ZMSG_MEMORY_LEAK_REPEATED 5L
|
||||
#define ZMSG_LOG_SCRIPT_NAME 6L
|
||||
#define ZMSG_MEMORY_LEAKS_GRAND_TOTAL 7L
|
||||
|
||||
|
||||
#define ZVAL_ADDREF(pz) (++(pz)->refcount)
|
||||
#define ZVAL_DELREF(pz) (--(pz)->refcount)
|
||||
#define ZVAL_REFCOUNT(pz) ((pz)->refcount)
|
||||
|
||||
#define INIT_PZVAL(z) \
|
||||
(z)->refcount = 1; \
|
||||
(z)->is_ref = 0;
|
||||
|
||||
#define INIT_ZVAL(z) z = zval_used_for_init;
|
||||
|
||||
#define ALLOC_INIT_ZVAL(zp) \
|
||||
ALLOC_ZVAL(zp); \
|
||||
INIT_ZVAL(*zp);
|
||||
|
||||
#define MAKE_STD_ZVAL(zv) \
|
||||
ALLOC_ZVAL(zv); \
|
||||
INIT_PZVAL(zv);
|
||||
|
||||
#define PZVAL_IS_REF(z) ((z)->is_ref)
|
||||
|
||||
#define SEPARATE_ZVAL(ppzv) \
|
||||
{ \
|
||||
zval *orig_ptr = *(ppzv); \
|
||||
\
|
||||
if (orig_ptr->refcount>1) { \
|
||||
orig_ptr->refcount--; \
|
||||
ALLOC_ZVAL(*(ppzv)); \
|
||||
**(ppzv) = *orig_ptr; \
|
||||
zval_copy_ctor(*(ppzv)); \
|
||||
(*(ppzv))->refcount=1; \
|
||||
(*(ppzv))->is_ref = 0; \
|
||||
} \
|
||||
}
|
||||
|
||||
#define SEPARATE_ZVAL_IF_NOT_REF(ppzv) \
|
||||
if (!PZVAL_IS_REF(*ppzv)) { \
|
||||
SEPARATE_ZVAL(ppzv); \
|
||||
}
|
||||
|
||||
#define SEPARATE_ZVAL_TO_MAKE_IS_REF(ppzv) \
|
||||
if (!PZVAL_IS_REF(*ppzv)) { \
|
||||
SEPARATE_ZVAL(ppzv); \
|
||||
(*(ppzv))->is_ref = 1; \
|
||||
}
|
||||
|
||||
#define COPY_PZVAL_TO_ZVAL(zv, pzv) \
|
||||
(zv) = *(pzv); \
|
||||
if ((pzv)->refcount>1) { \
|
||||
zval_copy_ctor(&(zv)); \
|
||||
(pzv)->refcount--; \
|
||||
} else { \
|
||||
FREE_ZVAL(pzv); \
|
||||
} \
|
||||
INIT_PZVAL(&(zv));
|
||||
|
||||
#define REPLACE_ZVAL_VALUE(ppzv_dest, pzv_src, copy) { \
|
||||
int is_ref, refcount; \
|
||||
\
|
||||
SEPARATE_ZVAL_IF_NOT_REF(ppzv_dest); \
|
||||
is_ref = (*ppzv_dest)->is_ref; \
|
||||
refcount = (*ppzv_dest)->refcount; \
|
||||
zval_dtor(*ppzv_dest); \
|
||||
**ppzv_dest = *pzv_src; \
|
||||
if (copy) { \
|
||||
zval_copy_ctor(*ppzv_dest); \
|
||||
} \
|
||||
(*ppzv_dest)->is_ref = is_ref; \
|
||||
(*ppzv_dest)->refcount = refcount; \
|
||||
}
|
||||
|
||||
#define ZEND_MAX_RESERVED_RESOURCES 4
|
||||
|
||||
|
||||
#endif /* ZEND_H */
|
||||
|
||||
/*
|
||||
* Local variables:
|
||||
* tab-width: 4
|
||||
* c-basic-offset: 4
|
||||
* indent-tabs-mode: t
|
||||
* End:
|
||||
*/
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 1.3 KiB |
-1917
File diff suppressed because it is too large.
Load diff
-534
@@ -1,534 +0,0 @@
|
||||
/*
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2003 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 |
|
||||
| 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 |
|
||||
| obtain it through the world-wide-web, please send a note to |
|
||||
| license@zend.com so we can mail you a copy immediately. |
|
||||
+----------------------------------------------------------------------+
|
||||
| Authors: Andi Gutmans <andi@zend.com> |
|
||||
| Zeev Suraski <zeev@zend.com> |
|
||||
| Andrei Zmievski <andrei@php.net> |
|
||||
+----------------------------------------------------------------------+
|
||||
*/
|
||||
|
||||
/* $Id$ */
|
||||
|
||||
#ifndef ZEND_API_H
|
||||
#define ZEND_API_H
|
||||
|
||||
#include "zend_modules.h"
|
||||
#include "zend_list.h"
|
||||
#include "zend_fast_cache.h"
|
||||
#include "zend_operators.h"
|
||||
#include "zend_variables.h"
|
||||
#include "zend_execute.h"
|
||||
|
||||
|
||||
BEGIN_EXTERN_C()
|
||||
|
||||
typedef struct _zend_function_entry {
|
||||
char *fname;
|
||||
void (*handler)(INTERNAL_FUNCTION_PARAMETERS);
|
||||
struct _zend_arg_info *arg_info;
|
||||
zend_uint num_args;
|
||||
zend_uint flags;
|
||||
} zend_function_entry;
|
||||
|
||||
#define ZEND_FN(name) zif_##name
|
||||
#define ZEND_NAMED_FUNCTION(name) void name(INTERNAL_FUNCTION_PARAMETERS)
|
||||
#define ZEND_FUNCTION(name) ZEND_NAMED_FUNCTION(ZEND_FN(name))
|
||||
#define ZEND_METHOD(classname, name) ZEND_NAMED_FUNCTION(ZEND_FN(classname##_##name))
|
||||
|
||||
#define ZEND_FENTRY(zend_name, name, arg_info, flags) { #zend_name, name, arg_info, (zend_uint) (sizeof(arg_info)/sizeof(struct _zend_arg_info)-1), flags },
|
||||
|
||||
#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_FALIAS(name, alias, arg_info) ZEND_FENTRY(name, ZEND_FN(alias), arg_info, 0)
|
||||
#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(name, classname, alias, arg_info, flags) \
|
||||
ZEND_FENTRY(name, ZEND_FN(classname##_##alias), arg_info, flags)
|
||||
|
||||
#define ZEND_ARG_INFO(pass_by_ref, name) { #name, sizeof(#name)-1, NULL, 0, 0, pass_by_ref },
|
||||
#define ZEND_ARG_PASS_INFO(pass_by_ref) { NULL, 0, NULL, 0, 0, pass_by_ref },
|
||||
#define ZEND_ARG_OBJ_INFO(pass_by_ref, name, classname, allow_null) { #name, sizeof(#name)-1, #classname, sizeof(#classname)-1, allow_null, pass_by_ref },
|
||||
#define ZEND_BEGIN_ARG_INFO(name, pass_rest_by_reference) \
|
||||
zend_arg_info name[] = { \
|
||||
ZEND_ARG_PASS_INFO(pass_rest_by_reference)
|
||||
#define ZEND_END_ARG_INFO() };
|
||||
|
||||
/* Name macros */
|
||||
#define ZEND_MODULE_STARTUP_N(module) zm_startup_##module
|
||||
#define ZEND_MODULE_SHUTDOWN_N(module) zm_shutdown_##module
|
||||
#define ZEND_MODULE_ACTIVATE_N(module) zm_activate_##module
|
||||
#define ZEND_MODULE_DEACTIVATE_N(module) zm_deactivate_##module
|
||||
#define ZEND_MODULE_EXEC_FINISHED_N(module) zm_exec_finished_##module
|
||||
#define ZEND_MODULE_INFO_N(module) zm_info_##module
|
||||
|
||||
/* Declaration macros */
|
||||
#define ZEND_MODULE_STARTUP_D(module) int ZEND_MODULE_STARTUP_N(module)(INIT_FUNC_ARGS)
|
||||
#define ZEND_MODULE_SHUTDOWN_D(module) int ZEND_MODULE_SHUTDOWN_N(module)(SHUTDOWN_FUNC_ARGS)
|
||||
#define ZEND_MODULE_ACTIVATE_D(module) int ZEND_MODULE_ACTIVATE_N(module)(INIT_FUNC_ARGS)
|
||||
#define ZEND_MODULE_DEACTIVATE_D(module) int ZEND_MODULE_DEACTIVATE_N(module)(SHUTDOWN_FUNC_ARGS)
|
||||
#define ZEND_MODULE_EXEC_FINISHED_D(module) int ZEND_MODULE_EXEC_FINISHED_N(module)(void)
|
||||
#define ZEND_MODULE_INFO_D(module) void ZEND_MODULE_INFO_N(module)(ZEND_MODULE_INFO_FUNC_ARGS)
|
||||
|
||||
#define ZEND_GET_MODULE(name) \
|
||||
BEGIN_EXTERN_C()\
|
||||
ZEND_DLEXPORT zend_module_entry *get_module(void) { return &name##_module_entry; }\
|
||||
END_EXTERN_C()
|
||||
|
||||
#define ZEND_BEGIN_MODULE_GLOBALS(module_name) \
|
||||
typedef struct _zend_##module_name##_globals {
|
||||
#define ZEND_END_MODULE_GLOBALS(module_name) \
|
||||
} zend_##module_name##_globals;
|
||||
|
||||
#ifdef ZTS
|
||||
|
||||
#define ZEND_DECLARE_MODULE_GLOBALS(module_name) \
|
||||
ts_rsrc_id module_name##_globals_id;
|
||||
#define ZEND_EXTERN_MODULE_GLOBALS(module_name) \
|
||||
extern ts_rsrc_id module_name##_globals_id;
|
||||
#define ZEND_INIT_MODULE_GLOBALS(module_name, globals_ctor, globals_dtor) \
|
||||
ts_allocate_id(&module_name##_globals_id, sizeof(zend_##module_name##_globals), (ts_allocate_ctor) globals_ctor, (ts_allocate_dtor) globals_dtor);
|
||||
|
||||
#else
|
||||
|
||||
#define ZEND_DECLARE_MODULE_GLOBALS(module_name) \
|
||||
zend_##module_name##_globals module_name##_globals;
|
||||
#define ZEND_EXTERN_MODULE_GLOBALS(module_name) \
|
||||
extern zend_##module_name##_globals module_name##_globals;
|
||||
#define ZEND_INIT_MODULE_GLOBALS(module_name, globals_ctor, globals_dtor) \
|
||||
globals_ctor(&module_name##_globals);
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
|
||||
#define INIT_CLASS_ENTRY(class_container, class_name, functions) INIT_OVERLOADED_CLASS_ENTRY(class_container, class_name, functions, NULL, NULL, NULL)
|
||||
|
||||
#define INIT_OVERLOADED_CLASS_ENTRY(class_container, class_name, functions, handle_fcall, handle_propget, handle_propset) \
|
||||
{ \
|
||||
class_container.name = strdup(class_name); \
|
||||
class_container.name_length = sizeof(class_name) - 1; \
|
||||
class_container.builtin_functions = functions; \
|
||||
class_container.constructor = NULL; \
|
||||
class_container.destructor = NULL; \
|
||||
class_container.clone = NULL; \
|
||||
class_container.create_object = NULL; \
|
||||
class_container.interface_gets_implemented = NULL; \
|
||||
class_container.__call = handle_fcall; \
|
||||
class_container.__get = handle_propget; \
|
||||
class_container.__set = handle_propset; \
|
||||
class_container.num_interfaces = 0; \
|
||||
class_container.get_iterator = NULL; \
|
||||
class_container.iterator_funcs.funcs = NULL; \
|
||||
}
|
||||
|
||||
int zend_next_free_module(void);
|
||||
|
||||
ZEND_API int zend_get_parameters(int ht, int param_count, ...);
|
||||
ZEND_API int _zend_get_parameters_array(int ht, int param_count, zval **argument_array TSRMLS_DC);
|
||||
ZEND_API int zend_get_parameters_ex(int param_count, ...);
|
||||
ZEND_API int _zend_get_parameters_array_ex(int param_count, zval ***argument_array TSRMLS_DC);
|
||||
|
||||
#define zend_get_parameters_array(ht, param_count, argument_array) \
|
||||
_zend_get_parameters_array(ht, param_count, argument_array TSRMLS_CC)
|
||||
#define zend_get_parameters_array_ex(param_count, argument_array) \
|
||||
_zend_get_parameters_array_ex(param_count, argument_array TSRMLS_CC)
|
||||
|
||||
|
||||
/* Parameter parsing API -- andrei */
|
||||
|
||||
#define ZEND_PARSE_PARAMS_QUIET 1<<1
|
||||
ZEND_API int zend_parse_parameters(int num_args TSRMLS_DC, char *type_spec, ...);
|
||||
ZEND_API int zend_parse_parameters_ex(int flags, int num_args TSRMLS_DC, char *type_spec, ...);
|
||||
ZEND_API char *zend_zval_type_name(zval *arg);
|
||||
|
||||
ZEND_API int zend_parse_method_parameters(int num_args TSRMLS_DC, zval *this_ptr, char *type_spec, ...);
|
||||
ZEND_API int zend_parse_method_parameters_ex(int flags, int num_args TSRMLS_DC, zval *this_ptr, char *type_spec, zend_class_entry *ce, void **object, ...);
|
||||
|
||||
/* End of parameter parsing API -- andrei */
|
||||
|
||||
int zend_register_functions(zend_class_entry *scope, zend_function_entry *functions, HashTable *function_table, int type TSRMLS_DC);
|
||||
void zend_unregister_functions(zend_function_entry *functions, int count, HashTable *function_table TSRMLS_DC);
|
||||
ZEND_API int zend_register_module(zend_module_entry *module_entry);
|
||||
|
||||
ZEND_API zend_class_entry *zend_register_internal_class(zend_class_entry *class_entry TSRMLS_DC);
|
||||
ZEND_API zend_class_entry *zend_register_internal_class_ex(zend_class_entry *class_entry, zend_class_entry *parent_ce, char *parent_name TSRMLS_DC);
|
||||
ZEND_API zend_class_entry *zend_register_internal_interface(zend_class_entry *orig_class_entry TSRMLS_DC);
|
||||
ZEND_API void zend_class_implements(zend_class_entry *class_entry TSRMLS_DC, int num_interfaces, ...);
|
||||
|
||||
ZEND_API int zend_disable_function(char *function_name, uint function_name_length TSRMLS_DC);
|
||||
ZEND_API int zend_disable_class(char *class_name, uint class_name_length TSRMLS_DC);
|
||||
|
||||
ZEND_API void zend_wrong_param_count(TSRMLS_D);
|
||||
ZEND_API zend_bool zend_is_callable(zval *callable, zend_bool syntax_only, char **callable_name);
|
||||
ZEND_API zend_bool zend_make_callable(zval *callable, char **callable_name TSRMLS_DC);
|
||||
ZEND_API char *zend_get_module_version(char *module_name);
|
||||
ZEND_API int zend_declare_property(zend_class_entry *ce, char *name, int name_length, zval *property, int access_type TSRMLS_DC);
|
||||
ZEND_API int zend_declare_property_null(zend_class_entry *ce, char *name, int name_length, int access_type TSRMLS_DC);
|
||||
ZEND_API int zend_declare_property_long(zend_class_entry *ce, char *name, int name_length, long value, int access_type TSRMLS_DC);
|
||||
ZEND_API int zend_declare_property_string(zend_class_entry *ce, char *name, int name_length, char *value, int access_type TSRMLS_DC);
|
||||
|
||||
ZEND_API void zend_update_property(zend_class_entry *scope, zval *object, char *name, int name_length, zval *value TSRMLS_DC);
|
||||
ZEND_API void zend_update_property_null(zend_class_entry *scope, zval *object, char *name, int name_length TSRMLS_DC);
|
||||
ZEND_API void zend_update_property_long(zend_class_entry *scope, zval *object, char *name, int name_length, long value TSRMLS_DC);
|
||||
ZEND_API void zend_update_property_string(zend_class_entry *scope, zval *object, char *name, int name_length, char *value TSRMLS_DC);
|
||||
|
||||
ZEND_API zval *zend_read_property(zend_class_entry *scope, zval *object, char *name, int name_length, zend_bool silent TSRMLS_DC);
|
||||
|
||||
ZEND_API zend_class_entry *zend_get_class_entry(zval *zobject TSRMLS_DC);
|
||||
|
||||
#define getThis() (this_ptr)
|
||||
|
||||
#define WRONG_PARAM_COUNT ZEND_WRONG_PARAM_COUNT()
|
||||
#define WRONG_PARAM_COUNT_WITH_RETVAL(ret) ZEND_WRONG_PARAM_COUNT_WITH_RETVAL(ret)
|
||||
#define ARG_COUNT(dummy) (ht)
|
||||
#define ZEND_NUM_ARGS() (ht)
|
||||
#define ZEND_WRONG_PARAM_COUNT() { zend_wrong_param_count(TSRMLS_C); return; }
|
||||
#define ZEND_WRONG_PARAM_COUNT_WITH_RETVAL(ret) { zend_wrong_param_count(TSRMLS_C); return ret; }
|
||||
|
||||
#ifndef ZEND_WIN32
|
||||
#define DLEXPORT
|
||||
#endif
|
||||
|
||||
ZEND_API int zend_startup_module(zend_module_entry *module);
|
||||
|
||||
#define array_init(arg) _array_init((arg) ZEND_FILE_LINE_CC)
|
||||
#define object_init(arg) _object_init((arg) ZEND_FILE_LINE_CC TSRMLS_CC)
|
||||
#define object_init_ex(arg, ce) _object_init_ex((arg), (ce) ZEND_FILE_LINE_CC TSRMLS_CC)
|
||||
#define object_and_properties_init(arg, ce, properties) _object_and_properties_init((arg), (ce), (properties) ZEND_FILE_LINE_CC TSRMLS_CC)
|
||||
ZEND_API int _array_init(zval *arg ZEND_FILE_LINE_DC);
|
||||
ZEND_API int _object_init(zval *arg ZEND_FILE_LINE_DC TSRMLS_DC);
|
||||
ZEND_API int _object_init_ex(zval *arg, zend_class_entry *ce ZEND_FILE_LINE_DC TSRMLS_DC);
|
||||
ZEND_API int _object_and_properties_init(zval *arg, zend_class_entry *ce, HashTable *properties ZEND_FILE_LINE_DC TSRMLS_DC);
|
||||
|
||||
ZEND_API void zend_merge_properties(zval *obj, HashTable *properties, int destroy_ht TSRMLS_DC);
|
||||
|
||||
/* no longer supported */
|
||||
ZEND_API int add_assoc_function(zval *arg, char *key, void (*function_ptr)(INTERNAL_FUNCTION_PARAMETERS));
|
||||
|
||||
ZEND_API int add_assoc_long_ex(zval *arg, char *key, uint key_len, long n);
|
||||
ZEND_API int add_assoc_null_ex(zval *arg, char *key, uint key_len);
|
||||
ZEND_API int add_assoc_bool_ex(zval *arg, char *key, uint key_len, int b);
|
||||
ZEND_API int add_assoc_resource_ex(zval *arg, char *key, uint key_len, int r);
|
||||
ZEND_API int add_assoc_double_ex(zval *arg, char *key, uint key_len, double d);
|
||||
ZEND_API int add_assoc_string_ex(zval *arg, char *key, uint key_len, char *str, int duplicate);
|
||||
ZEND_API int add_assoc_stringl_ex(zval *arg, char *key, uint key_len, char *str, uint length, int duplicate);
|
||||
ZEND_API int add_assoc_zval_ex(zval *arg, char *key, uint key_len, zval *value);
|
||||
|
||||
#define add_assoc_long(__arg, __key, __n) add_assoc_long_ex(__arg, __key, strlen(__key)+1, __n)
|
||||
#define add_assoc_null(__arg, __key) add_assoc_null_ex(__arg, __key, strlen(__key) + 1)
|
||||
#define add_assoc_bool(__arg, __key, __b) add_assoc_bool_ex(__arg, __key, strlen(__key)+1, __b)
|
||||
#define add_assoc_resource(__arg, __key, __r) add_assoc_resource_ex(__arg, __key, strlen(__key)+1, __r)
|
||||
#define add_assoc_double(__arg, __key, __d) add_assoc_double_ex(__arg, __key, strlen(__key)+1, __d)
|
||||
#define add_assoc_string(__arg, __key, __str, __duplicate) add_assoc_string_ex(__arg, __key, strlen(__key)+1, __str, __duplicate)
|
||||
#define add_assoc_stringl(__arg, __key, __str, __length, __duplicate) add_assoc_stringl_ex(__arg, __key, strlen(__key)+1, __str, __length, __duplicate)
|
||||
#define add_assoc_zval(__arg, __key, __value) add_assoc_zval_ex(__arg, __key, strlen(__key)+1, __value)
|
||||
|
||||
/* unset() functions are only suported for legacy modules and null() functions should be used */
|
||||
#define add_assoc_unset(__arg, __key) add_assoc_null_ex(__arg, __key, strlen(__key) + 1)
|
||||
#define add_index_unset(__arg, __key) add_index_null(__arg, __key)
|
||||
#define add_next_index_unset(__arg) add_next_index_null(__arg)
|
||||
#define add_property_unset(__arg, __key) add_property_null(__arg, __key)
|
||||
|
||||
ZEND_API int add_index_long(zval *arg, uint idx, long n);
|
||||
ZEND_API int add_index_null(zval *arg, uint idx);
|
||||
ZEND_API int add_index_bool(zval *arg, uint idx, int b);
|
||||
ZEND_API int add_index_resource(zval *arg, uint idx, int r);
|
||||
ZEND_API int add_index_double(zval *arg, uint idx, double d);
|
||||
ZEND_API int add_index_string(zval *arg, uint idx, char *str, int duplicate);
|
||||
ZEND_API int add_index_stringl(zval *arg, uint idx, char *str, uint length, int duplicate);
|
||||
ZEND_API int add_index_zval(zval *arg, uint index, zval *value);
|
||||
|
||||
ZEND_API int add_next_index_long(zval *arg, long n);
|
||||
ZEND_API int add_next_index_null(zval *arg);
|
||||
ZEND_API int add_next_index_bool(zval *arg, int b);
|
||||
ZEND_API int add_next_index_resource(zval *arg, int r);
|
||||
ZEND_API int add_next_index_double(zval *arg, double d);
|
||||
ZEND_API int add_next_index_string(zval *arg, char *str, int duplicate);
|
||||
ZEND_API int add_next_index_stringl(zval *arg, char *str, uint length, int duplicate);
|
||||
ZEND_API int add_next_index_zval(zval *arg, zval *value);
|
||||
|
||||
ZEND_API int add_get_assoc_string_ex(zval *arg, char *key, uint key_len, char *str, void **dest, int duplicate);
|
||||
ZEND_API int add_get_assoc_stringl_ex(zval *arg, char *key, uint key_len, char *str, uint length, void **dest, int duplicate);
|
||||
|
||||
#define add_get_assoc_string(__arg, __key, __str, __dest, __duplicate) add_get_assoc_string_ex(__arg, __key, strlen(__key)+1, __str, __dest, __duplicate)
|
||||
#define add_get_assoc_stringl(__arg, __key, __str, __length, __dest, __duplicate) add_get_assoc_stringl_ex(__arg, __key, strlen(__key)+1, __str, __length, __dest, __duplicate)
|
||||
|
||||
ZEND_API int add_get_index_long(zval *arg, uint idx, long l, void **dest);
|
||||
ZEND_API int add_get_index_double(zval *arg, uint idx, double d, void **dest);
|
||||
ZEND_API int add_get_index_string(zval *arg, uint idx, char *str, void **dest, int duplicate);
|
||||
ZEND_API int add_get_index_stringl(zval *arg, uint idx, char *str, uint length, void **dest, int duplicate);
|
||||
|
||||
ZEND_API int add_property_long_ex(zval *arg, char *key, uint key_len, long l TSRMLS_DC);
|
||||
ZEND_API int add_property_null_ex(zval *arg, char *key, uint key_len TSRMLS_DC);
|
||||
ZEND_API int add_property_bool_ex(zval *arg, char *key, uint key_len, int b TSRMLS_DC);
|
||||
ZEND_API int add_property_resource_ex(zval *arg, char *key, uint key_len, long r TSRMLS_DC);
|
||||
ZEND_API int add_property_double_ex(zval *arg, char *key, uint key_len, double d TSRMLS_DC);
|
||||
ZEND_API int add_property_string_ex(zval *arg, char *key, uint key_len, char *str, int duplicate TSRMLS_DC);
|
||||
ZEND_API int add_property_stringl_ex(zval *arg, char *key, uint key_len, char *str, uint length, int duplicate TSRMLS_DC);
|
||||
ZEND_API int add_property_zval_ex(zval *arg, char *key, uint key_len, zval *value TSRMLS_DC);
|
||||
|
||||
#define add_property_long(__arg, __key, __n) add_property_long_ex(__arg, __key, strlen(__key)+1, __n TSRMLS_CC)
|
||||
#define add_property_null(__arg, __key) add_property_null_ex(__arg, __key, strlen(__key) + 1 TSRMLS_CC)
|
||||
#define add_property_bool(__arg, __key, __b) add_property_bool_ex(__arg, __key, strlen(__key)+1, __b TSRMLS_CC)
|
||||
#define add_property_resource(__arg, __key, __r) add_property_resource_ex(__arg, __key, strlen(__key)+1, __r TSRMLS_CC)
|
||||
#define add_property_double(__arg, __key, __d) add_property_double_ex(__arg, __key, strlen(__key)+1, __d TSRMLS_CC)
|
||||
#define add_property_string(__arg, __key, __str, __duplicate) add_property_string_ex(__arg, __key, strlen(__key)+1, __str, __duplicate TSRMLS_CC)
|
||||
#define add_property_stringl(__arg, __key, __str, __length, __duplicate) add_property_stringl_ex(__arg, __key, strlen(__key)+1, __str, __length, __duplicate TSRMLS_CC)
|
||||
#define add_property_zval(__arg, __key, __value) add_property_zval_ex(__arg, __key, strlen(__key)+1, __value TSRMLS_CC)
|
||||
|
||||
|
||||
ZEND_API int call_user_function(HashTable *function_table, zval **object_pp, zval *function_name, zval *retval_ptr, zend_uint param_count, zval *params[] TSRMLS_DC);
|
||||
ZEND_API int call_user_function_ex(HashTable *function_table, zval **object_pp, zval *function_name, zval **retval_ptr_ptr, zend_uint param_count, zval **params[], int no_separation, HashTable *symbol_table TSRMLS_DC);
|
||||
|
||||
typedef struct _zend_fcall_info {
|
||||
size_t size;
|
||||
HashTable *function_table;
|
||||
zval *function_name;
|
||||
HashTable *symbol_table;
|
||||
zval **retval_ptr_ptr;
|
||||
zend_uint param_count;
|
||||
zval ***params;
|
||||
zval **object_pp;
|
||||
zend_bool no_separation;
|
||||
} zend_fcall_info;
|
||||
|
||||
typedef struct _zend_fcall_info_cache {
|
||||
zend_bool initialized;
|
||||
zend_function *function_handler;
|
||||
zend_class_entry *calling_scope;
|
||||
zval **object_pp;
|
||||
} zend_fcall_info_cache;
|
||||
|
||||
ZEND_API extern zend_fcall_info_cache empty_fcall_info_cache;
|
||||
|
||||
ZEND_API int zend_call_function(zend_fcall_info *fci, zend_fcall_info_cache *fci_cache TSRMLS_DC);
|
||||
|
||||
|
||||
ZEND_API int zend_set_hash_symbol(zval *symbol, char *name, int name_length,
|
||||
zend_bool is_ref, int num_symbol_tables, ...);
|
||||
|
||||
#define add_method(arg, key, method) add_assoc_function((arg), (key), (method))
|
||||
|
||||
ZEND_API ZEND_FUNCTION(display_disabled_function);
|
||||
ZEND_API ZEND_FUNCTION(display_disabled_class);
|
||||
|
||||
#if ZEND_DEBUG
|
||||
#define CHECK_ZVAL_STRING(z) \
|
||||
if ((z)->value.str.val[ (z)->value.str.len ] != '\0') { zend_error(E_WARNING, "String is not zero-terminated (%s)", (z)->value.str.val); }
|
||||
#define CHECK_ZVAL_STRING_REL(z) \
|
||||
if ((z)->value.str.val[ (z)->value.str.len ] != '\0') { zend_error(E_WARNING, "String is not zero-terminated (%s) (source: %s:%d)", (z)->value.str.val ZEND_FILE_LINE_RELAY_CC); }
|
||||
#else
|
||||
#define CHECK_ZVAL_STRING(z)
|
||||
#define CHECK_ZVAL_STRING_REL(z)
|
||||
#endif
|
||||
|
||||
#define ZVAL_RESOURCE(z, l) { \
|
||||
(z)->type = IS_RESOURCE; \
|
||||
(z)->value.lval = l; \
|
||||
}
|
||||
|
||||
#define ZVAL_BOOL(z, b) { \
|
||||
(z)->type = IS_BOOL; \
|
||||
(z)->value.lval = ((b) != 0); \
|
||||
}
|
||||
|
||||
#define ZVAL_NULL(z) { \
|
||||
(z)->type = IS_NULL; \
|
||||
}
|
||||
|
||||
#define ZVAL_LONG(z, l) { \
|
||||
(z)->type = IS_LONG; \
|
||||
(z)->value.lval = l; \
|
||||
}
|
||||
|
||||
#define ZVAL_DOUBLE(z, d) { \
|
||||
(z)->type = IS_DOUBLE; \
|
||||
(z)->value.dval = d; \
|
||||
}
|
||||
|
||||
#define ZVAL_STRING(z, s, duplicate) { \
|
||||
char *__s=(s); \
|
||||
(z)->value.str.len = strlen(__s); \
|
||||
(z)->value.str.val = (duplicate?estrndup(__s, (z)->value.str.len):__s); \
|
||||
(z)->type = IS_STRING; \
|
||||
}
|
||||
|
||||
#define ZVAL_STRINGL(z, s, l, duplicate) { \
|
||||
char *__s=(s); int __l=l; \
|
||||
(z)->value.str.len = __l; \
|
||||
(z)->value.str.val = (duplicate?estrndup(__s, __l):__s); \
|
||||
(z)->type = IS_STRING; \
|
||||
}
|
||||
|
||||
#define ZVAL_EMPTY_STRING(z) { \
|
||||
(z)->value.str.len = 0; \
|
||||
(z)->value.str.val = empty_string; \
|
||||
(z)->type = IS_STRING; \
|
||||
}
|
||||
|
||||
#define ZVAL_ZVAL(z, zv, copy, dtor) { \
|
||||
int is_ref, refcount; \
|
||||
is_ref = (z)->is_ref; \
|
||||
refcount = (z)->refcount; \
|
||||
*(z) = *(zv); \
|
||||
if (copy) { \
|
||||
zval_copy_ctor(z); \
|
||||
} \
|
||||
if (dtor) { \
|
||||
if (!copy) { \
|
||||
ZVAL_NULL(zv); \
|
||||
} \
|
||||
zval_ptr_dtor(&zv); \
|
||||
} \
|
||||
(z)->is_ref = is_ref; \
|
||||
(z)->refcount = refcount; \
|
||||
}
|
||||
|
||||
#define ZVAL_FALSE(z) ZVAL_BOOL(z, 0)
|
||||
#define ZVAL_TRUE(z) ZVAL_BOOL(z, 1)
|
||||
|
||||
#define RETVAL_RESOURCE(l) ZVAL_RESOURCE(return_value, l)
|
||||
#define RETVAL_BOOL(b) ZVAL_BOOL(return_value, b)
|
||||
#define RETVAL_NULL() ZVAL_NULL(return_value)
|
||||
#define RETVAL_LONG(l) ZVAL_LONG(return_value, l)
|
||||
#define RETVAL_DOUBLE(d) ZVAL_DOUBLE(return_value, d)
|
||||
#define RETVAL_STRING(s, duplicate) ZVAL_STRING(return_value, s, duplicate)
|
||||
#define RETVAL_STRINGL(s, l, duplicate) ZVAL_STRINGL(return_value, s, l, duplicate)
|
||||
#define RETVAL_EMPTY_STRING() ZVAL_EMPTY_STRING(return_value)
|
||||
#define RETVAL_ZVAL(zv, copy, dtor) ZVAL_ZVAL(return_value, zv, copy, dtor)
|
||||
#define RETVAL_FALSE ZVAL_BOOL(return_value, 0)
|
||||
#define RETVAL_TRUE ZVAL_BOOL(return_value, 1)
|
||||
|
||||
#define RETURN_RESOURCE(l) { RETVAL_RESOURCE(l); return; }
|
||||
#define RETURN_BOOL(b) { RETVAL_BOOL(b); return; }
|
||||
#define RETURN_NULL() { RETVAL_NULL(); return;}
|
||||
#define RETURN_LONG(l) { RETVAL_LONG(l); return; }
|
||||
#define RETURN_DOUBLE(d) { RETVAL_DOUBLE(d); return; }
|
||||
#define RETURN_STRING(s, duplicate) { RETVAL_STRING(s, duplicate); return; }
|
||||
#define RETURN_STRINGL(s, l, duplicate) { RETVAL_STRINGL(s, l, duplicate); return; }
|
||||
#define RETURN_EMPTY_STRING() { RETVAL_EMPTY_STRING(); return; }
|
||||
#define RETURN_ZVAL(zv, copy, dtor) { RETVAL_ZVAL(zv, copy, dtor); return; }
|
||||
#define RETURN_FALSE { RETVAL_FALSE; return; }
|
||||
#define RETURN_TRUE { RETVAL_TRUE; return; }
|
||||
|
||||
#define SET_VAR_STRING(n, v) { \
|
||||
{ \
|
||||
zval *var; \
|
||||
ALLOC_ZVAL(var); \
|
||||
ZVAL_STRING(var, v, 0); \
|
||||
ZEND_SET_GLOBAL_VAR(n, var); \
|
||||
} \
|
||||
}
|
||||
|
||||
#define SET_VAR_STRINGL(n, v, l) { \
|
||||
{ \
|
||||
zval *var; \
|
||||
ALLOC_ZVAL(var); \
|
||||
ZVAL_STRINGL(var, v, l, 0); \
|
||||
ZEND_SET_GLOBAL_VAR(n, var); \
|
||||
} \
|
||||
}
|
||||
|
||||
#define SET_VAR_LONG(n, v) { \
|
||||
{ \
|
||||
zval *var; \
|
||||
ALLOC_ZVAL(var); \
|
||||
ZVAL_LONG(var, v); \
|
||||
ZEND_SET_GLOBAL_VAR(n, var); \
|
||||
} \
|
||||
}
|
||||
|
||||
#define SET_VAR_DOUBLE(n, v) { \
|
||||
{ \
|
||||
zval *var; \
|
||||
ALLOC_ZVAL(var); \
|
||||
ZVAL_DOUBLE(var, v); \
|
||||
ZEND_SET_GLOBAL_VAR(n, var); \
|
||||
} \
|
||||
}
|
||||
|
||||
|
||||
#define ZEND_SET_SYMBOL(symtable, name, var) \
|
||||
{ \
|
||||
char *_name = (name); \
|
||||
\
|
||||
ZEND_SET_SYMBOL_WITH_LENGTH(symtable, _name, strlen(_name)+1, var, 1, 0); \
|
||||
}
|
||||
|
||||
#define ZEND_SET_SYMBOL_WITH_LENGTH(symtable, name, name_length, var, _refcount, _is_ref) \
|
||||
{ \
|
||||
zval **orig_var; \
|
||||
\
|
||||
if (zend_hash_find(symtable, (name), (name_length), (void **) &orig_var)==SUCCESS \
|
||||
&& PZVAL_IS_REF(*orig_var)) { \
|
||||
(var)->refcount = (*orig_var)->refcount; \
|
||||
(var)->is_ref = 1; \
|
||||
\
|
||||
if (_refcount) { \
|
||||
(var)->refcount += _refcount-1; \
|
||||
} \
|
||||
zval_dtor(*orig_var); \
|
||||
**orig_var = *(var); \
|
||||
FREE_ZVAL(var); \
|
||||
} else { \
|
||||
(var)->is_ref = _is_ref; \
|
||||
if (_refcount) { \
|
||||
(var)->refcount = _refcount; \
|
||||
} \
|
||||
zend_hash_update(symtable, (name), (name_length), &(var), sizeof(zval *), NULL); \
|
||||
} \
|
||||
}
|
||||
|
||||
|
||||
#define ZEND_SET_GLOBAL_VAR(name, var) \
|
||||
ZEND_SET_SYMBOL(&EG(symbol_table), name, var)
|
||||
|
||||
#define ZEND_SET_GLOBAL_VAR_WITH_LENGTH(name, name_length, var, _refcount, _is_ref) \
|
||||
ZEND_SET_SYMBOL_WITH_LENGTH(&EG(symbol_table), name, name_length, var, _refcount, _is_ref)
|
||||
|
||||
#define ZEND_DEFINE_PROPERTY(class_ptr, name, value, mask) \
|
||||
{ \
|
||||
char *_name = (name); \
|
||||
int namelen = strlen(_name); \
|
||||
zend_declare_property(class_ptr, _name, namelen, value, mask TSRMLS_CC); \
|
||||
}
|
||||
|
||||
#define HASH_OF(p) ((p)->type==IS_ARRAY ? (p)->value.ht : (((p)->type==IS_OBJECT ? Z_OBJ_HT_P(p)->get_properties((p) TSRMLS_CC) : NULL)))
|
||||
#define ZVAL_IS_NULL(z) ((z)->type==IS_NULL)
|
||||
|
||||
/* For compatibility */
|
||||
#define ZEND_MINIT ZEND_MODULE_STARTUP_N
|
||||
#define ZEND_MSHUTDOWN ZEND_MODULE_SHUTDOWN_N
|
||||
#define ZEND_RINIT ZEND_MODULE_ACTIVATE_N
|
||||
#define ZEND_RSHUTDOWN ZEND_MODULE_DEACTIVATE_N
|
||||
#define ZEND_MINFO ZEND_MODULE_INFO_N
|
||||
|
||||
#define ZEND_MINIT_FUNCTION ZEND_MODULE_STARTUP_D
|
||||
#define ZEND_MSHUTDOWN_FUNCTION ZEND_MODULE_SHUTDOWN_D
|
||||
#define ZEND_RINIT_FUNCTION ZEND_MODULE_ACTIVATE_D
|
||||
#define ZEND_RSHUTDOWN_FUNCTION ZEND_MODULE_DEACTIVATE_D
|
||||
#define ZEND_MINFO_FUNCTION ZEND_MODULE_INFO_D
|
||||
|
||||
END_EXTERN_C()
|
||||
|
||||
#endif /* ZEND_API_H */
|
||||
|
||||
|
||||
/*
|
||||
* Local variables:
|
||||
* tab-width: 4
|
||||
* c-basic-offset: 4
|
||||
* indent-tabs-mode: t
|
||||
* End:
|
||||
*/
|
||||
@@ -1,793 +0,0 @@
|
||||
/*
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2003 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 |
|
||||
| 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 |
|
||||
| obtain it through the world-wide-web, please send a note to |
|
||||
| license@zend.com so we can mail you a copy immediately. |
|
||||
+----------------------------------------------------------------------+
|
||||
| Authors: Andi Gutmans <andi@zend.com> |
|
||||
| Zeev Suraski <zeev@zend.com> |
|
||||
+----------------------------------------------------------------------+
|
||||
*/
|
||||
|
||||
/* $Id$ */
|
||||
|
||||
#include "zend.h"
|
||||
#include "zend_alloc.h"
|
||||
#include "zend_globals.h"
|
||||
#include "zend_fast_cache.h"
|
||||
#ifdef HAVE_SIGNAL_H
|
||||
# include <signal.h>
|
||||
#endif
|
||||
#ifdef HAVE_UNISTD_H
|
||||
# include <unistd.h>
|
||||
#endif
|
||||
|
||||
#include "zend_mm.h"
|
||||
|
||||
#ifndef ZTS
|
||||
ZEND_API zend_alloc_globals alloc_globals;
|
||||
#endif
|
||||
|
||||
|
||||
#ifdef ZEND_MM
|
||||
#define ZEND_DISABLE_MEMORY_CACHE 0
|
||||
#else
|
||||
#define ZEND_DISABLE_MEMORY_CACHE 0
|
||||
#endif
|
||||
|
||||
#ifdef ZEND_MM
|
||||
#define ZEND_DO_MALLOC(size) zend_mm_alloc(&AG(mm_heap), size)
|
||||
#define ZEND_DO_FREE(ptr) zend_mm_free(&AG(mm_heap), ptr)
|
||||
#define ZEND_DO_REALLOC(ptr, size) zend_mm_realloc(&AG(mm_heap), ptr, size)
|
||||
#elif defined(ZEND_WIN32)
|
||||
#define ZEND_DO_MALLOC(size) (AG(memory_heap) ? HeapAlloc(AG(memory_heap), HEAP_NO_SERIALIZE, size) : malloc(size))
|
||||
#define ZEND_DO_FREE(ptr) (AG(memory_heap) ? HeapFree(AG(memory_heap), HEAP_NO_SERIALIZE, ptr) : free(ptr))
|
||||
#define ZEND_DO_REALLOC(ptr, size) (AG(memory_heap) ? HeapReAlloc(AG(memory_heap), HEAP_NO_SERIALIZE, ptr, size) : realloc(ptr, size))
|
||||
#else
|
||||
#define ZEND_DO_MALLOC(size) malloc(size)
|
||||
#define ZEND_DO_FREE(ptr) free(ptr)
|
||||
#define ZEND_DO_REALLOC(ptr, size) realloc(ptr, size)
|
||||
#endif
|
||||
|
||||
#if ZEND_DEBUG
|
||||
# define END_MAGIC_SIZE sizeof(long)
|
||||
static long mem_block_end_magic = MEM_BLOCK_END_MAGIC;
|
||||
#else
|
||||
# define END_MAGIC_SIZE 0
|
||||
#endif
|
||||
|
||||
|
||||
# if MEMORY_LIMIT
|
||||
# if ZEND_DEBUG
|
||||
#define CHECK_MEMORY_LIMIT(s, rs) _CHECK_MEMORY_LIMIT(s, rs, __zend_filename, __zend_lineno)
|
||||
# else
|
||||
#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;\
|
||||
if (AG(memory_limit)<AG(allocated_memory)) {\
|
||||
int php_mem_limit = AG(memory_limit); \
|
||||
if (AG(memory_limit)+1048576 > AG(allocated_memory) - rs) { \
|
||||
AG(memory_limit) = AG(allocated_memory) + 1048576; \
|
||||
if (file) { \
|
||||
zend_error(E_ERROR,"Allowed memory size of %d bytes exhausted at %s:%d (tried to allocate %d bytes)", php_mem_limit, file, lineno, s); \
|
||||
} else { \
|
||||
zend_error(E_ERROR,"Allowed memory size of %d bytes exhausted (tried to allocate %d bytes)", php_mem_limit, s); \
|
||||
} \
|
||||
} else { \
|
||||
if (file) { \
|
||||
fprintf(stderr, "Allowed memory size of %d bytes exhausted at %s:%d (tried to allocate %d bytes)\n", php_mem_limit, file, lineno, s); \
|
||||
} else { \
|
||||
fprintf(stderr, "Allowed memory size of %d bytes exhausted (tried to allocate %d bytes)\n", php_mem_limit, s); \
|
||||
} \
|
||||
exit(1); \
|
||||
} \
|
||||
} \
|
||||
}
|
||||
# endif
|
||||
|
||||
#ifndef CHECK_MEMORY_LIMIT
|
||||
#define CHECK_MEMORY_LIMIT(s, rs)
|
||||
#endif
|
||||
|
||||
|
||||
#define REMOVE_POINTER_FROM_LIST(p) \
|
||||
if (p==AG(head)) { \
|
||||
AG(head) = p->pNext; \
|
||||
} else { \
|
||||
p->pLast->pNext = p->pNext; \
|
||||
} \
|
||||
if (p->pNext) { \
|
||||
p->pNext->pLast = p->pLast; \
|
||||
}
|
||||
|
||||
#define ADD_POINTER_TO_LIST(p) \
|
||||
p->pNext = AG(head); \
|
||||
if (AG(head)) { \
|
||||
AG(head)->pLast = p; \
|
||||
} \
|
||||
AG(head) = p; \
|
||||
p->pLast = (zend_mem_header *) NULL;
|
||||
|
||||
#define DECLARE_CACHE_VARS() \
|
||||
unsigned int real_size; \
|
||||
unsigned int cache_index
|
||||
|
||||
#define REAL_SIZE(size) ((size+7) & ~0x7)
|
||||
|
||||
#define CALCULATE_REAL_SIZE_AND_CACHE_INDEX(size) \
|
||||
real_size = REAL_SIZE(size); \
|
||||
cache_index = real_size >> 3;
|
||||
|
||||
#define SIZE real_size
|
||||
|
||||
#define CACHE_INDEX cache_index
|
||||
|
||||
ZEND_API void *_emalloc(size_t size ZEND_FILE_LINE_DC ZEND_FILE_LINE_ORIG_DC)
|
||||
{
|
||||
zend_mem_header *p;
|
||||
DECLARE_CACHE_VARS();
|
||||
TSRMLS_FETCH();
|
||||
|
||||
CALCULATE_REAL_SIZE_AND_CACHE_INDEX(size);
|
||||
|
||||
#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]];
|
||||
#if ZEND_DEBUG
|
||||
p->filename = __zend_filename;
|
||||
p->lineno = __zend_lineno;
|
||||
p->orig_filename = __zend_orig_filename;
|
||||
p->orig_lineno = __zend_orig_lineno;
|
||||
p->magic = MEM_BLOCK_START_MAGIC;
|
||||
p->reported = 0;
|
||||
/* Setting the thread id should not be necessary, because we fetched this block
|
||||
* from this thread's cache
|
||||
*/
|
||||
AG(cache_stats)[CACHE_INDEX][1]++;
|
||||
memcpy((((char *) p) + sizeof(zend_mem_header) + MEM_HEADER_PADDING + size), &mem_block_end_magic, sizeof(long));
|
||||
#endif
|
||||
p->cached = 0;
|
||||
p->size = size;
|
||||
return (void *)((char *)p + sizeof(zend_mem_header) + MEM_HEADER_PADDING);
|
||||
} else {
|
||||
#endif
|
||||
#if ZEND_DEBUG
|
||||
if (CACHE_INDEX<MAX_CACHED_MEMORY) {
|
||||
AG(cache_stats)[CACHE_INDEX][0]++;
|
||||
}
|
||||
#endif
|
||||
p = (zend_mem_header *) ZEND_DO_MALLOC(sizeof(zend_mem_header) + MEM_HEADER_PADDING + SIZE + END_MAGIC_SIZE);
|
||||
#if !ZEND_DISABLE_MEMORY_CACHE
|
||||
}
|
||||
#endif
|
||||
|
||||
HANDLE_BLOCK_INTERRUPTIONS();
|
||||
|
||||
if (!p) {
|
||||
fprintf(stderr,"FATAL: emalloc(): Unable to allocate %ld bytes\n", (long) size);
|
||||
#if ZEND_DEBUG && defined(HAVE_KILL) && defined(HAVE_GETPID)
|
||||
kill(getpid(), SIGSEGV);
|
||||
#else
|
||||
exit(1);
|
||||
#endif
|
||||
HANDLE_UNBLOCK_INTERRUPTIONS();
|
||||
return (void *)p;
|
||||
}
|
||||
p->cached = 0;
|
||||
#if ZEND_DEBUG || !defined(ZEND_MM)
|
||||
ADD_POINTER_TO_LIST(p);
|
||||
#endif
|
||||
p->size = size; /* Save real size for correct cache output */
|
||||
#if ZEND_DEBUG
|
||||
p->filename = __zend_filename;
|
||||
p->lineno = __zend_lineno;
|
||||
p->orig_filename = __zend_orig_filename;
|
||||
p->orig_lineno = __zend_orig_lineno;
|
||||
p->magic = MEM_BLOCK_START_MAGIC;
|
||||
p->reported = 0;
|
||||
# ifdef ZTS
|
||||
p->thread_id = tsrm_thread_id();
|
||||
# endif
|
||||
memcpy((((char *) p) + sizeof(zend_mem_header) + MEM_HEADER_PADDING + size), &mem_block_end_magic, sizeof(long));
|
||||
#endif
|
||||
#if MEMORY_LIMIT
|
||||
CHECK_MEMORY_LIMIT(size, SIZE);
|
||||
if (AG(allocated_memory) > AG(allocated_memory_peak)) {
|
||||
AG(allocated_memory_peak) = AG(allocated_memory);
|
||||
}
|
||||
#endif
|
||||
|
||||
HANDLE_UNBLOCK_INTERRUPTIONS();
|
||||
return (void *)((char *)p + sizeof(zend_mem_header) + MEM_HEADER_PADDING);
|
||||
}
|
||||
|
||||
#include "zend_multiply.h"
|
||||
|
||||
ZEND_API void *_safe_emalloc(size_t nmemb, size_t size, size_t offset ZEND_FILE_LINE_DC ZEND_FILE_LINE_ORIG_DC)
|
||||
{
|
||||
|
||||
if (nmemb < LONG_MAX
|
||||
&& size < LONG_MAX
|
||||
&& offset < LONG_MAX
|
||||
&& nmemb >= 0
|
||||
&& size >= 0
|
||||
&& offset >= 0) {
|
||||
long lval;
|
||||
double dval;
|
||||
int use_dval;
|
||||
|
||||
ZEND_SIGNED_MULTIPLY_LONG(nmemb, size, lval, dval, use_dval);
|
||||
|
||||
if (!use_dval
|
||||
&& lval < (long) (LONG_MAX - offset)) {
|
||||
return emalloc_rel(lval + offset);
|
||||
}
|
||||
}
|
||||
|
||||
zend_error(E_ERROR, "Possible integer overflow in memory allocation (%zd * %zd + %zd)", nmemb, size, offset);
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
|
||||
ZEND_API void _efree(void *ptr ZEND_FILE_LINE_DC ZEND_FILE_LINE_ORIG_DC)
|
||||
{
|
||||
zend_mem_header *p = (zend_mem_header *) ((char *)ptr - sizeof(zend_mem_header) - MEM_HEADER_PADDING);
|
||||
DECLARE_CACHE_VARS();
|
||||
TSRMLS_FETCH();
|
||||
|
||||
#if defined(ZTS) && TSRM_DEBUG
|
||||
if (p->thread_id != tsrm_thread_id()) {
|
||||
tsrm_error(TSRM_ERROR_LEVEL_ERROR, "Memory block allocated at %s:(%d) on thread %x freed at %s:(%d) on thread %x, ignoring",
|
||||
p->filename, p->lineno, p->thread_id,
|
||||
__zend_filename, __zend_lineno, tsrm_thread_id());
|
||||
return;
|
||||
}
|
||||
#endif
|
||||
|
||||
CALCULATE_REAL_SIZE_AND_CACHE_INDEX(p->size);
|
||||
#if ZEND_DEBUG
|
||||
if (!_mem_block_check(ptr, 1 ZEND_FILE_LINE_RELAY_CC ZEND_FILE_LINE_ORIG_RELAY_CC)) {
|
||||
return;
|
||||
}
|
||||
memset(ptr, 0x5a, p->size);
|
||||
#endif
|
||||
#if !ZEND_DISABLE_MEMORY_CACHE
|
||||
if ((CACHE_INDEX < MAX_CACHED_MEMORY) && (AG(cache_count)[CACHE_INDEX] < MAX_CACHED_ENTRIES)) {
|
||||
AG(cache)[CACHE_INDEX][AG(cache_count)[CACHE_INDEX]++] = p;
|
||||
p->cached = 1;
|
||||
#if ZEND_DEBUG
|
||||
p->magic = MEM_BLOCK_CACHED_MAGIC;
|
||||
#endif
|
||||
return;
|
||||
}
|
||||
#endif
|
||||
HANDLE_BLOCK_INTERRUPTIONS();
|
||||
#if ZEND_DEBUG || !defined(ZEND_MM)
|
||||
REMOVE_POINTER_FROM_LIST(p);
|
||||
#endif
|
||||
|
||||
#if MEMORY_LIMIT
|
||||
AG(allocated_memory) -= SIZE;
|
||||
#endif
|
||||
|
||||
ZEND_DO_FREE(p);
|
||||
HANDLE_UNBLOCK_INTERRUPTIONS();
|
||||
}
|
||||
|
||||
|
||||
ZEND_API void *_ecalloc(size_t nmemb, size_t size ZEND_FILE_LINE_DC ZEND_FILE_LINE_ORIG_DC)
|
||||
{
|
||||
void *p;
|
||||
int final_size = size*nmemb;
|
||||
|
||||
HANDLE_BLOCK_INTERRUPTIONS();
|
||||
p = _emalloc(final_size ZEND_FILE_LINE_RELAY_CC ZEND_FILE_LINE_ORIG_RELAY_CC);
|
||||
if (!p) {
|
||||
HANDLE_UNBLOCK_INTERRUPTIONS();
|
||||
return (void *) p;
|
||||
}
|
||||
memset(p, 0, final_size);
|
||||
HANDLE_UNBLOCK_INTERRUPTIONS();
|
||||
return p;
|
||||
}
|
||||
|
||||
|
||||
ZEND_API void *_erealloc(void *ptr, size_t size, int allow_failure ZEND_FILE_LINE_DC ZEND_FILE_LINE_ORIG_DC)
|
||||
{
|
||||
zend_mem_header *p;
|
||||
zend_mem_header *orig;
|
||||
DECLARE_CACHE_VARS();
|
||||
TSRMLS_FETCH();
|
||||
|
||||
if (!ptr) {
|
||||
return _emalloc(size ZEND_FILE_LINE_RELAY_CC ZEND_FILE_LINE_ORIG_RELAY_CC);
|
||||
}
|
||||
|
||||
p = orig = (zend_mem_header *) ((char *)ptr-sizeof(zend_mem_header)-MEM_HEADER_PADDING);
|
||||
|
||||
#if defined(ZTS) && TSRM_DEBUG
|
||||
if (p->thread_id != tsrm_thread_id()) {
|
||||
void *new_p;
|
||||
|
||||
tsrm_error(TSRM_ERROR_LEVEL_ERROR, "Memory block allocated at %s:(%d) on thread %x reallocated at %s:(%d) on thread %x, duplicating",
|
||||
p->filename, p->lineno, p->thread_id,
|
||||
__zend_filename, __zend_lineno, tsrm_thread_id());
|
||||
new_p = _emalloc(size ZEND_FILE_LINE_RELAY_CC ZEND_FILE_LINE_ORIG_RELAY_CC);
|
||||
memcpy(new_p, ptr, p->size);
|
||||
return new_p;
|
||||
}
|
||||
#endif
|
||||
|
||||
CALCULATE_REAL_SIZE_AND_CACHE_INDEX(size);
|
||||
|
||||
HANDLE_BLOCK_INTERRUPTIONS();
|
||||
#if ZEND_DEBUG || !defined(ZEND_MM)
|
||||
REMOVE_POINTER_FROM_LIST(p);
|
||||
#endif
|
||||
p = (zend_mem_header *) ZEND_DO_REALLOC(p, sizeof(zend_mem_header)+MEM_HEADER_PADDING+SIZE+END_MAGIC_SIZE);
|
||||
if (!p) {
|
||||
if (!allow_failure) {
|
||||
fprintf(stderr,"FATAL: erealloc(): Unable to allocate %ld bytes\n", (long) size);
|
||||
#if ZEND_DEBUG && HAVE_KILL && HAVE_GETPID
|
||||
kill(getpid(), SIGSEGV);
|
||||
#else
|
||||
exit(1);
|
||||
#endif
|
||||
}
|
||||
#if ZEND_DEBUG || !defined(ZEND_MM)
|
||||
ADD_POINTER_TO_LIST(orig);
|
||||
#endif
|
||||
HANDLE_UNBLOCK_INTERRUPTIONS();
|
||||
return (void *)NULL;
|
||||
}
|
||||
#if ZEND_DEBUG || !defined(ZEND_MM)
|
||||
ADD_POINTER_TO_LIST(p);
|
||||
#endif
|
||||
#if ZEND_DEBUG
|
||||
p->filename = __zend_filename;
|
||||
p->lineno = __zend_lineno;
|
||||
p->magic = MEM_BLOCK_START_MAGIC;
|
||||
memcpy((((char *) p) + sizeof(zend_mem_header) + MEM_HEADER_PADDING + size), &mem_block_end_magic, sizeof(long));
|
||||
#endif
|
||||
#if MEMORY_LIMIT
|
||||
CHECK_MEMORY_LIMIT(size - p->size, SIZE - REAL_SIZE(p->size));
|
||||
if (AG(allocated_memory) > AG(allocated_memory_peak)) {
|
||||
AG(allocated_memory_peak) = AG(allocated_memory);
|
||||
}
|
||||
#endif
|
||||
|
||||
p->size = size;
|
||||
|
||||
HANDLE_UNBLOCK_INTERRUPTIONS();
|
||||
return (void *)((char *)p+sizeof(zend_mem_header)+MEM_HEADER_PADDING);
|
||||
}
|
||||
|
||||
|
||||
ZEND_API char *_estrdup(const char *s ZEND_FILE_LINE_DC ZEND_FILE_LINE_ORIG_DC)
|
||||
{
|
||||
int length;
|
||||
char *p;
|
||||
|
||||
length = strlen(s)+1;
|
||||
HANDLE_BLOCK_INTERRUPTIONS();
|
||||
p = (char *) _emalloc(length ZEND_FILE_LINE_RELAY_CC ZEND_FILE_LINE_ORIG_RELAY_CC);
|
||||
if (!p) {
|
||||
HANDLE_UNBLOCK_INTERRUPTIONS();
|
||||
return (char *)NULL;
|
||||
}
|
||||
HANDLE_UNBLOCK_INTERRUPTIONS();
|
||||
memcpy(p, s, length);
|
||||
return p;
|
||||
}
|
||||
|
||||
|
||||
ZEND_API char *_estrndup(const char *s, uint length ZEND_FILE_LINE_DC ZEND_FILE_LINE_ORIG_DC)
|
||||
{
|
||||
char *p;
|
||||
|
||||
HANDLE_BLOCK_INTERRUPTIONS();
|
||||
p = (char *) _emalloc(length+1 ZEND_FILE_LINE_RELAY_CC ZEND_FILE_LINE_ORIG_RELAY_CC);
|
||||
if (!p) {
|
||||
HANDLE_UNBLOCK_INTERRUPTIONS();
|
||||
return (char *)NULL;
|
||||
}
|
||||
HANDLE_UNBLOCK_INTERRUPTIONS();
|
||||
memcpy(p, s, length);
|
||||
p[length] = 0;
|
||||
return p;
|
||||
}
|
||||
|
||||
|
||||
ZEND_API char *zend_strndup(const char *s, uint length)
|
||||
{
|
||||
char *p;
|
||||
|
||||
p = (char *) malloc(length+1);
|
||||
if (!p) {
|
||||
return (char *)NULL;
|
||||
}
|
||||
if (length) {
|
||||
memcpy(p, s, length);
|
||||
}
|
||||
p[length] = 0;
|
||||
return p;
|
||||
}
|
||||
|
||||
|
||||
ZEND_API int zend_set_memory_limit(unsigned int memory_limit)
|
||||
{
|
||||
#if MEMORY_LIMIT
|
||||
TSRMLS_FETCH();
|
||||
|
||||
AG(memory_limit) = memory_limit;
|
||||
return SUCCESS;
|
||||
#else
|
||||
return FAILURE;
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
ZEND_API void start_memory_manager(TSRMLS_D)
|
||||
{
|
||||
AG(head) = NULL;
|
||||
|
||||
#if MEMORY_LIMIT
|
||||
AG(memory_limit) = 1<<30; /* ridiculous limit, effectively no limit */
|
||||
AG(allocated_memory) = 0;
|
||||
AG(memory_exhausted) = 0;
|
||||
AG(allocated_memory_peak) = 0;
|
||||
#endif
|
||||
|
||||
#if ZEND_ENABLE_FAST_CACHE
|
||||
memset(AG(fast_cache_list_head), 0, sizeof(AG(fast_cache_list_head)));
|
||||
#endif
|
||||
#if !ZEND_DISABLE_MEMORY_CACHE
|
||||
memset(AG(cache_count), 0, sizeof(AG(cache_count)));
|
||||
#endif
|
||||
|
||||
#ifdef ZEND_MM
|
||||
zend_mm_startup(&AG(mm_heap), 256*1024);
|
||||
#elif defined(ZEND_WIN32)
|
||||
AG(memory_heap) = HeapCreate(HEAP_NO_SERIALIZE, 256*1024, 0);
|
||||
#endif
|
||||
|
||||
#if ZEND_DEBUG
|
||||
memset(AG(cache_stats), 0, sizeof(AG(cache_stats)));
|
||||
memset(AG(fast_cache_stats), 0, sizeof(AG(fast_cache_stats)));
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
ZEND_API void shutdown_memory_manager(int silent, int clean_cache TSRMLS_DC)
|
||||
{
|
||||
#if ZEND_DEBUG || !defined(ZEND_MM)
|
||||
zend_mem_header *p, *t;
|
||||
#endif
|
||||
#if ZEND_DEBUG
|
||||
zend_uint grand_total_leaks=0;
|
||||
#endif
|
||||
|
||||
#if defined(ZEND_MM) && !ZEND_DEBUG
|
||||
if (clean_cache) {
|
||||
zend_mm_shutdown(&AG(mm_heap));
|
||||
return;
|
||||
}
|
||||
#elif defined(ZEND_WIN32) && !ZEND_DEBUG
|
||||
if (clean_cache && AG(memory_heap)) {
|
||||
HeapDestroy(AG(memory_heap));
|
||||
return;
|
||||
}
|
||||
#endif
|
||||
|
||||
#if ZEND_ENABLE_FAST_CACHE
|
||||
{
|
||||
zend_fast_cache_list_entry *fast_cache_list_entry, *next_fast_cache_list_entry;
|
||||
unsigned int fci;
|
||||
|
||||
for (fci=0; fci<MAX_FAST_CACHE_TYPES; fci++) {
|
||||
fast_cache_list_entry = AG(fast_cache_list_head)[fci];
|
||||
while (fast_cache_list_entry) {
|
||||
next_fast_cache_list_entry = fast_cache_list_entry->next;
|
||||
efree(fast_cache_list_entry);
|
||||
fast_cache_list_entry = next_fast_cache_list_entry;
|
||||
}
|
||||
AG(fast_cache_list_head)[fci] = NULL;
|
||||
}
|
||||
}
|
||||
#endif /* ZEND_ENABLE_FAST_CACHE */
|
||||
|
||||
#if !ZEND_DISABLE_MEMORY_CACHE && !defined(ZEND_MM)
|
||||
if (1 || clean_cache) {
|
||||
unsigned int i, j;
|
||||
zend_mem_header *ptr;
|
||||
|
||||
for (i=1; i<MAX_CACHED_MEMORY; i++) {
|
||||
for (j=0; j<AG(cache_count)[i]; j++) {
|
||||
ptr = (zend_mem_header *) AG(cache)[i][j];
|
||||
#if MEMORY_LIMIT
|
||||
AG(allocated_memory) -= REAL_SIZE(ptr->size);
|
||||
#endif
|
||||
REMOVE_POINTER_FROM_LIST(ptr);
|
||||
ZEND_DO_FREE(ptr);
|
||||
}
|
||||
AG(cache_count)[i] = 0;
|
||||
}
|
||||
}
|
||||
#endif /* !ZEND_DISABLE_MEMORY_CACHE */
|
||||
|
||||
#if ZEND_DEBUG || !defined(ZEND_MM)
|
||||
p = AG(head);
|
||||
t = AG(head);
|
||||
while (t) {
|
||||
if (!t->cached) {
|
||||
#if ZEND_DEBUG
|
||||
if (!t->cached && !t->reported) {
|
||||
zend_mem_header *iterator;
|
||||
int total_leak=0, total_leak_count=0;
|
||||
|
||||
grand_total_leaks++;
|
||||
if (!silent) {
|
||||
zend_message_dispatcher(ZMSG_MEMORY_LEAK_DETECTED, t);
|
||||
}
|
||||
t->reported = 1;
|
||||
for (iterator=t->pNext; iterator; iterator=iterator->pNext) {
|
||||
if (!iterator->cached
|
||||
&& iterator->filename==t->filename
|
||||
&& iterator->lineno==t->lineno) {
|
||||
total_leak += iterator->size;
|
||||
total_leak_count++;
|
||||
iterator->reported = 1;
|
||||
}
|
||||
}
|
||||
if (!silent && total_leak_count>0) {
|
||||
zend_message_dispatcher(ZMSG_MEMORY_LEAK_REPEATED, (void *) (long) (total_leak_count));
|
||||
}
|
||||
grand_total_leaks += total_leak_count;
|
||||
}
|
||||
#endif
|
||||
#if MEMORY_LIMIT
|
||||
AG(allocated_memory) -= REAL_SIZE(t->size);
|
||||
#endif
|
||||
p = t->pNext;
|
||||
REMOVE_POINTER_FROM_LIST(t);
|
||||
ZEND_DO_FREE(t);
|
||||
t = p;
|
||||
} else {
|
||||
t = t->pNext;
|
||||
}
|
||||
}
|
||||
|
||||
#if ZEND_DEBUG
|
||||
if (!silent && grand_total_leaks > 0) {
|
||||
zend_message_dispatcher(ZMSG_MEMORY_LEAKS_GRAND_TOTAL, &grand_total_leaks);
|
||||
}
|
||||
#endif
|
||||
|
||||
#if MEMORY_LIMIT
|
||||
AG(memory_exhausted)=0;
|
||||
AG(allocated_memory_peak) = 0;
|
||||
#endif
|
||||
|
||||
|
||||
#if (ZEND_DEBUG)
|
||||
do {
|
||||
zval display_memory_cache_stats;
|
||||
int i, j;
|
||||
|
||||
if (clean_cache) {
|
||||
/* we're shutting down completely, don't even touch the INI subsystem */
|
||||
break;
|
||||
}
|
||||
if (zend_get_configuration_directive("display_memory_cache_stats", sizeof("display_memory_cache_stats"), &display_memory_cache_stats)==FAILURE) {
|
||||
break;
|
||||
}
|
||||
if (!atoi(display_memory_cache_stats.value.str.val)) {
|
||||
break;
|
||||
}
|
||||
fprintf(stderr, "Memory cache statistics\n"
|
||||
"-----------------------\n\n"
|
||||
"[zval, %2ld]\t\t%d / %d (%.2f%%)\n"
|
||||
"[hash, %2ld]\t\t%d / %d (%.2f%%)\n",
|
||||
(long) sizeof(zval),
|
||||
AG(fast_cache_stats)[ZVAL_CACHE_LIST][1], AG(fast_cache_stats)[ZVAL_CACHE_LIST][0]+AG(fast_cache_stats)[ZVAL_CACHE_LIST][1],
|
||||
((double) AG(fast_cache_stats)[ZVAL_CACHE_LIST][1] / (AG(fast_cache_stats)[ZVAL_CACHE_LIST][0]+AG(fast_cache_stats)[ZVAL_CACHE_LIST][1]))*100,
|
||||
(long) sizeof(HashTable),
|
||||
AG(fast_cache_stats)[HASHTABLE_CACHE_LIST][1], AG(fast_cache_stats)[HASHTABLE_CACHE_LIST][0]+AG(fast_cache_stats)[HASHTABLE_CACHE_LIST][1],
|
||||
((double) AG(fast_cache_stats)[HASHTABLE_CACHE_LIST][1] / (AG(fast_cache_stats)[HASHTABLE_CACHE_LIST][0]+AG(fast_cache_stats)[HASHTABLE_CACHE_LIST][1]))*100);
|
||||
|
||||
|
||||
for (i=0; i<MAX_CACHED_MEMORY; i+=2) {
|
||||
fprintf(stderr, "[%2d, %2d]\t\t", i, i+1);
|
||||
for (j=0; j<2; j++) {
|
||||
fprintf(stderr, "%d / %d (%.2f%%)\t\t",
|
||||
AG(cache_stats)[i+j][1], AG(cache_stats)[i+j][0]+AG(cache_stats)[i+j][1],
|
||||
((double) AG(cache_stats)[i+j][1] / (AG(cache_stats)[i+j][0]+AG(cache_stats)[i+j][1]))*100);
|
||||
}
|
||||
fprintf(stderr, "\n");
|
||||
}
|
||||
|
||||
} while (0);
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
#if defined(ZEND_MM) && ZEND_DEBUG
|
||||
if (clean_cache) {
|
||||
zend_mm_shutdown(&AG(mm_heap));
|
||||
return;
|
||||
}
|
||||
#elif defined(ZEND_WIN32) && ZEND_DEBUG
|
||||
if (clean_cache && AG(memory_heap)) {
|
||||
HeapDestroy(AG(memory_heap));
|
||||
return;
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
#if ZEND_DEBUG
|
||||
void zend_debug_alloc_output(char *format, ...)
|
||||
{
|
||||
char output_buf[256];
|
||||
va_list args;
|
||||
|
||||
va_start(args, format);
|
||||
vsprintf(output_buf, format, args);
|
||||
va_end(args);
|
||||
|
||||
#ifdef ZEND_WIN32
|
||||
OutputDebugString(output_buf);
|
||||
#else
|
||||
fprintf(stderr, "%s", output_buf);
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
ZEND_API int _mem_block_check(void *ptr, int silent ZEND_FILE_LINE_DC ZEND_FILE_LINE_ORIG_DC)
|
||||
{
|
||||
zend_mem_header *p = (zend_mem_header *) ((char *)ptr - sizeof(zend_mem_header) - MEM_HEADER_PADDING);
|
||||
int no_cache_notice=0;
|
||||
int valid_beginning=1;
|
||||
int had_problems=0;
|
||||
long end_magic;
|
||||
|
||||
if (silent==2) {
|
||||
silent = 1;
|
||||
no_cache_notice = 1;
|
||||
}
|
||||
if (silent==3) {
|
||||
silent = 0;
|
||||
no_cache_notice = 1;
|
||||
}
|
||||
if (!silent) {
|
||||
zend_message_dispatcher(ZMSG_LOG_SCRIPT_NAME, NULL);
|
||||
zend_debug_alloc_output("---------------------------------------\n");
|
||||
zend_debug_alloc_output("%s(%d) : Block 0x%0.8lX status:\n" ZEND_FILE_LINE_RELAY_CC, (long) p);
|
||||
if (__zend_orig_filename) {
|
||||
zend_debug_alloc_output("%s(%d) : Actual location (location was relayed)\n" ZEND_FILE_LINE_ORIG_RELAY_CC);
|
||||
}
|
||||
zend_debug_alloc_output("%10s\t","Beginning: ");
|
||||
}
|
||||
|
||||
switch (p->magic) {
|
||||
case MEM_BLOCK_START_MAGIC:
|
||||
if (!silent) {
|
||||
zend_debug_alloc_output("OK (allocated on %s:%d, %d bytes)\n", p->filename, p->lineno, p->size);
|
||||
}
|
||||
break; /* ok */
|
||||
case MEM_BLOCK_FREED_MAGIC:
|
||||
if (!silent) {
|
||||
zend_debug_alloc_output("Freed\n");
|
||||
had_problems = 1;
|
||||
} else {
|
||||
return _mem_block_check(ptr, 0 ZEND_FILE_LINE_RELAY_CC ZEND_FILE_LINE_ORIG_RELAY_CC);
|
||||
}
|
||||
break;
|
||||
case MEM_BLOCK_CACHED_MAGIC:
|
||||
if (!silent) {
|
||||
if (!no_cache_notice) {
|
||||
zend_debug_alloc_output("Cached (allocated on %s:%d, %d bytes)\n", p->filename, p->lineno, p->size);
|
||||
had_problems = 1;
|
||||
}
|
||||
} else {
|
||||
if (!no_cache_notice) {
|
||||
return _mem_block_check(ptr, 0 ZEND_FILE_LINE_RELAY_CC ZEND_FILE_LINE_ORIG_RELAY_CC);
|
||||
}
|
||||
}
|
||||
break;
|
||||
default:
|
||||
if (!silent) {
|
||||
zend_debug_alloc_output("Overrun (magic=0x%0.8lX, expected=0x%0.8lX)\n", p->magic, MEM_BLOCK_START_MAGIC);
|
||||
} else {
|
||||
return _mem_block_check(ptr, 0 ZEND_FILE_LINE_RELAY_CC ZEND_FILE_LINE_ORIG_RELAY_CC);
|
||||
}
|
||||
had_problems = 1;
|
||||
valid_beginning = 0;
|
||||
break;
|
||||
}
|
||||
|
||||
|
||||
memcpy(&end_magic, (((char *) p)+sizeof(zend_mem_header)+MEM_HEADER_PADDING+p->size), sizeof(long));
|
||||
|
||||
if (valid_beginning && (end_magic != MEM_BLOCK_END_MAGIC)) {
|
||||
char *overflow_ptr, *magic_ptr=(char *) &mem_block_end_magic;
|
||||
int overflows=0;
|
||||
long i;
|
||||
|
||||
if (silent) {
|
||||
return _mem_block_check(ptr, 0 ZEND_FILE_LINE_RELAY_CC ZEND_FILE_LINE_ORIG_RELAY_CC);
|
||||
}
|
||||
had_problems = 1;
|
||||
overflow_ptr = (char *) &end_magic;
|
||||
|
||||
for (i=0; i<(int)sizeof(long); i++) {
|
||||
if (overflow_ptr[i]!=magic_ptr[i]) {
|
||||
overflows++;
|
||||
}
|
||||
}
|
||||
|
||||
zend_debug_alloc_output("%10s\t", "End:");
|
||||
zend_debug_alloc_output("Overflown (magic=0x%0.8lX instead of 0x%0.8lX)\n", end_magic, MEM_BLOCK_END_MAGIC);
|
||||
zend_debug_alloc_output("%10s\t","");
|
||||
if (overflows>=(int)sizeof(long)) {
|
||||
zend_debug_alloc_output("At least %d bytes overflown\n", sizeof(long));
|
||||
} else {
|
||||
zend_debug_alloc_output("%d byte(s) overflown\n", overflows);
|
||||
}
|
||||
} else if (!silent) {
|
||||
zend_debug_alloc_output("%10s\t", "End:");
|
||||
if (valid_beginning) {
|
||||
zend_debug_alloc_output("OK\n");
|
||||
} else {
|
||||
zend_debug_alloc_output("Unknown\n");
|
||||
}
|
||||
}
|
||||
|
||||
if (!silent) {
|
||||
zend_debug_alloc_output("---------------------------------------\n");
|
||||
}
|
||||
return ((!had_problems) ? 1 : 0);
|
||||
}
|
||||
|
||||
|
||||
ZEND_API void _full_mem_check(int silent ZEND_FILE_LINE_DC ZEND_FILE_LINE_ORIG_DC)
|
||||
{
|
||||
zend_mem_header *p;
|
||||
int errors=0;
|
||||
TSRMLS_FETCH();
|
||||
|
||||
p = AG(head);
|
||||
|
||||
|
||||
zend_debug_alloc_output("------------------------------------------------\n");
|
||||
zend_debug_alloc_output("Full Memory Check at %s:%d\n" ZEND_FILE_LINE_RELAY_CC);
|
||||
|
||||
while (p) {
|
||||
if (!_mem_block_check((void *)((char *)p + sizeof(zend_mem_header) + MEM_HEADER_PADDING), (silent?2:3) ZEND_FILE_LINE_RELAY_CC ZEND_FILE_LINE_ORIG_RELAY_CC)) {
|
||||
errors++;
|
||||
}
|
||||
p = p->pNext;
|
||||
}
|
||||
zend_debug_alloc_output("End of full memory check %s:%d (%d errors)\n" ZEND_FILE_LINE_RELAY_CC, errors);
|
||||
zend_debug_alloc_output("------------------------------------------------\n");
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
/*
|
||||
* Local variables:
|
||||
* tab-width: 4
|
||||
* c-basic-offset: 4
|
||||
* indent-tabs-mode: t
|
||||
* End:
|
||||
*/
|
||||
@@ -1,153 +0,0 @@
|
||||
/*
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2003 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 |
|
||||
| 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 |
|
||||
| obtain it through the world-wide-web, please send a note to |
|
||||
| license@zend.com so we can mail you a copy immediately. |
|
||||
+----------------------------------------------------------------------+
|
||||
| Authors: Andi Gutmans <andi@zend.com> |
|
||||
| Zeev Suraski <zeev@zend.com> |
|
||||
+----------------------------------------------------------------------+
|
||||
*/
|
||||
|
||||
/* $Id$ */
|
||||
|
||||
#ifndef ZEND_ALLOC_H
|
||||
#define ZEND_ALLOC_H
|
||||
|
||||
#include <stdio.h>
|
||||
|
||||
#include "../TSRM/TSRM.h"
|
||||
#include "zend_globals_macros.h"
|
||||
|
||||
#include "zend_mm.h"
|
||||
|
||||
#define MEM_BLOCK_START_MAGIC 0x7312F8DCL
|
||||
#define MEM_BLOCK_END_MAGIC 0x2A8FCC84L
|
||||
#define MEM_BLOCK_FREED_MAGIC 0x99954317L
|
||||
#define MEM_BLOCK_CACHED_MAGIC 0xFB8277DCL
|
||||
|
||||
typedef struct _zend_mem_header {
|
||||
#if ZEND_DEBUG
|
||||
long magic;
|
||||
char *filename;
|
||||
uint lineno;
|
||||
int reported;
|
||||
char *orig_filename;
|
||||
uint orig_lineno;
|
||||
# ifdef ZTS
|
||||
THREAD_T thread_id;
|
||||
# endif
|
||||
#endif
|
||||
#if ZEND_DEBUG || !defined(ZEND_MM)
|
||||
struct _zend_mem_header *pNext;
|
||||
struct _zend_mem_header *pLast;
|
||||
#endif
|
||||
unsigned int size:31;
|
||||
unsigned int cached:1;
|
||||
} zend_mem_header;
|
||||
|
||||
typedef union _align_test {
|
||||
void *ptr;
|
||||
double dbl;
|
||||
long lng;
|
||||
} align_test;
|
||||
|
||||
#define MAX_CACHED_MEMORY 11
|
||||
#define MAX_CACHED_ENTRIES 256
|
||||
#define PRE_INIT_CACHE_ENTRIES 32
|
||||
|
||||
#if ZEND_GCC_VERSION >= 2000
|
||||
# define PLATFORM_ALIGNMENT (__alignof__ (align_test))
|
||||
#else
|
||||
# define PLATFORM_ALIGNMENT (sizeof(align_test))
|
||||
#endif
|
||||
|
||||
#define MEM_HEADER_PADDING (((PLATFORM_ALIGNMENT-sizeof(zend_mem_header))%PLATFORM_ALIGNMENT+PLATFORM_ALIGNMENT)%PLATFORM_ALIGNMENT)
|
||||
|
||||
|
||||
BEGIN_EXTERN_C()
|
||||
|
||||
ZEND_API char *zend_strndup(const char *s, unsigned int length) ZEND_ATTRIBUTE_MALLOC;
|
||||
|
||||
ZEND_API void *_emalloc(size_t size ZEND_FILE_LINE_DC ZEND_FILE_LINE_ORIG_DC) ZEND_ATTRIBUTE_MALLOC;
|
||||
ZEND_API void *_safe_emalloc(size_t nmemb, size_t size, size_t offset ZEND_FILE_LINE_DC ZEND_FILE_LINE_ORIG_DC) ZEND_ATTRIBUTE_MALLOC;
|
||||
ZEND_API void _efree(void *ptr ZEND_FILE_LINE_DC ZEND_FILE_LINE_ORIG_DC);
|
||||
ZEND_API void *_ecalloc(size_t nmemb, size_t size ZEND_FILE_LINE_DC ZEND_FILE_LINE_ORIG_DC) ZEND_ATTRIBUTE_MALLOC;
|
||||
ZEND_API void *_erealloc(void *ptr, size_t size, int allow_failure ZEND_FILE_LINE_DC ZEND_FILE_LINE_ORIG_DC);
|
||||
ZEND_API char *_estrdup(const char *s ZEND_FILE_LINE_DC ZEND_FILE_LINE_ORIG_DC) ZEND_ATTRIBUTE_MALLOC;
|
||||
ZEND_API char *_estrndup(const char *s, unsigned int length ZEND_FILE_LINE_DC ZEND_FILE_LINE_ORIG_DC) ZEND_ATTRIBUTE_MALLOC;
|
||||
|
||||
/* Standard wrapper macros */
|
||||
#define emalloc(size) _emalloc((size) ZEND_FILE_LINE_CC ZEND_FILE_LINE_EMPTY_CC)
|
||||
#define safe_emalloc(nmemb, size, offset) _safe_emalloc((nmemb), (size), (offset) ZEND_FILE_LINE_CC ZEND_FILE_LINE_EMPTY_CC)
|
||||
#define efree(ptr) _efree((ptr) ZEND_FILE_LINE_CC ZEND_FILE_LINE_EMPTY_CC)
|
||||
#define ecalloc(nmemb, size) _ecalloc((nmemb), (size) ZEND_FILE_LINE_CC ZEND_FILE_LINE_EMPTY_CC)
|
||||
#define erealloc(ptr, size) _erealloc((ptr), (size), 0 ZEND_FILE_LINE_CC ZEND_FILE_LINE_EMPTY_CC)
|
||||
#define erealloc_recoverable(ptr, size) _erealloc((ptr), (size), 1 ZEND_FILE_LINE_CC ZEND_FILE_LINE_EMPTY_CC)
|
||||
#define estrdup(s) _estrdup((s) ZEND_FILE_LINE_CC ZEND_FILE_LINE_EMPTY_CC)
|
||||
#define estrndup(s, length) _estrndup((s), (length) ZEND_FILE_LINE_CC ZEND_FILE_LINE_EMPTY_CC)
|
||||
|
||||
/* Relay wrapper macros */
|
||||
#define emalloc_rel(size) _emalloc((size) ZEND_FILE_LINE_RELAY_CC ZEND_FILE_LINE_CC)
|
||||
#define safe_emalloc_rel(nmemb, size, offset) _safe_emalloc((nmemb), (size), (offset) ZEND_FILE_LINE_RELAY_CC ZEND_FILE_LINE_CC)
|
||||
#define efree_rel(ptr) _efree((ptr) ZEND_FILE_LINE_RELAY_CC ZEND_FILE_LINE_CC)
|
||||
#define ecalloc_rel(nmemb, size) _ecalloc((nmemb), (size) ZEND_FILE_LINE_RELAY_CC ZEND_FILE_LINE_CC)
|
||||
#define erealloc_rel(ptr, size) _erealloc((ptr), (size), 0 ZEND_FILE_LINE_RELAY_CC ZEND_FILE_LINE_CC)
|
||||
#define erealloc_recoverable_rel(ptr, size) _erealloc((ptr), (size), 1 ZEND_FILE_LINE_RELAY_CC ZEND_FILE_LINE_CC)
|
||||
#define estrdup_rel(s) _estrdup((s) ZEND_FILE_LINE_RELAY_CC ZEND_FILE_LINE_CC)
|
||||
#define estrndup_rel(s, length) _estrndup((s), (length) ZEND_FILE_LINE_RELAY_CC ZEND_FILE_LINE_CC)
|
||||
|
||||
/* Selective persistent/non persistent allocation macros */
|
||||
#define pemalloc(size, persistent) ((persistent)?malloc(size):emalloc(size))
|
||||
#define pefree(ptr, persistent) ((persistent)?free(ptr):efree(ptr))
|
||||
#define pecalloc(nmemb, size, persistent) ((persistent)?calloc((nmemb), (size)):ecalloc((nmemb), (size)))
|
||||
#define perealloc(ptr, size, persistent) ((persistent)?realloc((ptr), (size)):erealloc((ptr), (size)))
|
||||
#define perealloc_recoverable(ptr, size, persistent) ((persistent)?realloc((ptr), (size)):erealloc_recoverable((ptr), (size)))
|
||||
#define pestrdup(s, persistent) ((persistent)?strdup(s):estrdup(s))
|
||||
|
||||
#define pemalloc_rel(size, persistent) ((persistent)?malloc(size):emalloc_rel(size))
|
||||
#define pefree_rel(ptr, persistent) ((persistent)?free(ptr):efree_rel(ptr))
|
||||
#define pecalloc_rel(nmemb, size, persistent) ((persistent)?calloc((nmemb), (size)):ecalloc_rel((nmemb), (size)))
|
||||
#define perealloc_rel(ptr, size, persistent) ((persistent)?realloc((ptr), (size)):erealloc_rel((ptr), (size)))
|
||||
#define perealloc_recoverable_rel(ptr, size, persistent) ((persistent)?realloc((ptr), (size)):erealloc_recoverable_rel((ptr), (size)))
|
||||
#define pestrdup_rel(s, persistent) ((persistent)?strdup(s):estrdup_rel(s))
|
||||
|
||||
#define safe_estrdup(ptr) ((ptr)?(estrdup(ptr)):(empty_string))
|
||||
#define safe_estrndup(ptr, len) ((ptr)?(estrndup((ptr), (len))):(empty_string))
|
||||
|
||||
ZEND_API int zend_set_memory_limit(unsigned int memory_limit);
|
||||
|
||||
ZEND_API void start_memory_manager(TSRMLS_D);
|
||||
ZEND_API void shutdown_memory_manager(int silent, int clean_cache TSRMLS_DC);
|
||||
|
||||
#if ZEND_DEBUG
|
||||
ZEND_API int _mem_block_check(void *ptr, int silent ZEND_FILE_LINE_DC ZEND_FILE_LINE_ORIG_DC);
|
||||
ZEND_API void _full_mem_check(int silent ZEND_FILE_LINE_DC ZEND_FILE_LINE_ORIG_DC);
|
||||
void zend_debug_alloc_output(char *format, ...);
|
||||
#define mem_block_check(ptr, silent) _mem_block_check(ptr, silent ZEND_FILE_LINE_CC ZEND_FILE_LINE_EMPTY_CC)
|
||||
#define full_mem_check(silent) _full_mem_check(silent ZEND_FILE_LINE_CC ZEND_FILE_LINE_EMPTY_CC)
|
||||
#else
|
||||
#define mem_block_check(type, ptr, silent)
|
||||
#define full_mem_check(silent)
|
||||
#endif
|
||||
|
||||
|
||||
END_EXTERN_C()
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
* Local variables:
|
||||
* tab-width: 4
|
||||
* c-basic-offset: 4
|
||||
* indent-tabs-mode: t
|
||||
* End:
|
||||
*/
|
||||
@@ -1,27 +0,0 @@
|
||||
ZEND_BEGIN_ARG_INFO(first_arg_force_ref, 0)
|
||||
ZEND_ARG_PASS_INFO(1)
|
||||
ZEND_END_ARG_INFO();
|
||||
|
||||
|
||||
ZEND_BEGIN_ARG_INFO(second_arg_force_ref, 0)
|
||||
ZEND_ARG_PASS_INFO(0)
|
||||
ZEND_ARG_PASS_INFO(1)
|
||||
ZEND_END_ARG_INFO();
|
||||
|
||||
ZEND_BEGIN_ARG_INFO(third_arg_force_ref, 0)
|
||||
ZEND_ARG_PASS_INFO(0)
|
||||
ZEND_ARG_PASS_INFO(0)
|
||||
ZEND_ARG_PASS_INFO(1)
|
||||
ZEND_END_ARG_INFO();
|
||||
|
||||
|
||||
ZEND_BEGIN_ARG_INFO(fourth_arg_force_ref, 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();
|
||||
|
||||
File diff suppressed because it is too large.
Load diff
@@ -1,36 +0,0 @@
|
||||
/*
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2003 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 |
|
||||
| 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 |
|
||||
| obtain it through the world-wide-web, please send a note to |
|
||||
| license@zend.com so we can mail you a copy immediately. |
|
||||
+----------------------------------------------------------------------+
|
||||
| Authors: Andi Gutmans <andi@zend.com> |
|
||||
| Zeev Suraski <zeev@zend.com> |
|
||||
+----------------------------------------------------------------------+
|
||||
*/
|
||||
|
||||
/* $Id$ */
|
||||
|
||||
#ifndef ZEND_BUILTIN_FUNCTIONS_H
|
||||
#define ZEND_BUILTIN_FUNCTIONS_H
|
||||
|
||||
int zend_startup_builtin_functions(TSRMLS_D);
|
||||
ZEND_API void zend_fetch_debug_backtrace(zval *return_value, int skip_last TSRMLS_DC);
|
||||
|
||||
#endif /* ZEND_BUILTIN_FUNCTIONS_H */
|
||||
|
||||
/*
|
||||
* Local variables:
|
||||
* tab-width: 4
|
||||
* c-basic-offset: 4
|
||||
* indent-tabs-mode: t
|
||||
* End:
|
||||
*/
|
||||
-3594
File diff suppressed because it is too large.
Load diff
@@ -1,813 +0,0 @@
|
||||
/*
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2003 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 |
|
||||
| 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 |
|
||||
| obtain it through the world-wide-web, please send a note to |
|
||||
| license@zend.com so we can mail you a copy immediately. |
|
||||
+----------------------------------------------------------------------+
|
||||
| Authors: Andi Gutmans <andi@zend.com> |
|
||||
| Zeev Suraski <zeev@zend.com> |
|
||||
+----------------------------------------------------------------------+
|
||||
*/
|
||||
|
||||
/* $Id$ */
|
||||
|
||||
#ifndef ZEND_COMPILE_H
|
||||
#define ZEND_COMPILE_H
|
||||
|
||||
#include "zend.h"
|
||||
|
||||
#ifdef HAVE_STDARG_H
|
||||
# include <stdarg.h>
|
||||
#endif
|
||||
|
||||
#include "zend_llist.h"
|
||||
|
||||
#define DEBUG_ZEND 0
|
||||
|
||||
#define FREE_PNODE(znode) zval_dtor(&znode->u.constant);
|
||||
#define FREE_OP(Ts, op, should_free) if (should_free) zval_dtor(should_free);
|
||||
|
||||
#define SET_UNUSED(op) (op).op_type = IS_UNUSED
|
||||
|
||||
#define INC_BPC(op_array) if (CG(interactive)) { ((op_array)->backpatch_count++); }
|
||||
#define DEC_BPC(op_array) if (CG(interactive)) { ((op_array)->backpatch_count--); }
|
||||
#define HANDLE_INTERACTIVE() if (CG(interactive)) { execute_new_code(TSRMLS_C); }
|
||||
|
||||
#define RESET_DOC_COMMENT() \
|
||||
{ \
|
||||
CG(doc_comment) = NULL; \
|
||||
CG(doc_comment_len) = 0; \
|
||||
}
|
||||
|
||||
typedef struct _zend_op_array zend_op_array;
|
||||
typedef struct _zend_op zend_op;
|
||||
|
||||
typedef struct _znode {
|
||||
int op_type;
|
||||
zend_llist *throw_list; /* Try and save this space later on */
|
||||
union {
|
||||
zval constant;
|
||||
|
||||
zend_uint var;
|
||||
zend_uint opline_num; /* Needs to be signed */
|
||||
zend_op_array *op_array;
|
||||
zend_op *jmp_addr;
|
||||
struct {
|
||||
zend_uint var; /* dummy */
|
||||
zend_uint type;
|
||||
} EA;
|
||||
} u;
|
||||
} znode;
|
||||
|
||||
typedef struct _zend_execute_data zend_execute_data;
|
||||
|
||||
#define ZEND_OPCODE_HANDLER_ARGS zend_execute_data *execute_data, zend_op_array *op_array TSRMLS_DC
|
||||
#define ZEND_OPCODE_HANDLER_ARGS_PASSTHRU execute_data, op_array TSRMLS_CC
|
||||
|
||||
typedef int (*opcode_handler_t) (ZEND_OPCODE_HANDLER_ARGS);
|
||||
|
||||
extern opcode_handler_t zend_opcode_handlers[512];
|
||||
|
||||
struct _zend_op {
|
||||
opcode_handler_t handler;
|
||||
znode result;
|
||||
znode op1;
|
||||
znode op2;
|
||||
ulong extended_value;
|
||||
uint lineno;
|
||||
zend_uchar opcode;
|
||||
};
|
||||
|
||||
|
||||
typedef struct _zend_brk_cont_element {
|
||||
int cont;
|
||||
int brk;
|
||||
int parent;
|
||||
} zend_brk_cont_element;
|
||||
|
||||
|
||||
#define ZEND_ACC_STATIC 0x01
|
||||
#define ZEND_ACC_ABSTRACT 0x02
|
||||
#define ZEND_ACC_FINAL 0x04
|
||||
#define ZEND_ACC_INTERFACE 0x08
|
||||
#define ZEND_ACC_ABSTRACT_CLASS 0x10
|
||||
#define ZEND_ACC_FINAL_CLASS 0x20
|
||||
|
||||
/* The order of those must be kept - public < protected < private */
|
||||
#define ZEND_ACC_PUBLIC 0x100
|
||||
#define ZEND_ACC_PROTECTED 0x200
|
||||
#define ZEND_ACC_PRIVATE 0x400
|
||||
#define ZEND_ACC_PPP_MASK (ZEND_ACC_PUBLIC | ZEND_ACC_PROTECTED | ZEND_ACC_PRIVATE)
|
||||
|
||||
#define ZEND_ACC_CHANGED 0x800
|
||||
#define ZEND_ACC_IMPLICIT_PUBLIC 0x1000
|
||||
|
||||
#define ZEND_ACC_CTOR 0x2000
|
||||
#define ZEND_ACC_DTOR 0x4000
|
||||
|
||||
char *zend_visibility_string(zend_uint fn_flags);
|
||||
|
||||
|
||||
typedef struct _zend_property_info {
|
||||
zend_uint flags;
|
||||
char *name;
|
||||
int name_length;
|
||||
ulong h;
|
||||
} zend_property_info;
|
||||
|
||||
|
||||
typedef struct _zend_arg_info {
|
||||
char *name;
|
||||
zend_uint name_len;
|
||||
char *class_name;
|
||||
zend_uint class_name_len;
|
||||
zend_bool allow_null;
|
||||
zend_bool pass_by_reference;
|
||||
} zend_arg_info;
|
||||
|
||||
struct _zend_op_array {
|
||||
/* Common elements */
|
||||
zend_uchar type;
|
||||
char *function_name;
|
||||
zend_class_entry *scope;
|
||||
zend_uint fn_flags;
|
||||
union _zend_function *prototype;
|
||||
zend_uint num_args;
|
||||
zend_arg_info *arg_info;
|
||||
zend_bool pass_rest_by_reference;
|
||||
/* END of common elements */
|
||||
|
||||
zend_uint *refcount;
|
||||
|
||||
zend_op *opcodes;
|
||||
zend_uint last, size;
|
||||
|
||||
zend_uint T;
|
||||
|
||||
zend_brk_cont_element *brk_cont_array;
|
||||
zend_uint last_brk_cont;
|
||||
zend_uint current_brk_cont;
|
||||
|
||||
/* static variables support */
|
||||
HashTable *static_variables;
|
||||
|
||||
zend_op *start_op;
|
||||
int backpatch_count;
|
||||
|
||||
zend_bool return_reference;
|
||||
zend_bool done_pass_two;
|
||||
zend_bool uses_this;
|
||||
|
||||
char *filename;
|
||||
zend_uint line_start;
|
||||
zend_uint line_end;
|
||||
char *doc_comment;
|
||||
zend_uint doc_comment_len;
|
||||
|
||||
void *reserved[ZEND_MAX_RESERVED_RESOURCES];
|
||||
};
|
||||
|
||||
|
||||
typedef struct _zend_internal_function {
|
||||
/* Common elements */
|
||||
zend_uchar type;
|
||||
char *function_name;
|
||||
zend_class_entry *scope;
|
||||
zend_uint fn_flags;
|
||||
union _zend_function *prototype;
|
||||
zend_uint num_args;
|
||||
zend_arg_info *arg_info;
|
||||
zend_bool pass_rest_by_reference;
|
||||
/* END of common elements */
|
||||
|
||||
void (*handler)(INTERNAL_FUNCTION_PARAMETERS);
|
||||
} zend_internal_function;
|
||||
|
||||
#define ZEND_FN_SCOPE_NAME(function) ((function) && (function)->common.scope ? (function)->common.scope->name : "")
|
||||
|
||||
typedef union _zend_function {
|
||||
zend_uchar type; /* MUST be the first element of this struct! */
|
||||
|
||||
struct {
|
||||
zend_uchar type; /* never used */
|
||||
char *function_name;
|
||||
zend_class_entry *scope;
|
||||
zend_uint fn_flags;
|
||||
union _zend_function *prototype;
|
||||
zend_uint num_args;
|
||||
zend_arg_info *arg_info;
|
||||
zend_bool pass_rest_by_reference;
|
||||
} common;
|
||||
|
||||
zend_op_array op_array;
|
||||
zend_internal_function internal_function;
|
||||
} zend_function;
|
||||
|
||||
|
||||
typedef struct _zend_function_state {
|
||||
HashTable *function_symbol_table;
|
||||
zend_function *function;
|
||||
void *reserved[ZEND_MAX_RESERVED_RESOURCES];
|
||||
} zend_function_state;
|
||||
|
||||
|
||||
typedef struct _zend_switch_entry {
|
||||
znode cond;
|
||||
int default_case;
|
||||
int control_var;
|
||||
} zend_switch_entry;
|
||||
|
||||
|
||||
typedef struct _list_llist_element {
|
||||
znode var;
|
||||
zend_llist dimensions;
|
||||
znode value;
|
||||
} list_llist_element;
|
||||
|
||||
union _temp_variable;
|
||||
|
||||
struct _zend_execute_data {
|
||||
struct _zend_op *opline;
|
||||
zend_function_state function_state;
|
||||
zend_function *fbc; /* Function Being Called */
|
||||
zend_function *fbc_constructor;
|
||||
zend_op_array *op_array;
|
||||
zval *object;
|
||||
union _temp_variable *Ts;
|
||||
zend_bool original_in_execution;
|
||||
zend_class_entry *calling_scope;
|
||||
struct _zend_execute_data *prev_execute_data;
|
||||
};
|
||||
|
||||
#define EX(element) execute_data.element
|
||||
|
||||
|
||||
#define IS_CONST (1<<0)
|
||||
#define IS_TMP_VAR (1<<1)
|
||||
#define IS_VAR (1<<2)
|
||||
#define IS_UNUSED (1<<3) /* Unused variable */
|
||||
|
||||
#define EXT_TYPE_UNUSED (1<<0)
|
||||
|
||||
#include "zend_globals.h"
|
||||
|
||||
BEGIN_EXTERN_C()
|
||||
|
||||
void init_compiler(TSRMLS_D);
|
||||
void shutdown_compiler(TSRMLS_D);
|
||||
void zend_init_compiler_data_structures(TSRMLS_D);
|
||||
|
||||
extern ZEND_API zend_op_array *(*zend_compile_file)(zend_file_handle *file_handle, int type TSRMLS_DC);
|
||||
|
||||
ZEND_API int lex_scan(zval *zendlval TSRMLS_DC);
|
||||
void startup_scanner(TSRMLS_D);
|
||||
void shutdown_scanner(TSRMLS_D);
|
||||
|
||||
ZEND_API char *zend_set_compiled_filename(char *new_compiled_filename TSRMLS_DC);
|
||||
ZEND_API void zend_restore_compiled_filename(char *original_compiled_filename TSRMLS_DC);
|
||||
ZEND_API char *zend_get_compiled_filename(TSRMLS_D);
|
||||
ZEND_API int zend_get_compiled_lineno(TSRMLS_D);
|
||||
|
||||
#ifdef ZTS
|
||||
const char *zend_get_zendtext(TSRMLS_D);
|
||||
int zend_get_zendleng(TSRMLS_D);
|
||||
#endif
|
||||
|
||||
|
||||
/* parser-driven code generators */
|
||||
void zend_do_fold_binary_op(zend_uchar op, znode *result, znode *op1, znode *op2 TSRMLS_DC);
|
||||
void zend_do_fold_constant(znode *result, znode *constant_name TSRMLS_DC);
|
||||
void zend_do_binary_op(zend_uchar op, znode *result, znode *op1, znode *op2 TSRMLS_DC);
|
||||
void zend_do_unary_op(zend_uchar op, znode *result, znode *op1 TSRMLS_DC);
|
||||
void zend_do_binary_assign_op(zend_uchar op, znode *result, znode *op1, znode *op2 TSRMLS_DC);
|
||||
void zend_do_assign(znode *result, znode *variable, znode *value TSRMLS_DC);
|
||||
void zend_do_assign_ref(znode *result, znode *lvar, znode *rvar TSRMLS_DC);
|
||||
void fetch_simple_variable(znode *result, znode *varname, int bp TSRMLS_DC);
|
||||
void fetch_simple_variable_ex(znode *result, znode *varname, int bp, zend_uchar op TSRMLS_DC);
|
||||
void zend_do_indirect_references(znode *result, znode *num_references, znode *variable TSRMLS_DC);
|
||||
void zend_do_fetch_static_variable(znode *varname, znode *static_assignment, int fetch_type TSRMLS_DC);
|
||||
void zend_do_fetch_global_variable(znode *varname, znode *static_assignment, int fetch_type TSRMLS_DC);
|
||||
|
||||
void fetch_array_begin(znode *result, znode *varname, znode *first_dim TSRMLS_DC);
|
||||
void fetch_array_dim(znode *result, znode *parent, znode *dim TSRMLS_DC);
|
||||
void fetch_string_offset(znode *result, znode *parent, znode *offset TSRMLS_DC);
|
||||
void zend_do_fetch_static_member(znode *class_znode TSRMLS_DC);
|
||||
void zend_do_print(znode *result, znode *arg TSRMLS_DC);
|
||||
void zend_do_echo(znode *arg TSRMLS_DC);
|
||||
typedef int (*unary_op_type)(zval *, zval *);
|
||||
ZEND_API unary_op_type get_unary_op(int opcode);
|
||||
ZEND_API void *get_binary_op(int opcode);
|
||||
|
||||
void zend_do_while_cond(znode *expr, znode *close_bracket_token TSRMLS_DC);
|
||||
void zend_do_while_end(znode *while_token, znode *close_bracket_token TSRMLS_DC);
|
||||
void zend_do_do_while_begin(TSRMLS_D);
|
||||
void zend_do_do_while_end(znode *do_token, znode *expr_open_bracket, znode *expr TSRMLS_DC);
|
||||
|
||||
|
||||
void zend_do_if_cond(znode *cond, znode *closing_bracket_token TSRMLS_DC);
|
||||
void zend_do_if_after_statement(znode *closing_bracket_token, unsigned char initialize TSRMLS_DC);
|
||||
void zend_do_if_end(TSRMLS_D);
|
||||
|
||||
void zend_do_for_cond(znode *expr, znode *second_semicolon_token TSRMLS_DC);
|
||||
void zend_do_for_before_statement(znode *cond_start, znode *second_semicolon_token TSRMLS_DC);
|
||||
void zend_do_for_end(znode *second_semicolon_token TSRMLS_DC);
|
||||
|
||||
void zend_do_pre_incdec(znode *result, znode *op1, zend_uchar op TSRMLS_DC);
|
||||
void zend_do_post_incdec(znode *result, znode *op1, zend_uchar op TSRMLS_DC);
|
||||
|
||||
void zend_do_begin_variable_parse(TSRMLS_D);
|
||||
void zend_do_end_variable_parse(int type, int arg_offset TSRMLS_DC);
|
||||
|
||||
void zend_check_writable_variable(znode *variable);
|
||||
|
||||
void zend_do_free(znode *op1 TSRMLS_DC);
|
||||
|
||||
void zend_do_init_string(znode *result TSRMLS_DC);
|
||||
void zend_do_add_char(znode *result, znode *op1, znode *op2 TSRMLS_DC);
|
||||
void zend_do_add_string(znode *result, znode *op1, znode *op2 TSRMLS_DC);
|
||||
void zend_do_add_variable(znode *result, znode *op1, znode *op2 TSRMLS_DC);
|
||||
|
||||
int zend_do_verify_access_types(znode *current_access_type, znode *new_modifier);
|
||||
void zend_do_begin_function_declaration(znode *function_token, znode *function_name, int is_method, int return_reference, znode *fn_flags_znode TSRMLS_DC);
|
||||
void zend_do_end_function_declaration(znode *function_token TSRMLS_DC);
|
||||
void zend_do_receive_arg(zend_uchar op, znode *var, znode *offset, znode *initialization, znode *class_type, znode *varname, zend_bool pass_by_reference TSRMLS_DC);
|
||||
int zend_do_begin_function_call(znode *function_name TSRMLS_DC);
|
||||
void zend_do_begin_method_call(znode *left_bracket TSRMLS_DC);
|
||||
void zend_do_begin_dynamic_function_call(znode *function_name TSRMLS_DC);
|
||||
void zend_do_fetch_class(znode *result, znode *class_name TSRMLS_DC);
|
||||
void zend_do_fetch_class_name(znode *result, znode *class_entry, znode *class_name TSRMLS_DC);
|
||||
void zend_do_begin_class_member_function_call(TSRMLS_D);
|
||||
void zend_do_end_function_call(znode *function_name, znode *result, znode *argument_list, int is_method, int is_dynamic_fcall TSRMLS_DC);
|
||||
void zend_do_return(znode *expr, int do_end_vparse TSRMLS_DC);
|
||||
|
||||
void zend_do_try(znode *try_token TSRMLS_DC);
|
||||
void zend_do_begin_catch(znode *try_token, znode *catch_class, znode *catch_var, zend_bool first_catch TSRMLS_DC);
|
||||
void zend_do_end_catch(znode *try_token TSRMLS_DC);
|
||||
void zend_do_throw(znode *expr TSRMLS_DC);
|
||||
|
||||
ZEND_API int do_bind_function(zend_op *opline, HashTable *function_table, HashTable *class_table, int compile_time);
|
||||
ZEND_API zend_class_entry *do_bind_class(zend_op *opline, HashTable *function_table, HashTable *class_table TSRMLS_DC);
|
||||
ZEND_API zend_class_entry *do_bind_inherited_class(zend_op *opline, HashTable *function_table, HashTable *class_table, zend_class_entry *parent_ce TSRMLS_DC);
|
||||
ZEND_API void zend_do_inherit_interfaces(zend_class_entry *ce, zend_class_entry *iface TSRMLS_DC);
|
||||
ZEND_API void zend_do_implement_interface(zend_class_entry *ce, zend_class_entry *iface TSRMLS_DC);
|
||||
void zend_do_implements_interface(znode *interface_znode TSRMLS_DC);
|
||||
|
||||
void zend_do_inheritance(zend_class_entry *ce, zend_class_entry *parent_ce TSRMLS_DC);
|
||||
void zend_do_early_binding(TSRMLS_D);
|
||||
|
||||
void zend_do_pass_param(znode *param, zend_uchar op, int offset TSRMLS_DC);
|
||||
|
||||
|
||||
void zend_do_boolean_or_begin(znode *expr1, znode *op_token TSRMLS_DC);
|
||||
void zend_do_boolean_or_end(znode *result, znode *expr1, znode *expr2, znode *op_token TSRMLS_DC);
|
||||
void zend_do_boolean_and_begin(znode *expr1, znode *op_token TSRMLS_DC);
|
||||
void zend_do_boolean_and_end(znode *result, znode *expr1, znode *expr2, znode *op_token TSRMLS_DC);
|
||||
|
||||
void zend_do_brk_cont(zend_uchar op, znode *expr TSRMLS_DC);
|
||||
|
||||
void zend_do_switch_cond(znode *cond TSRMLS_DC);
|
||||
void zend_do_switch_end(znode *case_list TSRMLS_DC);
|
||||
void zend_do_case_before_statement(znode *case_list, znode *case_token, znode *case_expr TSRMLS_DC);
|
||||
void zend_do_case_after_statement(znode *result, znode *case_token TSRMLS_DC);
|
||||
void zend_do_default_before_statement(znode *case_list, znode *default_token TSRMLS_DC);
|
||||
|
||||
void zend_do_begin_class_declaration(znode *class_token, znode *class_name, znode *parent_class_name TSRMLS_DC);
|
||||
void zend_do_end_class_declaration(znode *class_token, znode *parent_token TSRMLS_DC);
|
||||
void zend_do_declare_property(znode *var_name, znode *value, zend_uint access_type TSRMLS_DC);
|
||||
void zend_do_declare_implicit_property(TSRMLS_D);
|
||||
void zend_do_declare_class_constant(znode *var_name, znode *value TSRMLS_DC);
|
||||
|
||||
void zend_do_fetch_property(znode *result, znode *object, znode *property TSRMLS_DC);
|
||||
|
||||
|
||||
void zend_do_push_object(znode *object TSRMLS_DC);
|
||||
void zend_do_pop_object(znode *object TSRMLS_DC);
|
||||
|
||||
|
||||
void zend_do_begin_new_object(znode *new_token, znode *class_type TSRMLS_DC);
|
||||
void zend_do_end_new_object(znode *result, znode *new_token, znode *argument_list TSRMLS_DC);
|
||||
|
||||
void zend_do_fetch_constant(znode *result, znode *constant_container, znode *constant_name, int mode TSRMLS_DC);
|
||||
|
||||
void zend_do_shell_exec(znode *result, znode *cmd TSRMLS_DC);
|
||||
|
||||
void zend_do_init_array(znode *result, znode *expr, znode *offset, zend_bool is_ref TSRMLS_DC);
|
||||
void zend_do_add_array_element(znode *result, znode *expr, znode *offset, zend_bool is_ref TSRMLS_DC);
|
||||
void zend_do_add_static_array_element(znode *result, znode *offset, znode *expr);
|
||||
void zend_do_list_init(TSRMLS_D);
|
||||
void zend_do_list_end(znode *result, znode *expr TSRMLS_DC);
|
||||
void zend_do_add_list_element(znode *element TSRMLS_DC);
|
||||
void zend_do_new_list_begin(TSRMLS_D);
|
||||
void zend_do_new_list_end(TSRMLS_D);
|
||||
|
||||
void zend_do_cast(znode *result, znode *expr, int type TSRMLS_DC);
|
||||
void zend_do_include_or_eval(int type, znode *result, znode *op1 TSRMLS_DC);
|
||||
|
||||
void zend_do_unset(znode *variable TSRMLS_DC);
|
||||
void zend_do_isset_or_isempty(int type, znode *result, znode *variable TSRMLS_DC);
|
||||
|
||||
void zend_do_instanceof(znode *result, znode *expr, znode *class_znode, int type TSRMLS_DC);
|
||||
|
||||
void zend_do_foreach_begin(znode *foreach_token, znode *array, znode *open_brackets_token, znode *as_token, int variable TSRMLS_DC);
|
||||
void zend_do_foreach_cont(znode *value, znode *key, znode *as_token, znode *foreach_token TSRMLS_DC);
|
||||
void zend_do_foreach_end(znode *foreach_token, znode *open_brackets_token TSRMLS_DC);
|
||||
|
||||
void zend_do_declare_begin(TSRMLS_D);
|
||||
void zend_do_declare_stmt(znode *var, znode *val TSRMLS_DC);
|
||||
void zend_do_declare_end(znode *declare_token TSRMLS_DC);
|
||||
|
||||
void zend_do_end_heredoc(TSRMLS_D);
|
||||
|
||||
void zend_do_exit(znode *result, znode *message TSRMLS_DC);
|
||||
|
||||
void zend_do_begin_silence(znode *strudel_token TSRMLS_DC);
|
||||
void zend_do_end_silence(znode *strudel_token TSRMLS_DC);
|
||||
|
||||
void zend_do_begin_qm_op(znode *cond, znode *qm_token TSRMLS_DC);
|
||||
void zend_do_qm_true(znode *true_value, znode *qm_token, znode *colon_token TSRMLS_DC);
|
||||
void zend_do_qm_false(znode *result, znode *false_value, znode *qm_token, znode *colon_token TSRMLS_DC);
|
||||
|
||||
void zend_do_extended_info(TSRMLS_D);
|
||||
void zend_do_extended_fcall_begin(TSRMLS_D);
|
||||
void zend_do_extended_fcall_end(TSRMLS_D);
|
||||
|
||||
void zend_do_ticks(TSRMLS_D);
|
||||
|
||||
void zend_do_abstract_method(znode *function_name, znode *modifiers, znode *body TSRMLS_DC);
|
||||
|
||||
ZEND_API void function_add_ref(zend_function *function);
|
||||
|
||||
#define INITIAL_OP_ARRAY_SIZE 64
|
||||
|
||||
|
||||
/* helper functions in zend_language_scanner.l */
|
||||
ZEND_API zend_op_array *compile_file(zend_file_handle *file_handle, int type TSRMLS_DC);
|
||||
ZEND_API zend_op_array *compile_string(zval *source_string, char *filename TSRMLS_DC);
|
||||
ZEND_API zend_op_array *compile_filename(int type, zval *filename TSRMLS_DC);
|
||||
ZEND_API int zend_execute_scripts(int type TSRMLS_DC, zval **retval, int file_count, ...);
|
||||
ZEND_API int open_file_for_scanning(zend_file_handle *file_handle TSRMLS_DC);
|
||||
ZEND_API void init_op_array(zend_op_array *op_array, zend_uchar type, int initial_ops_size TSRMLS_DC);
|
||||
ZEND_API void destroy_op_array(zend_op_array *op_array TSRMLS_DC);
|
||||
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 void destroy_zend_function(zend_function *function TSRMLS_DC);
|
||||
ZEND_API void destroy_zend_class(zend_class_entry **pce);
|
||||
void zend_class_add_ref(zend_class_entry **ce);
|
||||
|
||||
void mangle_property_name(char **dest, int *dest_length, char *src1, int src1_length, char *src2, int src2_length, int internal);
|
||||
void unmangle_property_name(char *mangled_property, char **prop_name, char **class_name);
|
||||
|
||||
#define ZEND_FUNCTION_DTOR (void (*)(void *)) destroy_zend_function
|
||||
#define ZEND_CLASS_DTOR (void (*)(void *)) destroy_zend_class
|
||||
|
||||
zend_op *get_next_op(zend_op_array *op_array TSRMLS_DC);
|
||||
void init_op(zend_op *op TSRMLS_DC);
|
||||
int get_next_op_number(zend_op_array *op_array);
|
||||
int print_class(zend_class_entry *class_entry TSRMLS_DC);
|
||||
void print_op_array(zend_op_array *op_array, int optimizations);
|
||||
int pass_two(zend_op_array *op_array TSRMLS_DC);
|
||||
zend_brk_cont_element *get_next_brk_cont_element(zend_op_array *op_array);
|
||||
ZEND_API zend_bool zend_is_compiling(TSRMLS_D);
|
||||
ZEND_API char *zend_make_compiled_string_description(char *name TSRMLS_DC);
|
||||
ZEND_API void zend_initialize_class_data(zend_class_entry *ce, zend_bool nullify_handlers TSRMLS_DC);
|
||||
int zend_get_class_fetch_type(char *class_name, uint class_name_len);
|
||||
|
||||
typedef zend_bool (*zend_auto_global_callback)(char *name, uint name_len TSRMLS_DC);
|
||||
typedef struct _zend_auto_global {
|
||||
char *name;
|
||||
uint name_len;
|
||||
zend_auto_global_callback auto_global_callback;
|
||||
zend_bool armed;
|
||||
} zend_auto_global;
|
||||
|
||||
void zend_auto_global_dtor(zend_auto_global *auto_global);
|
||||
ZEND_API int zend_register_auto_global(char *name, uint name_len, zend_auto_global_callback auto_global_callback TSRMLS_DC);
|
||||
ZEND_API zend_bool zend_is_auto_global(char *name, uint name_len TSRMLS_DC);
|
||||
|
||||
int zendlex(znode *zendlval TSRMLS_DC);
|
||||
|
||||
/* BEGIN: OPCODES */
|
||||
#define ZEND_NOP 0
|
||||
|
||||
#define ZEND_ADD 1
|
||||
#define ZEND_SUB 2
|
||||
#define ZEND_MUL 3
|
||||
#define ZEND_DIV 4
|
||||
#define ZEND_MOD 5
|
||||
#define ZEND_SL 6
|
||||
#define ZEND_SR 7
|
||||
#define ZEND_CONCAT 8
|
||||
#define ZEND_BW_OR 9
|
||||
#define ZEND_BW_AND 10
|
||||
#define ZEND_BW_XOR 11
|
||||
#define ZEND_BW_NOT 12
|
||||
#define ZEND_BOOL_NOT 13
|
||||
#define ZEND_BOOL_XOR 14
|
||||
#define ZEND_IS_IDENTICAL 15
|
||||
#define ZEND_IS_NOT_IDENTICAL 16
|
||||
#define ZEND_IS_EQUAL 17
|
||||
#define ZEND_IS_NOT_EQUAL 18
|
||||
#define ZEND_IS_SMALLER 19
|
||||
#define ZEND_IS_SMALLER_OR_EQUAL 20
|
||||
#define ZEND_CAST 21
|
||||
#define ZEND_QM_ASSIGN 22
|
||||
|
||||
#define ZEND_ASSIGN_ADD 23
|
||||
#define ZEND_ASSIGN_SUB 24
|
||||
#define ZEND_ASSIGN_MUL 25
|
||||
#define ZEND_ASSIGN_DIV 26
|
||||
#define ZEND_ASSIGN_MOD 27
|
||||
#define ZEND_ASSIGN_SL 28
|
||||
#define ZEND_ASSIGN_SR 29
|
||||
#define ZEND_ASSIGN_CONCAT 30
|
||||
#define ZEND_ASSIGN_BW_OR 31
|
||||
#define ZEND_ASSIGN_BW_AND 32
|
||||
#define ZEND_ASSIGN_BW_XOR 33
|
||||
|
||||
#define ZEND_PRE_INC 34
|
||||
#define ZEND_PRE_DEC 35
|
||||
#define ZEND_POST_INC 36
|
||||
#define ZEND_POST_DEC 37
|
||||
|
||||
#define ZEND_ASSIGN 38
|
||||
#define ZEND_ASSIGN_REF 39
|
||||
|
||||
#define ZEND_ECHO 40
|
||||
#define ZEND_PRINT 41
|
||||
|
||||
#define ZEND_JMP 42
|
||||
#define ZEND_JMPZ 43
|
||||
#define ZEND_JMPNZ 44
|
||||
#define ZEND_JMPZNZ 45
|
||||
#define ZEND_JMPZ_EX 46
|
||||
#define ZEND_JMPNZ_EX 47
|
||||
#define ZEND_CASE 48
|
||||
#define ZEND_SWITCH_FREE 49
|
||||
#define ZEND_BRK 50
|
||||
#define ZEND_CONT 51
|
||||
#define ZEND_BOOL 52
|
||||
|
||||
#define ZEND_INIT_STRING 53
|
||||
#define ZEND_ADD_CHAR 54
|
||||
#define ZEND_ADD_STRING 55
|
||||
#define ZEND_ADD_VAR 56
|
||||
|
||||
#define ZEND_BEGIN_SILENCE 57
|
||||
#define ZEND_END_SILENCE 58
|
||||
|
||||
#define ZEND_INIT_FCALL_BY_NAME 59
|
||||
#define ZEND_DO_FCALL 60
|
||||
#define ZEND_DO_FCALL_BY_NAME 61
|
||||
#define ZEND_RETURN 62
|
||||
|
||||
#define ZEND_RECV 63
|
||||
#define ZEND_RECV_INIT 64
|
||||
|
||||
#define ZEND_SEND_VAL 65
|
||||
#define ZEND_SEND_VAR 66
|
||||
#define ZEND_SEND_REF 67
|
||||
|
||||
#define ZEND_NEW 68
|
||||
#define ZEND_JMP_NO_CTOR 69
|
||||
#define ZEND_FREE 70
|
||||
|
||||
#define ZEND_INIT_ARRAY 71
|
||||
#define ZEND_ADD_ARRAY_ELEMENT 72
|
||||
|
||||
#define ZEND_INCLUDE_OR_EVAL 73
|
||||
|
||||
#define ZEND_UNSET_VAR 74
|
||||
#define ZEND_UNSET_DIM_OBJ 75
|
||||
|
||||
#define ZEND_FE_RESET 77
|
||||
#define ZEND_FE_FETCH 78
|
||||
|
||||
#define ZEND_EXIT 79
|
||||
|
||||
|
||||
/* the following 18 opcodes are 6 groups of 3 opcodes each, and must
|
||||
* remain in that order!
|
||||
*/
|
||||
#define ZEND_FETCH_R 80
|
||||
#define ZEND_FETCH_DIM_R 81
|
||||
#define ZEND_FETCH_OBJ_R 82
|
||||
#define ZEND_FETCH_W 83
|
||||
#define ZEND_FETCH_DIM_W 84
|
||||
#define ZEND_FETCH_OBJ_W 85
|
||||
#define ZEND_FETCH_RW 86
|
||||
#define ZEND_FETCH_DIM_RW 87
|
||||
#define ZEND_FETCH_OBJ_RW 88
|
||||
#define ZEND_FETCH_IS 89
|
||||
#define ZEND_FETCH_DIM_IS 90
|
||||
#define ZEND_FETCH_OBJ_IS 91
|
||||
#define ZEND_FETCH_FUNC_ARG 92
|
||||
#define ZEND_FETCH_DIM_FUNC_ARG 93
|
||||
#define ZEND_FETCH_OBJ_FUNC_ARG 94
|
||||
#define ZEND_FETCH_UNSET 95
|
||||
#define ZEND_FETCH_DIM_UNSET 96
|
||||
#define ZEND_FETCH_OBJ_UNSET 97
|
||||
|
||||
#define ZEND_FETCH_DIM_TMP_VAR 98
|
||||
#define ZEND_FETCH_CONSTANT 99
|
||||
|
||||
/* Hole - 100 */
|
||||
|
||||
#define ZEND_EXT_STMT 101
|
||||
#define ZEND_EXT_FCALL_BEGIN 102
|
||||
#define ZEND_EXT_FCALL_END 103
|
||||
#define ZEND_EXT_NOP 104
|
||||
|
||||
#define ZEND_TICKS 105
|
||||
|
||||
#define ZEND_SEND_VAR_NO_REF 106
|
||||
|
||||
#define ZEND_CATCH 107
|
||||
#define ZEND_THROW 108
|
||||
|
||||
#define ZEND_FETCH_CLASS 109
|
||||
|
||||
#define ZEND_CLONE 110
|
||||
|
||||
#define ZEND_INIT_CTOR_CALL 111
|
||||
#define ZEND_INIT_METHOD_CALL 112
|
||||
#define ZEND_INIT_STATIC_METHOD_CALL 113
|
||||
|
||||
#define ZEND_ISSET_ISEMPTY_VAR 114
|
||||
#define ZEND_ISSET_ISEMPTY_DIM_OBJ 115
|
||||
|
||||
#define ZEND_IMPORT_FUNCTION 116
|
||||
#define ZEND_IMPORT_CLASS 117
|
||||
#define ZEND_IMPORT_CONST 118
|
||||
|
||||
#define ZEND_PRE_INC_OBJ 132
|
||||
#define ZEND_PRE_DEC_OBJ 133
|
||||
#define ZEND_POST_INC_OBJ 134
|
||||
#define ZEND_POST_DEC_OBJ 135
|
||||
|
||||
#define ZEND_ASSIGN_OBJ 136
|
||||
#define ZEND_OP_DATA 137
|
||||
|
||||
#define ZEND_INSTANCEOF 138
|
||||
|
||||
#define ZEND_DECLARE_CLASS 139
|
||||
#define ZEND_DECLARE_INHERITED_CLASS 140
|
||||
#define ZEND_DECLARE_FUNCTION 141
|
||||
|
||||
#define ZEND_RAISE_ABSTRACT_ERROR 142
|
||||
|
||||
|
||||
|
||||
#define ZEND_ADD_INTERFACE 144
|
||||
#define ZEND_VERIFY_ABSTRACT_CLASS 146
|
||||
|
||||
#define ZEND_ASSIGN_DIM 147
|
||||
|
||||
#define ZEND_ISSET_ISEMPTY_PROP_OBJ 148
|
||||
|
||||
/* end of block */
|
||||
/* END: OPCODES */
|
||||
|
||||
|
||||
|
||||
|
||||
/* global/local fetches */
|
||||
#define ZEND_FETCH_GLOBAL 0
|
||||
#define ZEND_FETCH_LOCAL 1
|
||||
#define ZEND_FETCH_STATIC 2
|
||||
#define ZEND_FETCH_STATIC_MEMBER 3
|
||||
|
||||
|
||||
/* obj/dim unsets */
|
||||
#define ZEND_UNSET_DIM 1
|
||||
#define ZEND_UNSET_OBJ 2
|
||||
|
||||
/* class fetches */
|
||||
#define ZEND_FETCH_CLASS_DEFAULT 0
|
||||
#define ZEND_FETCH_CLASS_SELF 1
|
||||
#define ZEND_FETCH_CLASS_PARENT 2
|
||||
#define ZEND_FETCH_CLASS_MAIN 3
|
||||
#define ZEND_FETCH_CLASS_GLOBAL 4
|
||||
#define ZEND_FETCH_CLASS_AUTO 5
|
||||
|
||||
|
||||
/* variable parsing type (compile-time) */
|
||||
#define ZEND_PARSED_MEMBER (1<<0)
|
||||
#define ZEND_PARSED_METHOD_CALL (1<<1)
|
||||
#define ZEND_PARSED_STATIC_MEMBER (1<<2)
|
||||
#define ZEND_PARSED_FUNCTION_CALL (1<<3)
|
||||
#define ZEND_PARSED_VARIABLE (1<<4)
|
||||
#define ZEND_PARSED_REFERENCE_VARIABLE (1<<5)
|
||||
|
||||
|
||||
/* unset types */
|
||||
#define ZEND_UNSET_REG 0
|
||||
|
||||
/* var status for backpatching */
|
||||
#define BP_VAR_R 0
|
||||
#define BP_VAR_W 1
|
||||
#define BP_VAR_RW 2
|
||||
#define BP_VAR_IS 3
|
||||
#define BP_VAR_NA 4 /* if not applicable */
|
||||
#define BP_VAR_FUNC_ARG 5
|
||||
#define BP_VAR_UNSET 6
|
||||
|
||||
|
||||
#define ZEND_INTERNAL_FUNCTION 1
|
||||
#define ZEND_USER_FUNCTION 2
|
||||
#define ZEND_OVERLOADED_FUNCTION 3
|
||||
#define ZEND_EVAL_CODE 4
|
||||
#define ZEND_OVERLOADED_FUNCTION_TEMPORARY 5
|
||||
|
||||
#define ZEND_INTERNAL_CLASS 1
|
||||
#define ZEND_USER_CLASS 2
|
||||
|
||||
#define ZEND_EVAL (1<<0)
|
||||
#define ZEND_INCLUDE (1<<1)
|
||||
#define ZEND_INCLUDE_ONCE (1<<2)
|
||||
#define ZEND_REQUIRE (1<<3)
|
||||
#define ZEND_REQUIRE_ONCE (1<<4)
|
||||
|
||||
#define ZEND_ISSET (1<<0)
|
||||
#define ZEND_ISEMPTY (1<<1)
|
||||
|
||||
#define ZEND_CT (1<<0)
|
||||
#define ZEND_RT (1<<1)
|
||||
|
||||
|
||||
#define ZEND_HANDLE_FILENAME 0
|
||||
#define ZEND_HANDLE_FD 1
|
||||
#define ZEND_HANDLE_FP 2
|
||||
#define ZEND_HANDLE_STDIOSTREAM 3
|
||||
#define ZEND_HANDLE_FSTREAM 4
|
||||
#define ZEND_HANDLE_STREAM 5
|
||||
|
||||
#define ZEND_FETCH_STANDARD 0
|
||||
#define ZEND_FETCH_ADD_LOCK 1
|
||||
|
||||
#define ZEND_MEMBER_FUNC_CALL 1<<0
|
||||
|
||||
#define ZEND_ARG_SEND_BY_REF (1<<0)
|
||||
#define ZEND_ARG_COMPILE_TIME_BOUND (1<<1)
|
||||
|
||||
#define AI_USE_PTR(ai) \
|
||||
if ((ai).ptr_ptr) { \
|
||||
(ai).ptr = *((ai).ptr_ptr); \
|
||||
(ai).ptr_ptr = &((ai).ptr); \
|
||||
} else { \
|
||||
(ai).ptr = NULL; \
|
||||
}
|
||||
|
||||
/* Lost In Stupid Parentheses */
|
||||
#define ARG_SHOULD_BE_SENT_BY_REF(zf, arg_num) \
|
||||
( \
|
||||
zf \
|
||||
&& ((zend_function *) zf)->common.arg_info \
|
||||
&& \
|
||||
( \
|
||||
( \
|
||||
arg_num<=((zend_function *) zf)->common.num_args \
|
||||
&& ((zend_function *) zf)->common.arg_info[arg_num-1].pass_by_reference \
|
||||
) \
|
||||
|| ( \
|
||||
arg_num>((zend_function *) zf)->common.num_args \
|
||||
&& ((zend_function *) zf)->common.pass_rest_by_reference \
|
||||
) \
|
||||
) \
|
||||
)
|
||||
|
||||
|
||||
#define ZEND_RETURN_VAL 0
|
||||
#define ZEND_RETURN_REF 1
|
||||
|
||||
|
||||
#define ZEND_RETURNS_FUNCTION 1<<0
|
||||
|
||||
END_EXTERN_C()
|
||||
|
||||
#define ZEND_CLONE_FUNC_NAME "__clone"
|
||||
#define ZEND_CONSTRUCTOR_FUNC_NAME "__construct"
|
||||
#define ZEND_DESTRUCTOR_FUNC_NAME "__destruct"
|
||||
#define ZEND_GET_FUNC_NAME "__get"
|
||||
#define ZEND_SET_FUNC_NAME "__set"
|
||||
#define ZEND_CALL_FUNC_NAME "__call"
|
||||
|
||||
#endif /* ZEND_COMPILE_H */
|
||||
|
||||
/*
|
||||
* Local variables:
|
||||
* tab-width: 4
|
||||
* c-basic-offset: 4
|
||||
* indent-tabs-mode: t
|
||||
* End:
|
||||
*/
|
||||
@@ -1,88 +0,0 @@
|
||||
/*
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2003 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 |
|
||||
| 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 |
|
||||
| obtain it through the world-wide-web, please send a note to |
|
||||
| license@zend.com so we can mail you a copy immediately. |
|
||||
+----------------------------------------------------------------------+
|
||||
| Authors: Andi Gutmans <andi@zend.com> |
|
||||
| Zeev Suraski <zeev@zend.com> |
|
||||
+----------------------------------------------------------------------+
|
||||
*/
|
||||
|
||||
/* $Id$ */
|
||||
|
||||
#ifndef ZEND_CONFIG_NW_H
|
||||
#define ZEND_CONFIG_NW_H
|
||||
|
||||
|
||||
#include <string.h>
|
||||
#include <float.h>
|
||||
|
||||
typedef unsigned long ulong;
|
||||
typedef unsigned int uint;
|
||||
|
||||
#define HAVE_ALLOCA 1
|
||||
#define HAVE_LIMITS_H 1
|
||||
/* #include <malloc.h> */
|
||||
|
||||
#define HAVE_STRING_H 1
|
||||
|
||||
#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_DLFCN_H 1
|
||||
/* #define HAVE_LIBDL 1 */
|
||||
#define HAVE_SNPRINTF 1
|
||||
#define HAVE_VSNPRINTF 1
|
||||
|
||||
/*
|
||||
#define snprintf _snprintf
|
||||
#define vsnprintf _vsnprintf
|
||||
#define zend_isinf(a) 0
|
||||
#define zend_finite(x) _finite(x)
|
||||
#define zend_isnan(x) _isnan(x)
|
||||
*/
|
||||
|
||||
#define zend_sprintf sprintf
|
||||
|
||||
/* This will cause the compilation process to be MUCH longer, but will generate
|
||||
* a much quicker PHP binary
|
||||
*/
|
||||
/*
|
||||
#undef inline
|
||||
#ifdef ZEND_WIN32_FORCE_INLINE
|
||||
# define inline __forceinline
|
||||
#else
|
||||
# define inline
|
||||
#endif
|
||||
*/
|
||||
|
||||
/*
|
||||
#define zend_finite(A) _finite(A)
|
||||
#define zend_isnan(A) _isnan(A)
|
||||
*/
|
||||
|
||||
#endif /* ZEND_CONFIG_NW_H */
|
||||
|
||||
/*
|
||||
* Local variables:
|
||||
* tab-width: 4
|
||||
* c-basic-offset: 4
|
||||
* indent-tabs-mode: t
|
||||
* End:
|
||||
*/
|
||||
@@ -1,107 +0,0 @@
|
||||
/*
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2003 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 |
|
||||
| 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 |
|
||||
| obtain it through the world-wide-web, please send a note to |
|
||||
| license@zend.com so we can mail you a copy immediately. |
|
||||
+----------------------------------------------------------------------+
|
||||
| Authors: Andi Gutmans <andi@zend.com> |
|
||||
| Zeev Suraski <zeev@zend.com> |
|
||||
+----------------------------------------------------------------------+
|
||||
*/
|
||||
|
||||
/* $Id$ */
|
||||
|
||||
#ifndef ZEND_CONFIG_W32_H
|
||||
#define ZEND_CONFIG_W32_H
|
||||
|
||||
#define HAVE_ALLOCA 1
|
||||
#define HAVE_LIMITS_H 1
|
||||
#define _CRTDBG_MAP_ALLOC
|
||||
|
||||
#include <malloc.h>
|
||||
#include <stdlib.h>
|
||||
#include <crtdbg.h>
|
||||
|
||||
#include <string.h>
|
||||
|
||||
#ifndef ZEND_INCLUDE_FULL_WINDOWS_HEADERS
|
||||
#define WIN32_LEAN_AND_MEAN
|
||||
#endif
|
||||
#include <winsock2.h>
|
||||
#include <windows.h>
|
||||
|
||||
#include <float.h>
|
||||
|
||||
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 snprintf _snprintf
|
||||
#define vsnprintf _vsnprintf
|
||||
#define strcasecmp(s1, s2) stricmp(s1, s2)
|
||||
#define strncasecmp(s1, s2, n) strnicmp(s1, s2, n)
|
||||
#define zend_isinf(a) ((_fpclass(a) == _FPCLASS_PINF) || (_fpclass(a) == _FPCLASS_NINF))
|
||||
#define zend_finite(x) _finite(x)
|
||||
#define zend_isnan(x) _isnan(x)
|
||||
|
||||
#define zend_sprintf sprintf
|
||||
|
||||
/* This will cause the compilation process to be MUCH longer, but will generate
|
||||
* a much quicker PHP binary
|
||||
*/
|
||||
#undef inline
|
||||
#ifdef ZEND_WIN32_FORCE_INLINE
|
||||
# define inline __forceinline
|
||||
#else
|
||||
# define inline
|
||||
#endif
|
||||
|
||||
#ifdef LIBZEND_EXPORTS
|
||||
# define ZEND_API __declspec(dllexport)
|
||||
#else
|
||||
# define ZEND_API __declspec(dllimport)
|
||||
#endif
|
||||
|
||||
#define ZEND_DLEXPORT __declspec(dllexport)
|
||||
#define ZEND_DLIMPORT __declspec(dllimport)
|
||||
|
||||
/* 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
|
||||
*/
|
||||
#ifndef MB_SERVICE_NOTIFICATION
|
||||
#define MB_SERVICE_NOTIFICATION 0x00200000L
|
||||
#endif
|
||||
|
||||
#define ZEND_SERVICE_MB_STYLE (MB_TOPMOST|MB_SERVICE_NOTIFICATION)
|
||||
|
||||
#endif /* ZEND_CONFIG_W32_H */
|
||||
|
||||
/*
|
||||
* Local variables:
|
||||
* tab-width: 4
|
||||
* c-basic-offset: 4
|
||||
* indent-tabs-mode: t
|
||||
* End:
|
||||
*/
|
||||
@@ -1,340 +0,0 @@
|
||||
/*
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2003 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 |
|
||||
| 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 |
|
||||
| obtain it through the world-wide-web, please send a note to |
|
||||
| license@zend.com so we can mail you a copy immediately. |
|
||||
+----------------------------------------------------------------------+
|
||||
| Authors: Andi Gutmans <andi@zend.com> |
|
||||
| Zeev Suraski <zeev@zend.com> |
|
||||
+----------------------------------------------------------------------+
|
||||
*/
|
||||
|
||||
/* $Id$ */
|
||||
|
||||
#include "zend.h"
|
||||
#include "zend_constants.h"
|
||||
#include "zend_execute.h"
|
||||
#include "zend_variables.h"
|
||||
#include "zend_operators.h"
|
||||
#include "zend_globals.h"
|
||||
|
||||
|
||||
void free_zend_constant(zend_constant *c)
|
||||
{
|
||||
if (!(c->flags & CONST_PERSISTENT)) {
|
||||
zval_dtor(&c->value);
|
||||
}
|
||||
free(c->name);
|
||||
}
|
||||
|
||||
|
||||
void copy_zend_constant(zend_constant *c)
|
||||
{
|
||||
c->name = zend_strndup(c->name, c->name_len - 1);
|
||||
if (!(c->flags & CONST_PERSISTENT)) {
|
||||
zval_copy_ctor(&c->value);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void zend_copy_constants(HashTable *target, HashTable *source)
|
||||
{
|
||||
zend_constant tmp_constant;
|
||||
|
||||
zend_hash_copy(target, source, (copy_ctor_func_t) copy_zend_constant, &tmp_constant, sizeof(zend_constant));
|
||||
}
|
||||
|
||||
|
||||
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;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
static int clean_module_constant(zend_constant *c, int *module_number TSRMLS_DC)
|
||||
{
|
||||
if (c->module_number == *module_number) {
|
||||
return 1;
|
||||
} else {
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void clean_module_constants(int module_number TSRMLS_DC)
|
||||
{
|
||||
zend_hash_apply_with_argument(EG(zend_constants), (apply_func_arg_t) clean_module_constant, (void *) &module_number TSRMLS_CC);
|
||||
}
|
||||
|
||||
|
||||
int zend_startup_constants(TSRMLS_D)
|
||||
{
|
||||
EG(zend_constants) = (HashTable *) malloc(sizeof(HashTable));
|
||||
|
||||
if (zend_hash_init(EG(zend_constants), 20, NULL, ZEND_CONSTANT_DTOR, 1)==FAILURE) {
|
||||
return FAILURE;
|
||||
}
|
||||
return SUCCESS;
|
||||
}
|
||||
|
||||
|
||||
|
||||
void zend_register_standard_constants(TSRMLS_D)
|
||||
{
|
||||
REGISTER_MAIN_LONG_CONSTANT("E_ERROR", E_ERROR, CONST_PERSISTENT | CONST_CS);
|
||||
REGISTER_MAIN_LONG_CONSTANT("E_WARNING", E_WARNING, CONST_PERSISTENT | CONST_CS);
|
||||
REGISTER_MAIN_LONG_CONSTANT("E_PARSE", E_PARSE, CONST_PERSISTENT | CONST_CS);
|
||||
REGISTER_MAIN_LONG_CONSTANT("E_NOTICE", E_NOTICE, CONST_PERSISTENT | CONST_CS);
|
||||
REGISTER_MAIN_LONG_CONSTANT("E_STRICT", E_STRICT, CONST_PERSISTENT | CONST_CS);
|
||||
REGISTER_MAIN_LONG_CONSTANT("E_CORE_ERROR", E_CORE_ERROR, CONST_PERSISTENT | CONST_CS);
|
||||
REGISTER_MAIN_LONG_CONSTANT("E_CORE_WARNING", E_CORE_WARNING, CONST_PERSISTENT | CONST_CS);
|
||||
REGISTER_MAIN_LONG_CONSTANT("E_COMPILE_ERROR", E_COMPILE_ERROR, CONST_PERSISTENT | CONST_CS);
|
||||
REGISTER_MAIN_LONG_CONSTANT("E_COMPILE_WARNING", E_COMPILE_WARNING, CONST_PERSISTENT | CONST_CS);
|
||||
REGISTER_MAIN_LONG_CONSTANT("E_USER_ERROR", E_USER_ERROR, CONST_PERSISTENT | CONST_CS);
|
||||
REGISTER_MAIN_LONG_CONSTANT("E_USER_WARNING", E_USER_WARNING, CONST_PERSISTENT | CONST_CS);
|
||||
REGISTER_MAIN_LONG_CONSTANT("E_USER_NOTICE", E_USER_NOTICE, CONST_PERSISTENT | CONST_CS);
|
||||
|
||||
REGISTER_MAIN_LONG_CONSTANT("E_ALL", E_ALL, CONST_PERSISTENT | CONST_CS);
|
||||
|
||||
/* true/false constants */
|
||||
{
|
||||
zend_constant c;
|
||||
|
||||
c.value.type = IS_BOOL;
|
||||
c.flags = CONST_PERSISTENT;
|
||||
c.module_number = 0;
|
||||
|
||||
c.name = zend_strndup(ZEND_STRS("TRUE"));
|
||||
c.name_len = sizeof("TRUE");
|
||||
c.value.value.lval = 1;
|
||||
c.value.type = IS_BOOL;
|
||||
zend_register_constant(&c TSRMLS_CC);
|
||||
|
||||
c.name = zend_strndup(ZEND_STRS("FALSE"));
|
||||
c.name_len = sizeof("FALSE");
|
||||
c.value.value.lval = 0;
|
||||
c.value.type = IS_BOOL;
|
||||
zend_register_constant(&c TSRMLS_CC);
|
||||
|
||||
c.name = zend_strndup(ZEND_STRS("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_STRS("NULL"));
|
||||
c.name_len = sizeof("NULL");
|
||||
c.value.type = IS_NULL;
|
||||
zend_register_constant(&c TSRMLS_CC);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
int zend_shutdown_constants(TSRMLS_D)
|
||||
{
|
||||
zend_hash_destroy(EG(zend_constants));
|
||||
free(EG(zend_constants));
|
||||
return SUCCESS;
|
||||
}
|
||||
|
||||
|
||||
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);
|
||||
} else {
|
||||
zend_hash_reverse_apply(EG(zend_constants), (apply_func_t) clean_non_persistent_constant TSRMLS_CC);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
ZEND_API void zend_register_long_constant(char *name, uint name_len, long lval, int flags, int module_number TSRMLS_DC)
|
||||
{
|
||||
zend_constant c;
|
||||
|
||||
c.value.type = IS_LONG;
|
||||
c.value.value.lval = lval;
|
||||
c.flags = flags;
|
||||
c.name = zend_strndup(name, name_len-1);
|
||||
c.name_len = name_len;
|
||||
c.module_number = module_number;
|
||||
zend_register_constant(&c TSRMLS_CC);
|
||||
}
|
||||
|
||||
|
||||
ZEND_API void zend_register_double_constant(char *name, uint name_len, double dval, int flags, int module_number TSRMLS_DC)
|
||||
{
|
||||
zend_constant c;
|
||||
|
||||
c.value.type = IS_DOUBLE;
|
||||
c.value.value.dval = dval;
|
||||
c.flags = flags;
|
||||
c.name = zend_strndup(name, name_len-1);
|
||||
c.name_len = name_len;
|
||||
c.module_number = module_number;
|
||||
zend_register_constant(&c TSRMLS_CC);
|
||||
}
|
||||
|
||||
|
||||
ZEND_API void zend_register_stringl_constant(char *name, uint name_len, char *strval, uint strlen, int flags, int module_number TSRMLS_DC)
|
||||
{
|
||||
zend_constant c;
|
||||
|
||||
c.value.type = IS_STRING;
|
||||
c.value.value.str.val = strval;
|
||||
c.value.value.str.len = strlen;
|
||||
c.flags = flags;
|
||||
c.name = zend_strndup(name, name_len-1);
|
||||
c.name_len = name_len;
|
||||
c.module_number = module_number;
|
||||
zend_register_constant(&c TSRMLS_CC);
|
||||
}
|
||||
|
||||
|
||||
ZEND_API void zend_register_string_constant(char *name, uint name_len, char *strval, int flags, int module_number TSRMLS_DC)
|
||||
{
|
||||
zend_register_stringl_constant(name, name_len, strval, strlen(strval), flags, module_number TSRMLS_CC);
|
||||
}
|
||||
|
||||
|
||||
ZEND_API int zend_get_constant(char *name, uint name_len, zval *result TSRMLS_DC)
|
||||
{
|
||||
zend_constant *c;
|
||||
int retval = 1;
|
||||
char *lookup_name;
|
||||
char *colon;
|
||||
|
||||
if ((colon = memchr(name, ':', name_len)) && colon[1] == ':') {
|
||||
/* class constant */
|
||||
zend_class_entry **ce = NULL, *scope;
|
||||
int class_name_len = colon-name;
|
||||
int const_name_len = name_len - class_name_len - 2;
|
||||
char *constant_name = colon+2;
|
||||
zval **ret_constant;
|
||||
char *class_name;
|
||||
|
||||
if (EG(in_execution)) {
|
||||
scope = EG(scope);
|
||||
} else {
|
||||
scope = CG(active_class_entry);
|
||||
}
|
||||
|
||||
class_name = do_alloca(class_name_len+1);
|
||||
memcpy(class_name, name, class_name_len);
|
||||
class_name[class_name_len] = '\0';
|
||||
|
||||
if (class_name_len == sizeof("self")-1 && strcmp(class_name, "self") == 0) {
|
||||
if (scope) {
|
||||
ce = &scope;
|
||||
} else {
|
||||
zend_error(E_ERROR, "Cannot access self:: when no class scope is active");
|
||||
retval = 0;
|
||||
}
|
||||
} else if (class_name_len == sizeof("parent")-1 && strcmp(class_name, "parent") == 0) {
|
||||
if (!scope) {
|
||||
zend_error(E_ERROR, "Cannot access parent:: when no class scope is active");
|
||||
} else if (!scope->parent) {
|
||||
zend_error(E_ERROR, "Cannot access parent:: when current class scope has no parent");
|
||||
} else {
|
||||
ce = &scope->parent;
|
||||
}
|
||||
} else {
|
||||
if (zend_lookup_class(class_name, class_name_len, &ce TSRMLS_CC) != SUCCESS) {
|
||||
retval = 0;
|
||||
}
|
||||
}
|
||||
free_alloca(class_name);
|
||||
|
||||
if (retval && ce) {
|
||||
if (zend_hash_find(&((*ce)->constants_table), constant_name, const_name_len+1, (void **) &ret_constant) != SUCCESS) {
|
||||
retval = 0;
|
||||
}
|
||||
} else {
|
||||
retval = 0;
|
||||
}
|
||||
|
||||
if (retval) {
|
||||
*result = **ret_constant;
|
||||
zval_copy_ctor(result);
|
||||
}
|
||||
|
||||
return retval;
|
||||
}
|
||||
|
||||
if (zend_hash_find(EG(zend_constants), name, name_len+1, (void **) &c) == FAILURE) {
|
||||
lookup_name = do_alloca(name_len+1);
|
||||
zend_str_tolower_copy(lookup_name, name, name_len);
|
||||
lookup_name[name_len] = '\0';
|
||||
|
||||
if (zend_hash_find(EG(zend_constants), lookup_name, name_len+1, (void **) &c)==SUCCESS) {
|
||||
if ((c->flags & CONST_CS) && memcmp(c->name, name, name_len)!=0) {
|
||||
retval=0;
|
||||
}
|
||||
} else {
|
||||
retval=0;
|
||||
}
|
||||
free_alloca(lookup_name);
|
||||
}
|
||||
|
||||
if (retval) {
|
||||
*result = c->value;
|
||||
zval_copy_ctor(result);
|
||||
result->refcount = 1;
|
||||
result->is_ref = 0;
|
||||
}
|
||||
|
||||
return retval;
|
||||
}
|
||||
|
||||
|
||||
ZEND_API int zend_register_constant(zend_constant *c TSRMLS_DC)
|
||||
{
|
||||
char *lowercase_name;
|
||||
int ret = SUCCESS;
|
||||
|
||||
#if 0
|
||||
printf("Registering constant for module %d\n", c->module_number);
|
||||
#endif
|
||||
|
||||
if (!(c->flags & CONST_CS)) {
|
||||
/* keep in mind that c->name_len already contains the '\0' */
|
||||
lowercase_name = do_alloca(c->name_len);
|
||||
zend_str_tolower_copy(lowercase_name, c->name, c->name_len - 1);
|
||||
} else {
|
||||
lowercase_name = do_alloca(c->name_len + 1);
|
||||
memcpy(lowercase_name, c->name, c->name_len);
|
||||
lowercase_name[c->name_len] = '\0';
|
||||
}
|
||||
|
||||
if (zend_hash_add(EG(zend_constants), lowercase_name, c->name_len, (void *) c, sizeof(zend_constant), NULL)==FAILURE) {
|
||||
free(c->name);
|
||||
if (!(c->flags & CONST_PERSISTENT)) {
|
||||
zval_dtor(&c->value);
|
||||
}
|
||||
zend_error(E_NOTICE,"Constant %s already defined", lowercase_name);
|
||||
ret = FAILURE;
|
||||
}
|
||||
free_alloca(lowercase_name);
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
* Local variables:
|
||||
* tab-width: 4
|
||||
* c-basic-offset: 4
|
||||
* indent-tabs-mode: t
|
||||
* End:
|
||||
*/
|
||||
@@ -1,77 +0,0 @@
|
||||
/*
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2003 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 |
|
||||
| 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 |
|
||||
| obtain it through the world-wide-web, please send a note to |
|
||||
| license@zend.com so we can mail you a copy immediately. |
|
||||
+----------------------------------------------------------------------+
|
||||
| Authors: Andi Gutmans <andi@zend.com> |
|
||||
| Zeev Suraski <zeev@zend.com> |
|
||||
+----------------------------------------------------------------------+
|
||||
*/
|
||||
|
||||
/* $Id$ */
|
||||
|
||||
#ifndef ZEND_CONSTANTS_H
|
||||
#define ZEND_CONSTANTS_H
|
||||
|
||||
#include "zend_globals.h"
|
||||
|
||||
#define CONST_CS (1<<0) /* Case Sensitive */
|
||||
#define CONST_PERSISTENT (1<<1) /* Persistent */
|
||||
|
||||
#define PHP_USER_CONSTANT LONG_MAX /* a constant defined in user space */
|
||||
|
||||
typedef struct _zend_constant {
|
||||
zval value;
|
||||
int flags;
|
||||
char *name;
|
||||
uint name_len;
|
||||
int module_number;
|
||||
} zend_constant;
|
||||
|
||||
#define REGISTER_LONG_CONSTANT(name, lval, flags) zend_register_long_constant((name), sizeof(name), (lval), (flags), module_number TSRMLS_CC)
|
||||
#define REGISTER_DOUBLE_CONSTANT(name, dval, flags) zend_register_double_constant((name), sizeof(name), (dval), (flags), module_number TSRMLS_CC)
|
||||
#define REGISTER_STRING_CONSTANT(name, str, flags) zend_register_string_constant((name), sizeof(name), (str), (flags), module_number TSRMLS_CC)
|
||||
#define REGISTER_STRINGL_CONSTANT(name, str, len, flags) zend_register_stringl_constant((name), sizeof(name), (str), (len), (flags), module_number TSRMLS_CC)
|
||||
|
||||
#define REGISTER_MAIN_LONG_CONSTANT(name, lval, flags) zend_register_long_constant((name), sizeof(name), (lval), (flags), 0 TSRMLS_CC)
|
||||
#define REGISTER_MAIN_DOUBLE_CONSTANT(name, dval, flags) zend_register_double_constant((name), sizeof(name), (dval), (flags), 0 TSRMLS_CC)
|
||||
#define REGISTER_MAIN_STRING_CONSTANT(name, str, flags) zend_register_string_constant((name), sizeof(name), (str), (flags), 0 TSRMLS_CC)
|
||||
#define REGISTER_MAIN_STRINGL_CONSTANT(name, str, len, flags) zend_register_stringl_constant((name), sizeof(name), (str), (len), (flags), 0 TSRMLS_CC)
|
||||
|
||||
BEGIN_EXTERN_C()
|
||||
void clean_module_constants(int module_number TSRMLS_DC);
|
||||
void free_zend_constant(zend_constant *c);
|
||||
int zend_startup_constants(TSRMLS_D);
|
||||
int zend_shutdown_constants(TSRMLS_D);
|
||||
void zend_register_standard_constants(TSRMLS_D);
|
||||
void clean_non_persistent_constants(TSRMLS_D);
|
||||
ZEND_API int zend_get_constant(char *name, uint name_len, zval *result TSRMLS_DC);
|
||||
ZEND_API void zend_register_long_constant(char *name, uint name_len, long lval, int flags, int module_number TSRMLS_DC);
|
||||
ZEND_API void zend_register_double_constant(char *name, uint name_len, double dval, int flags, int module_number TSRMLS_DC);
|
||||
ZEND_API void zend_register_string_constant(char *name, uint name_len, char *strval, int flags, int module_number TSRMLS_DC);
|
||||
ZEND_API void zend_register_stringl_constant(char *name, uint name_len, char *strval, uint strlen, int flags, int module_number TSRMLS_DC);
|
||||
ZEND_API int zend_register_constant(zend_constant *c TSRMLS_DC);
|
||||
void zend_copy_constants(HashTable *target, HashTable *sourc);
|
||||
void copy_zend_constant(zend_constant *c);
|
||||
END_EXTERN_C();
|
||||
|
||||
#define ZEND_CONSTANT_DTOR (void (*)(void *)) free_zend_constant
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
* Local variables:
|
||||
* tab-width: 4
|
||||
* c-basic-offset: 4
|
||||
* indent-tabs-mode: t
|
||||
* End:
|
||||
*/
|
||||
@@ -1,531 +0,0 @@
|
||||
/*
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2003 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 |
|
||||
| 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 |
|
||||
| obtain it through the world-wide-web, please send a note to |
|
||||
| license@zend.com so we can mail you a copy immediately. |
|
||||
+----------------------------------------------------------------------+
|
||||
| Authors: Sterling Hughes <sterling@php.net> |
|
||||
| Marcus Boerger <helly@php.net> |
|
||||
+----------------------------------------------------------------------+
|
||||
*/
|
||||
|
||||
/* $Id$ */
|
||||
|
||||
#include "zend.h"
|
||||
#include "zend_API.h"
|
||||
#include "zend_reflection_api.h"
|
||||
#include "zend_builtin_functions.h"
|
||||
#include "zend_interfaces.h"
|
||||
|
||||
static zend_class_entry *default_exception_ptr;
|
||||
static zend_object_handlers default_exception_handlers;
|
||||
ZEND_API void zend_throw_exception(zend_class_entry *exception_ce, char *message, long code TSRMLS_DC);
|
||||
|
||||
static zend_object_value zend_default_exception_new(zend_class_entry *class_type TSRMLS_DC)
|
||||
{
|
||||
zval tmp, obj;
|
||||
zend_object *object;
|
||||
zval *trace;
|
||||
|
||||
obj.value.obj = zend_objects_new(&object, class_type TSRMLS_CC);
|
||||
obj.value.obj.handlers = &default_exception_handlers;
|
||||
|
||||
ALLOC_HASHTABLE(object->properties);
|
||||
zend_hash_init(object->properties, 0, NULL, ZVAL_PTR_DTOR, 0);
|
||||
zend_hash_copy(object->properties, &class_type->default_properties, (copy_ctor_func_t) zval_add_ref, (void *) &tmp, sizeof(zval *));
|
||||
|
||||
ALLOC_ZVAL(trace);
|
||||
trace->is_ref = 0;
|
||||
trace->refcount = 0;
|
||||
zend_fetch_debug_backtrace(trace, 0 TSRMLS_CC);
|
||||
|
||||
zend_update_property_string(class_type, &obj, "file", sizeof("file")-1, zend_get_executed_filename(TSRMLS_C) TSRMLS_CC);
|
||||
zend_update_property_long(class_type, &obj, "line", sizeof("line")-1, zend_get_executed_lineno(TSRMLS_C) TSRMLS_CC);
|
||||
zend_update_property(class_type, &obj, "trace", sizeof("trace")-1, trace TSRMLS_CC);
|
||||
|
||||
return obj.value.obj;
|
||||
}
|
||||
|
||||
ZEND_METHOD(exception, __clone)
|
||||
{
|
||||
/* Should never be executable */
|
||||
zend_throw_exception(NULL, "Cannot clone object using __clone()", 0 TSRMLS_CC);
|
||||
}
|
||||
|
||||
ZEND_METHOD(exception, __construct)
|
||||
{
|
||||
char *message = NULL;
|
||||
long code = 0;
|
||||
zval *object;
|
||||
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_CORE_ERROR, "Wrong parameter count for exception([string $exception [, long $code ]])");
|
||||
}
|
||||
|
||||
object = getThis();
|
||||
|
||||
if (message) {
|
||||
zend_update_property_string(Z_OBJCE_P(object), object, "message", sizeof("message")-1, message TSRMLS_CC);
|
||||
}
|
||||
|
||||
if (code) {
|
||||
zend_update_property_long(Z_OBJCE_P(object), object, "code", sizeof("code")-1, code TSRMLS_CC);
|
||||
}
|
||||
}
|
||||
|
||||
#define DEFAULT_0_PARAMS \
|
||||
if (ZEND_NUM_ARGS() > 0) { \
|
||||
ZEND_WRONG_PARAM_COUNT(); \
|
||||
}
|
||||
|
||||
static void _default_exception_get_entry(zval *object, char *name, int name_len, zval *return_value TSRMLS_DC)
|
||||
{
|
||||
zval *value;
|
||||
|
||||
value = zend_read_property(Z_OBJCE_P(object), object, name, name_len, 0 TSRMLS_CC);
|
||||
|
||||
*return_value = *value;
|
||||
zval_copy_ctor(return_value);
|
||||
}
|
||||
|
||||
ZEND_METHOD(exception, getFile)
|
||||
{
|
||||
DEFAULT_0_PARAMS;
|
||||
|
||||
_default_exception_get_entry(getThis(), "file", sizeof("file")-1, return_value TSRMLS_CC);
|
||||
}
|
||||
|
||||
ZEND_METHOD(exception, getLine)
|
||||
{
|
||||
DEFAULT_0_PARAMS;
|
||||
|
||||
_default_exception_get_entry(getThis(), "line", sizeof("line")-1, return_value TSRMLS_CC);
|
||||
}
|
||||
|
||||
ZEND_METHOD(exception, getMessage)
|
||||
{
|
||||
DEFAULT_0_PARAMS;
|
||||
|
||||
_default_exception_get_entry(getThis(), "message", sizeof("message")-1, return_value TSRMLS_CC);
|
||||
}
|
||||
|
||||
ZEND_METHOD(exception, getCode)
|
||||
{
|
||||
DEFAULT_0_PARAMS;
|
||||
|
||||
_default_exception_get_entry(getThis(), "code", sizeof("code")-1, return_value TSRMLS_CC);
|
||||
}
|
||||
|
||||
ZEND_METHOD(exception, getTrace)
|
||||
{
|
||||
DEFAULT_0_PARAMS;
|
||||
|
||||
_default_exception_get_entry(getThis(), "trace", sizeof("trace")-1, return_value TSRMLS_CC);
|
||||
}
|
||||
|
||||
/* {{{ ZEND_METHOD(exception, gettraceasstring) */
|
||||
#define TRACE_APPEND_CHR(chr) \
|
||||
*str = (char*)erealloc(*str, *len + 1 + 1); \
|
||||
(*str)[(*len)++] = chr
|
||||
|
||||
#define TRACE_APPEND_STRL(val, vallen) \
|
||||
{ \
|
||||
int l = vallen; \
|
||||
*str = (char*)erealloc(*str, *len + l + 1); \
|
||||
memcpy((*str) + *len, val, l); \
|
||||
*len += l; \
|
||||
}
|
||||
|
||||
#define TRACE_APPEND_STR(val) \
|
||||
TRACE_APPEND_STRL(val, sizeof(val)-1)
|
||||
|
||||
#define TRACE_APPEND_KEY(key) \
|
||||
if (zend_hash_find(ht, key, sizeof(key), (void**)&tmp) == SUCCESS) { \
|
||||
TRACE_APPEND_STRL(Z_STRVAL_PP(tmp), Z_STRLEN_PP(tmp)); \
|
||||
}
|
||||
|
||||
static int _build_trace_args(zval **arg, int num_args, va_list args, zend_hash_key *hash_key)
|
||||
{
|
||||
char **str;
|
||||
int *len;
|
||||
|
||||
str = va_arg(args, char**);
|
||||
len = va_arg(args, int*);
|
||||
|
||||
/* the trivial way would be to do:
|
||||
* conver_to_string_ex(arg);
|
||||
* append it and kill the now tmp arg.
|
||||
* but that could cause some E_NOTICE and also damn long lines.
|
||||
*/
|
||||
|
||||
switch (Z_TYPE_PP(arg)) {
|
||||
case IS_NULL:
|
||||
TRACE_APPEND_STR("NULL, ");
|
||||
break;
|
||||
case IS_STRING: {
|
||||
int l_added;
|
||||
TRACE_APPEND_CHR('\'');
|
||||
if (Z_STRLEN_PP(arg) > 15) {
|
||||
TRACE_APPEND_STRL(Z_STRVAL_PP(arg), 15);
|
||||
TRACE_APPEND_STR("...', ");
|
||||
l_added = 15 + 6 + 1; /* +1 because of while (--l_added) */
|
||||
} else {
|
||||
l_added = Z_STRLEN_PP(arg);
|
||||
TRACE_APPEND_STRL(Z_STRVAL_PP(arg), l_added);
|
||||
TRACE_APPEND_STR("', ");
|
||||
l_added += 3 + 1;
|
||||
}
|
||||
while (--l_added) {
|
||||
if ((*str)[*len - l_added] < 32) {
|
||||
(*str)[*len - l_added] = '?';
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
case IS_BOOL:
|
||||
if (Z_LVAL_PP(arg)) {
|
||||
TRACE_APPEND_STR("true, ");
|
||||
} else {
|
||||
TRACE_APPEND_STR("false, ");
|
||||
}
|
||||
break;
|
||||
case IS_RESOURCE:
|
||||
TRACE_APPEND_STR("Resource id #");
|
||||
/* break; */
|
||||
case IS_LONG: {
|
||||
long lval = Z_LVAL_PP(arg);
|
||||
char s_tmp[MAX_LENGTH_OF_LONG + 1];
|
||||
int l_tmp = zend_sprintf(s_tmp, "%ld", lval); /* SAFE */
|
||||
TRACE_APPEND_STRL(s_tmp, l_tmp);
|
||||
TRACE_APPEND_STR(", ");
|
||||
break;
|
||||
}
|
||||
case IS_DOUBLE: {
|
||||
double dval = Z_DVAL_PP(arg);
|
||||
char *s_tmp;
|
||||
int l_tmp;
|
||||
TSRMLS_FETCH();
|
||||
|
||||
s_tmp = emalloc(MAX_LENGTH_OF_DOUBLE + EG(precision) + 1);
|
||||
l_tmp = zend_sprintf(s_tmp, "%.*G", (int) EG(precision), dval); /* SAFE */
|
||||
TRACE_APPEND_STRL(s_tmp, l_tmp);
|
||||
/* %G already handles removing trailing zeros from the fractional part, yay */
|
||||
efree(s_tmp);
|
||||
TRACE_APPEND_STR(", ");
|
||||
break;
|
||||
}
|
||||
case IS_ARRAY:
|
||||
TRACE_APPEND_STR("Array, ");
|
||||
break;
|
||||
case IS_OBJECT: {
|
||||
TSRMLS_FETCH();
|
||||
|
||||
TRACE_APPEND_STR("Object(");
|
||||
TRACE_APPEND_STRL(Z_OBJCE_PP(arg)->name, strlen(Z_OBJCE_PP(arg)->name));
|
||||
TRACE_APPEND_STR("), ");
|
||||
break;
|
||||
}
|
||||
default:
|
||||
break;
|
||||
}
|
||||
return ZEND_HASH_APPLY_KEEP;
|
||||
}
|
||||
|
||||
static int _build_trace_string(zval **frame, int num_args, va_list args, zend_hash_key *hash_key)
|
||||
{
|
||||
char *s_tmp, **str;
|
||||
int *len, *num;
|
||||
long line;
|
||||
HashTable *ht = Z_ARRVAL_PP(frame);
|
||||
zval **file, **tmp;
|
||||
|
||||
str = va_arg(args, char**);
|
||||
len = va_arg(args, int*);
|
||||
num = va_arg(args, int*);
|
||||
|
||||
s_tmp = emalloc(1 + MAX_LENGTH_OF_LONG + 1 + 1);
|
||||
sprintf(s_tmp, "#%d ", (*num)++);
|
||||
TRACE_APPEND_STRL(s_tmp, strlen(s_tmp));
|
||||
efree(s_tmp);
|
||||
if (zend_hash_find(ht, "file", sizeof("file"), (void**)&file) == SUCCESS) {
|
||||
if (zend_hash_find(ht, "line", sizeof("line"), (void**)&tmp) == SUCCESS) {
|
||||
line = Z_LVAL_PP(tmp);
|
||||
} else {
|
||||
line = 0;
|
||||
}
|
||||
s_tmp = emalloc(Z_STRLEN_PP(file) + MAX_LENGTH_OF_LONG + 2 + 1);
|
||||
sprintf(s_tmp, "%s(%ld): ", Z_STRVAL_PP(file), line);
|
||||
TRACE_APPEND_STRL(s_tmp, strlen(s_tmp));
|
||||
efree(s_tmp);
|
||||
} else {
|
||||
TRACE_APPEND_STR("[internal function]: ");
|
||||
}
|
||||
TRACE_APPEND_KEY("class");
|
||||
TRACE_APPEND_KEY("type");
|
||||
TRACE_APPEND_KEY("function");
|
||||
TRACE_APPEND_CHR('(');
|
||||
if (zend_hash_find(ht, "args", sizeof("args"), (void**)&tmp) == SUCCESS) {
|
||||
int last_len = *len;
|
||||
zend_hash_apply_with_arguments(Z_ARRVAL_PP(tmp), (apply_func_args_t)_build_trace_args, 2, str, len);
|
||||
if (last_len != *len) {
|
||||
*len -= 2; /* remove last ', ' */
|
||||
}
|
||||
}
|
||||
TRACE_APPEND_STR(")\n");
|
||||
return ZEND_HASH_APPLY_KEEP;
|
||||
}
|
||||
|
||||
ZEND_METHOD(exception, getTraceAsString)
|
||||
{
|
||||
zval *trace;
|
||||
char *res = estrdup(""), **str = &res, *s_tmp;
|
||||
int res_len = 0, *len = &res_len, num = 0;
|
||||
|
||||
trace = zend_read_property(Z_OBJCE_P(getThis()), getThis(), "trace", sizeof("trace")-1, 1 TSRMLS_CC);
|
||||
zend_hash_apply_with_arguments(Z_ARRVAL_P(trace), (apply_func_args_t)_build_trace_string, 3, str, len, &num);
|
||||
|
||||
s_tmp = emalloc(1 + MAX_LENGTH_OF_LONG + 7 + 1);
|
||||
sprintf(s_tmp, "#%d {main}", num);
|
||||
TRACE_APPEND_STRL(s_tmp, strlen(s_tmp));
|
||||
efree(s_tmp);
|
||||
|
||||
res[res_len] = '\0';
|
||||
RETURN_STRINGL(res, res_len, 0);
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
int zend_spprintf(char **message, int max_len, char *format, ...)
|
||||
{
|
||||
va_list arg;
|
||||
int len;
|
||||
|
||||
va_start(arg, format);
|
||||
len = zend_vspprintf(message, max_len, format, arg);
|
||||
va_end(arg);
|
||||
return len;
|
||||
}
|
||||
|
||||
ZEND_METHOD(exception, __toString)
|
||||
{
|
||||
zval *message, *file, *line, *trace;
|
||||
char *str;
|
||||
int len;
|
||||
zend_fcall_info fci;
|
||||
zval fname;
|
||||
|
||||
message = zend_read_property(Z_OBJCE_P(getThis()), getThis(), "message", sizeof("message")-1, 1 TSRMLS_CC);
|
||||
file = zend_read_property(Z_OBJCE_P(getThis()), getThis(), "file", sizeof("file")-1, 1 TSRMLS_CC);
|
||||
line = zend_read_property(Z_OBJCE_P(getThis()), getThis(), "line", sizeof("line")-1, 1 TSRMLS_CC);
|
||||
|
||||
ZVAL_STRINGL(&fname, "gettraceasstring", sizeof("gettraceasstring")-1, 0);
|
||||
|
||||
fci.size = sizeof(fci);
|
||||
fci.function_table = &Z_OBJCE_P(getThis())->function_table;
|
||||
fci.function_name = &fname;
|
||||
fci.symbol_table = NULL;
|
||||
fci.object_pp = &getThis();
|
||||
fci.retval_ptr_ptr = &trace;
|
||||
fci.param_count = 0;
|
||||
fci.params = NULL;
|
||||
fci.no_separation = 1;
|
||||
|
||||
zend_call_function(&fci, NULL TSRMLS_CC);
|
||||
|
||||
len = zend_spprintf(&str, 0, "exception '%s' with message '%s' in %s:%ld\nStack trace:\n%s",
|
||||
Z_OBJCE_P(getThis())->name, Z_STRVAL_P(message), Z_STRVAL_P(file), Z_LVAL_P(line),
|
||||
Z_STRLEN_P(trace) ? Z_STRVAL_P(trace) : "#0 {main}\n");
|
||||
|
||||
/* We store the result in the private property string so we can access
|
||||
* the result in uncaught exception handlers without memleaks. */
|
||||
zend_update_property_string(default_exception_ptr, getThis(), "string", sizeof("string")-1, str TSRMLS_CC);
|
||||
|
||||
zval_ptr_dtor(&trace);
|
||||
|
||||
RETURN_STRINGL(str, len, 0);
|
||||
}
|
||||
|
||||
/* All functions that may be used in uncaught exception handlers must be final
|
||||
* and must not throw exceptions. Otherwise we would need a facility to handle
|
||||
* such exceptions in that handler.
|
||||
* Also all getXY() methods are final because thy serve as read only access to
|
||||
* their corresponding properties, no more, no less. If after all you need to
|
||||
* override somthing then it is method __toString().
|
||||
* And never try to change the state of exceptions and never implement anything
|
||||
* that gives the user anything to accomplish this.
|
||||
*/
|
||||
static zend_function_entry default_exception_functions[] = {
|
||||
ZEND_ME(exception, __clone, NULL, ZEND_ACC_PRIVATE|ZEND_ACC_FINAL)
|
||||
ZEND_ME(exception, __construct, NULL, 0)
|
||||
ZEND_ME(exception, getMessage, NULL, ZEND_ACC_PUBLIC|ZEND_ACC_FINAL)
|
||||
ZEND_ME(exception, getCode, NULL, ZEND_ACC_PUBLIC|ZEND_ACC_FINAL)
|
||||
ZEND_ME(exception, getFile, NULL, ZEND_ACC_PUBLIC|ZEND_ACC_FINAL)
|
||||
ZEND_ME(exception, getLine, NULL, ZEND_ACC_PUBLIC|ZEND_ACC_FINAL)
|
||||
ZEND_ME(exception, getTrace, NULL, ZEND_ACC_PUBLIC|ZEND_ACC_FINAL)
|
||||
ZEND_ME(exception, getTraceAsString, NULL, ZEND_ACC_PUBLIC|ZEND_ACC_FINAL)
|
||||
ZEND_ME(exception, __toString, NULL, 0)
|
||||
{NULL, NULL, NULL}
|
||||
};
|
||||
|
||||
static void zend_register_default_exception(TSRMLS_D)
|
||||
{
|
||||
zend_class_entry ce;
|
||||
|
||||
INIT_CLASS_ENTRY(ce, "exception", default_exception_functions);
|
||||
default_exception_ptr = zend_register_internal_class(&ce TSRMLS_CC);
|
||||
default_exception_ptr->create_object = zend_default_exception_new;
|
||||
memcpy(&default_exception_handlers, zend_get_std_object_handlers(), sizeof(zend_object_handlers));
|
||||
default_exception_handlers.clone_obj = NULL;
|
||||
|
||||
zend_declare_property_string(default_exception_ptr, "message", sizeof("message")-1, "Unknown exception", ZEND_ACC_PROTECTED TSRMLS_CC);
|
||||
zend_declare_property_string(default_exception_ptr, "string", sizeof("string")-1, "", ZEND_ACC_PRIVATE TSRMLS_CC);
|
||||
zend_declare_property_long(default_exception_ptr, "code", sizeof("code")-1, 0, ZEND_ACC_PROTECTED TSRMLS_CC);
|
||||
zend_declare_property_null(default_exception_ptr, "file", sizeof("file")-1, ZEND_ACC_PROTECTED TSRMLS_CC);
|
||||
zend_declare_property_null(default_exception_ptr, "line", sizeof("line")-1, ZEND_ACC_PROTECTED TSRMLS_CC);
|
||||
zend_declare_property_null(default_exception_ptr, "trace", sizeof("trace")-1, ZEND_ACC_PRIVATE TSRMLS_CC);
|
||||
}
|
||||
|
||||
ZEND_API zend_class_entry *zend_exception_get_default(void)
|
||||
{
|
||||
return default_exception_ptr;
|
||||
}
|
||||
|
||||
ZEND_API void zend_throw_exception_ex(zend_class_entry *exception_ce, long code TSRMLS_DC, char *format, ...)
|
||||
{
|
||||
zval *ex;
|
||||
va_list arg;
|
||||
char *message;
|
||||
|
||||
va_start(arg, format);
|
||||
zend_vspprintf(&message, 0, format, arg);
|
||||
va_end(arg);
|
||||
|
||||
MAKE_STD_ZVAL(ex);
|
||||
if (exception_ce) {
|
||||
if (!instanceof_function(exception_ce, default_exception_ptr TSRMLS_CC)) {
|
||||
zend_error(E_NOTICE, "Exceptions must be derived from exception");
|
||||
exception_ce = default_exception_ptr;
|
||||
}
|
||||
} else {
|
||||
exception_ce = default_exception_ptr;
|
||||
}
|
||||
object_init_ex(ex, exception_ce);
|
||||
|
||||
|
||||
if (message) {
|
||||
zend_update_property_string(exception_ce, ex, "message", sizeof("message")-1, message TSRMLS_CC);
|
||||
}
|
||||
if (code) {
|
||||
zend_update_property_long(exception_ce, ex, "code", sizeof("code")-1, code TSRMLS_CC);
|
||||
}
|
||||
|
||||
efree(message);
|
||||
|
||||
EG(exception) = ex;
|
||||
}
|
||||
|
||||
/* at the moment we can't use zend_throw_exception_ex because we don't have a protable
|
||||
* vsnprintf that tells us the number of characters needed nor do we have spprintf from
|
||||
* php or asprintf from glibc always.
|
||||
*/
|
||||
ZEND_API void zend_throw_exception(zend_class_entry *exception_ce, char *message, long code TSRMLS_DC)
|
||||
{
|
||||
zval *ex;
|
||||
|
||||
MAKE_STD_ZVAL(ex);
|
||||
if (exception_ce) {
|
||||
if (!instanceof_function(exception_ce, default_exception_ptr TSRMLS_CC)) {
|
||||
zend_error(E_NOTICE, "Exceptions must be derived from exception");
|
||||
exception_ce = default_exception_ptr;
|
||||
}
|
||||
} else {
|
||||
exception_ce = default_exception_ptr;
|
||||
}
|
||||
object_init_ex(ex, exception_ce);
|
||||
|
||||
|
||||
if (message) {
|
||||
zend_update_property_string(exception_ce, ex, "message", sizeof("message")-1, message TSRMLS_CC);
|
||||
}
|
||||
if (code) {
|
||||
zend_update_property_long(exception_ce, ex, "code", sizeof("code")-1, code TSRMLS_CC);
|
||||
}
|
||||
|
||||
EG(exception) = ex;
|
||||
}
|
||||
|
||||
static void zend_error_va(int type, const char *file, uint lineno, const char *format, ...)
|
||||
{
|
||||
va_list args;
|
||||
|
||||
va_start(args, format);
|
||||
zend_error_cb(type, file, lineno, format, args);
|
||||
va_end(args);
|
||||
}
|
||||
|
||||
ZEND_API void zend_exception_error(zval *exception TSRMLS_DC)
|
||||
{
|
||||
zend_class_entry *ce_exception = Z_OBJCE_P(exception);
|
||||
if (instanceof_function(ce_exception, default_exception_ptr TSRMLS_CC)) {
|
||||
zval *str, *file, *line;
|
||||
zval *old_exception = EG(exception);
|
||||
|
||||
EG(exception) = NULL;
|
||||
|
||||
zend_call_method_with_0_params(&exception, ce_exception, NULL, "__tostring", &str);
|
||||
if (!EG(exception)) {
|
||||
if (Z_TYPE_P(str) != IS_STRING) {
|
||||
zend_error(E_WARNING, "%s::__toString() must return a string", ce_exception->name);
|
||||
} else {
|
||||
zend_update_property_string(default_exception_ptr, exception, "string", sizeof("string")-1, EG(exception) ? ce_exception->name : Z_STRVAL_P(str) TSRMLS_CC);
|
||||
}
|
||||
}
|
||||
zval_ptr_dtor(&str);
|
||||
|
||||
if (EG(exception)) {
|
||||
/* do the best we can to inform about the inner exception */
|
||||
if (instanceof_function(ce_exception, default_exception_ptr TSRMLS_CC)) {
|
||||
file = zend_read_property(default_exception_ptr, EG(exception), "file", sizeof("file")-1, 1 TSRMLS_CC);
|
||||
line = zend_read_property(default_exception_ptr, EG(exception), "line", sizeof("line")-1, 1 TSRMLS_CC);
|
||||
} else {
|
||||
file = NULL;
|
||||
line = NULL;
|
||||
}
|
||||
zend_error_va(E_WARNING, file ? Z_STRVAL_P(file) : NULL, line ? Z_LVAL_P(line) : 0, "Uncaught %s in exception handling during call to %s::__tostring()", Z_OBJCE_P(EG(exception))->name, ce_exception->name);
|
||||
}
|
||||
|
||||
str = zend_read_property(default_exception_ptr, exception, "string", sizeof("string")-1, 1 TSRMLS_CC);
|
||||
file = zend_read_property(default_exception_ptr, exception, "file", sizeof("file")-1, 1 TSRMLS_CC);
|
||||
line = zend_read_property(default_exception_ptr, exception, "line", sizeof("line")-1, 1 TSRMLS_CC);
|
||||
|
||||
EG(exception) = old_exception;
|
||||
|
||||
zend_error_va(E_ERROR, Z_STRVAL_P(file), Z_LVAL_P(line), "Uncaught %s\n thrown", Z_STRVAL_P(str));
|
||||
} else {
|
||||
zend_error(E_ERROR, "Uncaught exception '%s'", ce_exception->name);
|
||||
}
|
||||
}
|
||||
|
||||
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);
|
||||
}
|
||||
|
||||
/*
|
||||
* Local variables:
|
||||
* tab-width: 4
|
||||
* c-basic-offset: 4
|
||||
* indent-tabs-mode: t
|
||||
* End:
|
||||
*/
|
||||
@@ -1,48 +0,0 @@
|
||||
/*
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2003 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 |
|
||||
| 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 |
|
||||
| obtain it through the world-wide-web, please send a note to |
|
||||
| license@zend.com so we can mail you a copy immediately. |
|
||||
+----------------------------------------------------------------------+
|
||||
| Authors: Sterling Hughes <sterling@php.net> |
|
||||
| Marcus Boerger <helly@php.net> |
|
||||
+----------------------------------------------------------------------+
|
||||
*/
|
||||
|
||||
/* $Id$ */
|
||||
|
||||
#ifndef ZEND_DEFAULT_CLASSES_H
|
||||
#define ZEND_DEFAULT_CLASSES_H
|
||||
|
||||
BEGIN_EXTERN_C()
|
||||
|
||||
ZEND_API zend_class_entry *zend_exception_get_default(void);
|
||||
ZEND_API void zend_register_default_classes(TSRMLS_D);
|
||||
|
||||
/* exception_ce NULL or zend_exception_get_default() or a derived class
|
||||
* message NULL or the message of the exception */
|
||||
ZEND_API void zend_throw_exception(zend_class_entry *exception_ce, char *message, long code TSRMLS_DC);
|
||||
ZEND_API void zend_throw_exception_ex(zend_class_entry *exception_ce, long code TSRMLS_DC, char *format, ...);
|
||||
|
||||
/* show an exception using zend_error(E_ERROR,...) */
|
||||
ZEND_API void zend_exception_error(zval *exception TSRMLS_DC);
|
||||
|
||||
END_EXTERN_C()
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
* Local variables:
|
||||
* tab-width: 4
|
||||
* c-basic-offset: 4
|
||||
* indent-tabs-mode: t
|
||||
* End:
|
||||
*/
|
||||
@@ -1,72 +0,0 @@
|
||||
/*
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2003 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 |
|
||||
| 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 |
|
||||
| obtain it through the world-wide-web, please send a note to |
|
||||
| license@zend.com so we can mail you a copy immediately. |
|
||||
+----------------------------------------------------------------------+
|
||||
| Authors: Andi Gutmans <andi@zend.com> |
|
||||
| Zeev Suraski <zeev@zend.com> |
|
||||
+----------------------------------------------------------------------+
|
||||
*/
|
||||
|
||||
/* $Id$ */
|
||||
|
||||
#include "zend.h"
|
||||
|
||||
typedef struct _dynamic_array {
|
||||
char *array;
|
||||
unsigned int element_size;
|
||||
unsigned int current;
|
||||
unsigned int allocated;
|
||||
} dynamic_array;
|
||||
|
||||
ZEND_API int zend_dynamic_array_init(dynamic_array *da, unsigned int element_size, unsigned int size)
|
||||
{
|
||||
da->element_size = element_size;
|
||||
da->allocated = size;
|
||||
da->current = 0;
|
||||
da->array = (char *) emalloc(size*element_size);
|
||||
if (da->array == NULL) {
|
||||
return 1;
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
ZEND_API void *zend_dynamic_array_push(dynamic_array *da)
|
||||
{
|
||||
if (da->current == da->allocated) {
|
||||
da->allocated *= 2;
|
||||
da->array = (char *) erealloc(da->array, da->allocated*da->element_size);
|
||||
}
|
||||
return (void *)(da->array+(da->current++)*da->element_size);
|
||||
}
|
||||
|
||||
ZEND_API void *zend_dynamic_array_pop(dynamic_array *da)
|
||||
{
|
||||
return (void *)(da->array+(--(da->current))*da->element_size);
|
||||
|
||||
}
|
||||
|
||||
ZEND_API void *zend_dynamic_array_get_element(dynamic_array *da, unsigned int index)
|
||||
{
|
||||
if (index >= da->current) {
|
||||
return NULL;
|
||||
}
|
||||
return (void *)(da->array+index*da->element_size);
|
||||
}
|
||||
|
||||
/*
|
||||
* Local variables:
|
||||
* tab-width: 4
|
||||
* c-basic-offset: 4
|
||||
* indent-tabs-mode: t
|
||||
* End:
|
||||
*/
|
||||
@@ -1,47 +0,0 @@
|
||||
/*
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2003 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 |
|
||||
| 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 |
|
||||
| obtain it through the world-wide-web, please send a note to |
|
||||
| license@zend.com so we can mail you a copy immediately. |
|
||||
+----------------------------------------------------------------------+
|
||||
| Authors: Andi Gutmans <andi@zend.com> |
|
||||
| Zeev Suraski <zeev@zend.com> |
|
||||
+----------------------------------------------------------------------+
|
||||
*/
|
||||
|
||||
/* $Id$ */
|
||||
|
||||
#ifndef ZEND_DYNAMIC_ARRAY_H
|
||||
#define ZEND_DYNAMIC_ARRAY_H
|
||||
|
||||
typedef struct _dynamic_array {
|
||||
char *array;
|
||||
unsigned int element_size;
|
||||
unsigned int last_used;
|
||||
unsigned int allocated;
|
||||
} dynamic_array;
|
||||
|
||||
BEGIN_EXTERN_C()
|
||||
ZEND_API int zend_dynamic_array_init(dynamic_array *da);
|
||||
ZEND_API void *zend_dynamic_array_push(dynamic_array *da);
|
||||
ZEND_API void *zend_dynamic_array_pop(dynamic_array *da);
|
||||
ZEND_API void *zend_dynamic_array_get_element(dynamic_array *da, unsigned int index);
|
||||
END_EXTERN_C()
|
||||
|
||||
#endif /* ZEND_DYNAMIC_ARRAY_H */
|
||||
|
||||
/*
|
||||
* Local variables:
|
||||
* tab-width: 4
|
||||
* c-basic-offset: 4
|
||||
* indent-tabs-mode: t
|
||||
* End:
|
||||
*/
|
||||
@@ -1,49 +0,0 @@
|
||||
/*
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2003 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 |
|
||||
| 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 |
|
||||
| obtain it through the world-wide-web, please send a note to |
|
||||
| license@zend.com so we can mail you a copy immediately. |
|
||||
+----------------------------------------------------------------------+
|
||||
| Authors: Andi Gutmans <andi@zend.com> |
|
||||
| Zeev Suraski <zeev@zend.com> |
|
||||
+----------------------------------------------------------------------+
|
||||
*/
|
||||
|
||||
/* $Id$ */
|
||||
|
||||
#ifndef ZEND_ERRORS_H
|
||||
#define ZEND_ERRORS_H
|
||||
|
||||
#define E_ERROR (1<<0L)
|
||||
#define E_WARNING (1<<1L)
|
||||
#define E_PARSE (1<<2L)
|
||||
#define E_NOTICE (1<<3L)
|
||||
#define E_CORE_ERROR (1<<4L)
|
||||
#define E_CORE_WARNING (1<<5L)
|
||||
#define E_COMPILE_ERROR (1<<6L)
|
||||
#define E_COMPILE_WARNING (1<<7L)
|
||||
#define E_USER_ERROR (1<<8L)
|
||||
#define E_USER_WARNING (1<<9L)
|
||||
#define E_USER_NOTICE (1<<10L)
|
||||
#define E_STRICT (1<<11L)
|
||||
|
||||
#define E_ALL (E_ERROR | E_WARNING | E_PARSE | E_NOTICE | E_CORE_ERROR | E_CORE_WARNING | E_COMPILE_ERROR | E_COMPILE_WARNING | E_USER_ERROR | E_USER_WARNING | E_USER_NOTICE)
|
||||
#define E_CORE (E_CORE_ERROR | E_CORE_WARNING)
|
||||
|
||||
#endif /* ZEND_ERRORS_H */
|
||||
|
||||
/*
|
||||
* Local variables:
|
||||
* tab-width: 4
|
||||
* c-basic-offset: 4
|
||||
* indent-tabs-mode: t
|
||||
* End:
|
||||
*/
|
||||
@@ -1,531 +0,0 @@
|
||||
/*
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2003 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 |
|
||||
| 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 |
|
||||
| obtain it through the world-wide-web, please send a note to |
|
||||
| license@zend.com so we can mail you a copy immediately. |
|
||||
+----------------------------------------------------------------------+
|
||||
| Authors: Sterling Hughes <sterling@php.net> |
|
||||
| Marcus Boerger <helly@php.net> |
|
||||
+----------------------------------------------------------------------+
|
||||
*/
|
||||
|
||||
/* $Id$ */
|
||||
|
||||
#include "zend.h"
|
||||
#include "zend_API.h"
|
||||
#include "zend_reflection_api.h"
|
||||
#include "zend_builtin_functions.h"
|
||||
#include "zend_interfaces.h"
|
||||
|
||||
static zend_class_entry *default_exception_ptr;
|
||||
static zend_object_handlers default_exception_handlers;
|
||||
ZEND_API void zend_throw_exception(zend_class_entry *exception_ce, char *message, long code TSRMLS_DC);
|
||||
|
||||
static zend_object_value zend_default_exception_new(zend_class_entry *class_type TSRMLS_DC)
|
||||
{
|
||||
zval tmp, obj;
|
||||
zend_object *object;
|
||||
zval *trace;
|
||||
|
||||
obj.value.obj = zend_objects_new(&object, class_type TSRMLS_CC);
|
||||
obj.value.obj.handlers = &default_exception_handlers;
|
||||
|
||||
ALLOC_HASHTABLE(object->properties);
|
||||
zend_hash_init(object->properties, 0, NULL, ZVAL_PTR_DTOR, 0);
|
||||
zend_hash_copy(object->properties, &class_type->default_properties, (copy_ctor_func_t) zval_add_ref, (void *) &tmp, sizeof(zval *));
|
||||
|
||||
ALLOC_ZVAL(trace);
|
||||
trace->is_ref = 0;
|
||||
trace->refcount = 0;
|
||||
zend_fetch_debug_backtrace(trace, 0 TSRMLS_CC);
|
||||
|
||||
zend_update_property_string(class_type, &obj, "file", sizeof("file")-1, zend_get_executed_filename(TSRMLS_C) TSRMLS_CC);
|
||||
zend_update_property_long(class_type, &obj, "line", sizeof("line")-1, zend_get_executed_lineno(TSRMLS_C) TSRMLS_CC);
|
||||
zend_update_property(class_type, &obj, "trace", sizeof("trace")-1, trace TSRMLS_CC);
|
||||
|
||||
return obj.value.obj;
|
||||
}
|
||||
|
||||
ZEND_METHOD(exception, __clone)
|
||||
{
|
||||
/* Should never be executable */
|
||||
zend_throw_exception(NULL, "Cannot clone object using __clone()", 0 TSRMLS_CC);
|
||||
}
|
||||
|
||||
ZEND_METHOD(exception, __construct)
|
||||
{
|
||||
char *message = NULL;
|
||||
long code = 0;
|
||||
zval *object;
|
||||
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_CORE_ERROR, "Wrong parameter count for exception([string $exception [, long $code ]])");
|
||||
}
|
||||
|
||||
object = getThis();
|
||||
|
||||
if (message) {
|
||||
zend_update_property_string(Z_OBJCE_P(object), object, "message", sizeof("message")-1, message TSRMLS_CC);
|
||||
}
|
||||
|
||||
if (code) {
|
||||
zend_update_property_long(Z_OBJCE_P(object), object, "code", sizeof("code")-1, code TSRMLS_CC);
|
||||
}
|
||||
}
|
||||
|
||||
#define DEFAULT_0_PARAMS \
|
||||
if (ZEND_NUM_ARGS() > 0) { \
|
||||
ZEND_WRONG_PARAM_COUNT(); \
|
||||
}
|
||||
|
||||
static void _default_exception_get_entry(zval *object, char *name, int name_len, zval *return_value TSRMLS_DC)
|
||||
{
|
||||
zval *value;
|
||||
|
||||
value = zend_read_property(Z_OBJCE_P(object), object, name, name_len, 0 TSRMLS_CC);
|
||||
|
||||
*return_value = *value;
|
||||
zval_copy_ctor(return_value);
|
||||
}
|
||||
|
||||
ZEND_METHOD(exception, getFile)
|
||||
{
|
||||
DEFAULT_0_PARAMS;
|
||||
|
||||
_default_exception_get_entry(getThis(), "file", sizeof("file")-1, return_value TSRMLS_CC);
|
||||
}
|
||||
|
||||
ZEND_METHOD(exception, getLine)
|
||||
{
|
||||
DEFAULT_0_PARAMS;
|
||||
|
||||
_default_exception_get_entry(getThis(), "line", sizeof("line")-1, return_value TSRMLS_CC);
|
||||
}
|
||||
|
||||
ZEND_METHOD(exception, getMessage)
|
||||
{
|
||||
DEFAULT_0_PARAMS;
|
||||
|
||||
_default_exception_get_entry(getThis(), "message", sizeof("message")-1, return_value TSRMLS_CC);
|
||||
}
|
||||
|
||||
ZEND_METHOD(exception, getCode)
|
||||
{
|
||||
DEFAULT_0_PARAMS;
|
||||
|
||||
_default_exception_get_entry(getThis(), "code", sizeof("code")-1, return_value TSRMLS_CC);
|
||||
}
|
||||
|
||||
ZEND_METHOD(exception, getTrace)
|
||||
{
|
||||
DEFAULT_0_PARAMS;
|
||||
|
||||
_default_exception_get_entry(getThis(), "trace", sizeof("trace")-1, return_value TSRMLS_CC);
|
||||
}
|
||||
|
||||
/* {{{ ZEND_METHOD(exception, gettraceasstring) */
|
||||
#define TRACE_APPEND_CHR(chr) \
|
||||
*str = (char*)erealloc(*str, *len + 1 + 1); \
|
||||
(*str)[(*len)++] = chr
|
||||
|
||||
#define TRACE_APPEND_STRL(val, vallen) \
|
||||
{ \
|
||||
int l = vallen; \
|
||||
*str = (char*)erealloc(*str, *len + l + 1); \
|
||||
memcpy((*str) + *len, val, l); \
|
||||
*len += l; \
|
||||
}
|
||||
|
||||
#define TRACE_APPEND_STR(val) \
|
||||
TRACE_APPEND_STRL(val, sizeof(val)-1)
|
||||
|
||||
#define TRACE_APPEND_KEY(key) \
|
||||
if (zend_hash_find(ht, key, sizeof(key), (void**)&tmp) == SUCCESS) { \
|
||||
TRACE_APPEND_STRL(Z_STRVAL_PP(tmp), Z_STRLEN_PP(tmp)); \
|
||||
}
|
||||
|
||||
static int _build_trace_args(zval **arg, int num_args, va_list args, zend_hash_key *hash_key)
|
||||
{
|
||||
char **str;
|
||||
int *len;
|
||||
|
||||
str = va_arg(args, char**);
|
||||
len = va_arg(args, int*);
|
||||
|
||||
/* the trivial way would be to do:
|
||||
* conver_to_string_ex(arg);
|
||||
* append it and kill the now tmp arg.
|
||||
* but that could cause some E_NOTICE and also damn long lines.
|
||||
*/
|
||||
|
||||
switch (Z_TYPE_PP(arg)) {
|
||||
case IS_NULL:
|
||||
TRACE_APPEND_STR("NULL, ");
|
||||
break;
|
||||
case IS_STRING: {
|
||||
int l_added;
|
||||
TRACE_APPEND_CHR('\'');
|
||||
if (Z_STRLEN_PP(arg) > 15) {
|
||||
TRACE_APPEND_STRL(Z_STRVAL_PP(arg), 15);
|
||||
TRACE_APPEND_STR("...', ");
|
||||
l_added = 15 + 6 + 1; /* +1 because of while (--l_added) */
|
||||
} else {
|
||||
l_added = Z_STRLEN_PP(arg);
|
||||
TRACE_APPEND_STRL(Z_STRVAL_PP(arg), l_added);
|
||||
TRACE_APPEND_STR("', ");
|
||||
l_added += 3 + 1;
|
||||
}
|
||||
while (--l_added) {
|
||||
if ((*str)[*len - l_added] < 32) {
|
||||
(*str)[*len - l_added] = '?';
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
case IS_BOOL:
|
||||
if (Z_LVAL_PP(arg)) {
|
||||
TRACE_APPEND_STR("true, ");
|
||||
} else {
|
||||
TRACE_APPEND_STR("false, ");
|
||||
}
|
||||
break;
|
||||
case IS_RESOURCE:
|
||||
TRACE_APPEND_STR("Resource id #");
|
||||
/* break; */
|
||||
case IS_LONG: {
|
||||
long lval = Z_LVAL_PP(arg);
|
||||
char s_tmp[MAX_LENGTH_OF_LONG + 1];
|
||||
int l_tmp = zend_sprintf(s_tmp, "%ld", lval); /* SAFE */
|
||||
TRACE_APPEND_STRL(s_tmp, l_tmp);
|
||||
TRACE_APPEND_STR(", ");
|
||||
break;
|
||||
}
|
||||
case IS_DOUBLE: {
|
||||
double dval = Z_DVAL_PP(arg);
|
||||
char *s_tmp;
|
||||
int l_tmp;
|
||||
TSRMLS_FETCH();
|
||||
|
||||
s_tmp = emalloc(MAX_LENGTH_OF_DOUBLE + EG(precision) + 1);
|
||||
l_tmp = zend_sprintf(s_tmp, "%.*G", (int) EG(precision), dval); /* SAFE */
|
||||
TRACE_APPEND_STRL(s_tmp, l_tmp);
|
||||
/* %G already handles removing trailing zeros from the fractional part, yay */
|
||||
efree(s_tmp);
|
||||
TRACE_APPEND_STR(", ");
|
||||
break;
|
||||
}
|
||||
case IS_ARRAY:
|
||||
TRACE_APPEND_STR("Array, ");
|
||||
break;
|
||||
case IS_OBJECT: {
|
||||
TSRMLS_FETCH();
|
||||
|
||||
TRACE_APPEND_STR("Object(");
|
||||
TRACE_APPEND_STRL(Z_OBJCE_PP(arg)->name, strlen(Z_OBJCE_PP(arg)->name));
|
||||
TRACE_APPEND_STR("), ");
|
||||
break;
|
||||
}
|
||||
default:
|
||||
break;
|
||||
}
|
||||
return ZEND_HASH_APPLY_KEEP;
|
||||
}
|
||||
|
||||
static int _build_trace_string(zval **frame, int num_args, va_list args, zend_hash_key *hash_key)
|
||||
{
|
||||
char *s_tmp, **str;
|
||||
int *len, *num;
|
||||
long line;
|
||||
HashTable *ht = Z_ARRVAL_PP(frame);
|
||||
zval **file, **tmp;
|
||||
|
||||
str = va_arg(args, char**);
|
||||
len = va_arg(args, int*);
|
||||
num = va_arg(args, int*);
|
||||
|
||||
s_tmp = emalloc(1 + MAX_LENGTH_OF_LONG + 1 + 1);
|
||||
sprintf(s_tmp, "#%d ", (*num)++);
|
||||
TRACE_APPEND_STRL(s_tmp, strlen(s_tmp));
|
||||
efree(s_tmp);
|
||||
if (zend_hash_find(ht, "file", sizeof("file"), (void**)&file) == SUCCESS) {
|
||||
if (zend_hash_find(ht, "line", sizeof("line"), (void**)&tmp) == SUCCESS) {
|
||||
line = Z_LVAL_PP(tmp);
|
||||
} else {
|
||||
line = 0;
|
||||
}
|
||||
s_tmp = emalloc(Z_STRLEN_PP(file) + MAX_LENGTH_OF_LONG + 2 + 1);
|
||||
sprintf(s_tmp, "%s(%ld): ", Z_STRVAL_PP(file), line);
|
||||
TRACE_APPEND_STRL(s_tmp, strlen(s_tmp));
|
||||
efree(s_tmp);
|
||||
} else {
|
||||
TRACE_APPEND_STR("[internal function]: ");
|
||||
}
|
||||
TRACE_APPEND_KEY("class");
|
||||
TRACE_APPEND_KEY("type");
|
||||
TRACE_APPEND_KEY("function");
|
||||
TRACE_APPEND_CHR('(');
|
||||
if (zend_hash_find(ht, "args", sizeof("args"), (void**)&tmp) == SUCCESS) {
|
||||
int last_len = *len;
|
||||
zend_hash_apply_with_arguments(Z_ARRVAL_PP(tmp), (apply_func_args_t)_build_trace_args, 2, str, len);
|
||||
if (last_len != *len) {
|
||||
*len -= 2; /* remove last ', ' */
|
||||
}
|
||||
}
|
||||
TRACE_APPEND_STR(")\n");
|
||||
return ZEND_HASH_APPLY_KEEP;
|
||||
}
|
||||
|
||||
ZEND_METHOD(exception, getTraceAsString)
|
||||
{
|
||||
zval *trace;
|
||||
char *res = estrdup(""), **str = &res, *s_tmp;
|
||||
int res_len = 0, *len = &res_len, num = 0;
|
||||
|
||||
trace = zend_read_property(Z_OBJCE_P(getThis()), getThis(), "trace", sizeof("trace")-1, 1 TSRMLS_CC);
|
||||
zend_hash_apply_with_arguments(Z_ARRVAL_P(trace), (apply_func_args_t)_build_trace_string, 3, str, len, &num);
|
||||
|
||||
s_tmp = emalloc(1 + MAX_LENGTH_OF_LONG + 7 + 1);
|
||||
sprintf(s_tmp, "#%d {main}", num);
|
||||
TRACE_APPEND_STRL(s_tmp, strlen(s_tmp));
|
||||
efree(s_tmp);
|
||||
|
||||
res[res_len] = '\0';
|
||||
RETURN_STRINGL(res, res_len, 0);
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
int zend_spprintf(char **message, int max_len, char *format, ...)
|
||||
{
|
||||
va_list arg;
|
||||
int len;
|
||||
|
||||
va_start(arg, format);
|
||||
len = zend_vspprintf(message, max_len, format, arg);
|
||||
va_end(arg);
|
||||
return len;
|
||||
}
|
||||
|
||||
ZEND_METHOD(exception, __toString)
|
||||
{
|
||||
zval *message, *file, *line, *trace;
|
||||
char *str;
|
||||
int len;
|
||||
zend_fcall_info fci;
|
||||
zval fname;
|
||||
|
||||
message = zend_read_property(Z_OBJCE_P(getThis()), getThis(), "message", sizeof("message")-1, 1 TSRMLS_CC);
|
||||
file = zend_read_property(Z_OBJCE_P(getThis()), getThis(), "file", sizeof("file")-1, 1 TSRMLS_CC);
|
||||
line = zend_read_property(Z_OBJCE_P(getThis()), getThis(), "line", sizeof("line")-1, 1 TSRMLS_CC);
|
||||
|
||||
ZVAL_STRINGL(&fname, "gettraceasstring", sizeof("gettraceasstring")-1, 0);
|
||||
|
||||
fci.size = sizeof(fci);
|
||||
fci.function_table = &Z_OBJCE_P(getThis())->function_table;
|
||||
fci.function_name = &fname;
|
||||
fci.symbol_table = NULL;
|
||||
fci.object_pp = &getThis();
|
||||
fci.retval_ptr_ptr = &trace;
|
||||
fci.param_count = 0;
|
||||
fci.params = NULL;
|
||||
fci.no_separation = 1;
|
||||
|
||||
zend_call_function(&fci, NULL TSRMLS_CC);
|
||||
|
||||
len = zend_spprintf(&str, 0, "exception '%s' with message '%s' in %s:%ld\nStack trace:\n%s",
|
||||
Z_OBJCE_P(getThis())->name, Z_STRVAL_P(message), Z_STRVAL_P(file), Z_LVAL_P(line),
|
||||
Z_STRLEN_P(trace) ? Z_STRVAL_P(trace) : "#0 {main}\n");
|
||||
|
||||
/* We store the result in the private property string so we can access
|
||||
* the result in uncaught exception handlers without memleaks. */
|
||||
zend_update_property_string(default_exception_ptr, getThis(), "string", sizeof("string")-1, str TSRMLS_CC);
|
||||
|
||||
zval_ptr_dtor(&trace);
|
||||
|
||||
RETURN_STRINGL(str, len, 0);
|
||||
}
|
||||
|
||||
/* All functions that may be used in uncaught exception handlers must be final
|
||||
* and must not throw exceptions. Otherwise we would need a facility to handle
|
||||
* such exceptions in that handler.
|
||||
* Also all getXY() methods are final because thy serve as read only access to
|
||||
* their corresponding properties, no more, no less. If after all you need to
|
||||
* override somthing then it is method __toString().
|
||||
* And never try to change the state of exceptions and never implement anything
|
||||
* that gives the user anything to accomplish this.
|
||||
*/
|
||||
static zend_function_entry default_exception_functions[] = {
|
||||
ZEND_ME(exception, __clone, NULL, ZEND_ACC_PRIVATE|ZEND_ACC_FINAL)
|
||||
ZEND_ME(exception, __construct, NULL, 0)
|
||||
ZEND_ME(exception, getMessage, NULL, ZEND_ACC_PUBLIC|ZEND_ACC_FINAL)
|
||||
ZEND_ME(exception, getCode, NULL, ZEND_ACC_PUBLIC|ZEND_ACC_FINAL)
|
||||
ZEND_ME(exception, getFile, NULL, ZEND_ACC_PUBLIC|ZEND_ACC_FINAL)
|
||||
ZEND_ME(exception, getLine, NULL, ZEND_ACC_PUBLIC|ZEND_ACC_FINAL)
|
||||
ZEND_ME(exception, getTrace, NULL, ZEND_ACC_PUBLIC|ZEND_ACC_FINAL)
|
||||
ZEND_ME(exception, getTraceAsString, NULL, ZEND_ACC_PUBLIC|ZEND_ACC_FINAL)
|
||||
ZEND_ME(exception, __toString, NULL, 0)
|
||||
{NULL, NULL, NULL}
|
||||
};
|
||||
|
||||
static void zend_register_default_exception(TSRMLS_D)
|
||||
{
|
||||
zend_class_entry ce;
|
||||
|
||||
INIT_CLASS_ENTRY(ce, "exception", default_exception_functions);
|
||||
default_exception_ptr = zend_register_internal_class(&ce TSRMLS_CC);
|
||||
default_exception_ptr->create_object = zend_default_exception_new;
|
||||
memcpy(&default_exception_handlers, zend_get_std_object_handlers(), sizeof(zend_object_handlers));
|
||||
default_exception_handlers.clone_obj = NULL;
|
||||
|
||||
zend_declare_property_string(default_exception_ptr, "message", sizeof("message")-1, "Unknown exception", ZEND_ACC_PROTECTED TSRMLS_CC);
|
||||
zend_declare_property_string(default_exception_ptr, "string", sizeof("string")-1, "", ZEND_ACC_PRIVATE TSRMLS_CC);
|
||||
zend_declare_property_long(default_exception_ptr, "code", sizeof("code")-1, 0, ZEND_ACC_PROTECTED TSRMLS_CC);
|
||||
zend_declare_property_null(default_exception_ptr, "file", sizeof("file")-1, ZEND_ACC_PROTECTED TSRMLS_CC);
|
||||
zend_declare_property_null(default_exception_ptr, "line", sizeof("line")-1, ZEND_ACC_PROTECTED TSRMLS_CC);
|
||||
zend_declare_property_null(default_exception_ptr, "trace", sizeof("trace")-1, ZEND_ACC_PRIVATE TSRMLS_CC);
|
||||
}
|
||||
|
||||
ZEND_API zend_class_entry *zend_exception_get_default(void)
|
||||
{
|
||||
return default_exception_ptr;
|
||||
}
|
||||
|
||||
ZEND_API void zend_throw_exception_ex(zend_class_entry *exception_ce, long code TSRMLS_DC, char *format, ...)
|
||||
{
|
||||
zval *ex;
|
||||
va_list arg;
|
||||
char *message;
|
||||
|
||||
va_start(arg, format);
|
||||
zend_vspprintf(&message, 0, format, arg);
|
||||
va_end(arg);
|
||||
|
||||
MAKE_STD_ZVAL(ex);
|
||||
if (exception_ce) {
|
||||
if (!instanceof_function(exception_ce, default_exception_ptr TSRMLS_CC)) {
|
||||
zend_error(E_NOTICE, "Exceptions must be derived from exception");
|
||||
exception_ce = default_exception_ptr;
|
||||
}
|
||||
} else {
|
||||
exception_ce = default_exception_ptr;
|
||||
}
|
||||
object_init_ex(ex, exception_ce);
|
||||
|
||||
|
||||
if (message) {
|
||||
zend_update_property_string(exception_ce, ex, "message", sizeof("message")-1, message TSRMLS_CC);
|
||||
}
|
||||
if (code) {
|
||||
zend_update_property_long(exception_ce, ex, "code", sizeof("code")-1, code TSRMLS_CC);
|
||||
}
|
||||
|
||||
efree(message);
|
||||
|
||||
EG(exception) = ex;
|
||||
}
|
||||
|
||||
/* at the moment we can't use zend_throw_exception_ex because we don't have a protable
|
||||
* vsnprintf that tells us the number of characters needed nor do we have spprintf from
|
||||
* php or asprintf from glibc always.
|
||||
*/
|
||||
ZEND_API void zend_throw_exception(zend_class_entry *exception_ce, char *message, long code TSRMLS_DC)
|
||||
{
|
||||
zval *ex;
|
||||
|
||||
MAKE_STD_ZVAL(ex);
|
||||
if (exception_ce) {
|
||||
if (!instanceof_function(exception_ce, default_exception_ptr TSRMLS_CC)) {
|
||||
zend_error(E_NOTICE, "Exceptions must be derived from exception");
|
||||
exception_ce = default_exception_ptr;
|
||||
}
|
||||
} else {
|
||||
exception_ce = default_exception_ptr;
|
||||
}
|
||||
object_init_ex(ex, exception_ce);
|
||||
|
||||
|
||||
if (message) {
|
||||
zend_update_property_string(exception_ce, ex, "message", sizeof("message")-1, message TSRMLS_CC);
|
||||
}
|
||||
if (code) {
|
||||
zend_update_property_long(exception_ce, ex, "code", sizeof("code")-1, code TSRMLS_CC);
|
||||
}
|
||||
|
||||
EG(exception) = ex;
|
||||
}
|
||||
|
||||
static void zend_error_va(int type, const char *file, uint lineno, const char *format, ...)
|
||||
{
|
||||
va_list args;
|
||||
|
||||
va_start(args, format);
|
||||
zend_error_cb(type, file, lineno, format, args);
|
||||
va_end(args);
|
||||
}
|
||||
|
||||
ZEND_API void zend_exception_error(zval *exception TSRMLS_DC)
|
||||
{
|
||||
zend_class_entry *ce_exception = Z_OBJCE_P(exception);
|
||||
if (instanceof_function(ce_exception, default_exception_ptr TSRMLS_CC)) {
|
||||
zval *str, *file, *line;
|
||||
zval *old_exception = EG(exception);
|
||||
|
||||
EG(exception) = NULL;
|
||||
|
||||
zend_call_method_with_0_params(&exception, ce_exception, NULL, "__tostring", &str);
|
||||
if (!EG(exception)) {
|
||||
if (Z_TYPE_P(str) != IS_STRING) {
|
||||
zend_error(E_WARNING, "%s::__toString() must return a string", ce_exception->name);
|
||||
} else {
|
||||
zend_update_property_string(default_exception_ptr, exception, "string", sizeof("string")-1, EG(exception) ? ce_exception->name : Z_STRVAL_P(str) TSRMLS_CC);
|
||||
}
|
||||
}
|
||||
zval_ptr_dtor(&str);
|
||||
|
||||
if (EG(exception)) {
|
||||
/* do the best we can to inform about the inner exception */
|
||||
if (instanceof_function(ce_exception, default_exception_ptr TSRMLS_CC)) {
|
||||
file = zend_read_property(default_exception_ptr, EG(exception), "file", sizeof("file")-1, 1 TSRMLS_CC);
|
||||
line = zend_read_property(default_exception_ptr, EG(exception), "line", sizeof("line")-1, 1 TSRMLS_CC);
|
||||
} else {
|
||||
file = NULL;
|
||||
line = NULL;
|
||||
}
|
||||
zend_error_va(E_WARNING, file ? Z_STRVAL_P(file) : NULL, line ? Z_LVAL_P(line) : 0, "Uncaught %s in exception handling during call to %s::__tostring()", Z_OBJCE_P(EG(exception))->name, ce_exception->name);
|
||||
}
|
||||
|
||||
str = zend_read_property(default_exception_ptr, exception, "string", sizeof("string")-1, 1 TSRMLS_CC);
|
||||
file = zend_read_property(default_exception_ptr, exception, "file", sizeof("file")-1, 1 TSRMLS_CC);
|
||||
line = zend_read_property(default_exception_ptr, exception, "line", sizeof("line")-1, 1 TSRMLS_CC);
|
||||
|
||||
EG(exception) = old_exception;
|
||||
|
||||
zend_error_va(E_ERROR, Z_STRVAL_P(file), Z_LVAL_P(line), "Uncaught %s\n thrown", Z_STRVAL_P(str));
|
||||
} else {
|
||||
zend_error(E_ERROR, "Uncaught exception '%s'", ce_exception->name);
|
||||
}
|
||||
}
|
||||
|
||||
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);
|
||||
}
|
||||
|
||||
/*
|
||||
* Local variables:
|
||||
* tab-width: 4
|
||||
* c-basic-offset: 4
|
||||
* indent-tabs-mode: t
|
||||
* End:
|
||||
*/
|
||||
@@ -1,48 +0,0 @@
|
||||
/*
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2003 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 |
|
||||
| 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 |
|
||||
| obtain it through the world-wide-web, please send a note to |
|
||||
| license@zend.com so we can mail you a copy immediately. |
|
||||
+----------------------------------------------------------------------+
|
||||
| Authors: Sterling Hughes <sterling@php.net> |
|
||||
| Marcus Boerger <helly@php.net> |
|
||||
+----------------------------------------------------------------------+
|
||||
*/
|
||||
|
||||
/* $Id$ */
|
||||
|
||||
#ifndef ZEND_DEFAULT_CLASSES_H
|
||||
#define ZEND_DEFAULT_CLASSES_H
|
||||
|
||||
BEGIN_EXTERN_C()
|
||||
|
||||
ZEND_API zend_class_entry *zend_exception_get_default(void);
|
||||
ZEND_API void zend_register_default_classes(TSRMLS_D);
|
||||
|
||||
/* exception_ce NULL or zend_exception_get_default() or a derived class
|
||||
* message NULL or the message of the exception */
|
||||
ZEND_API void zend_throw_exception(zend_class_entry *exception_ce, char *message, long code TSRMLS_DC);
|
||||
ZEND_API void zend_throw_exception_ex(zend_class_entry *exception_ce, long code TSRMLS_DC, char *format, ...);
|
||||
|
||||
/* show an exception using zend_error(E_ERROR,...) */
|
||||
ZEND_API void zend_exception_error(zval *exception TSRMLS_DC);
|
||||
|
||||
END_EXTERN_C()
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
* Local variables:
|
||||
* tab-width: 4
|
||||
* c-basic-offset: 4
|
||||
* indent-tabs-mode: t
|
||||
* End:
|
||||
*/
|
||||
-4279
File diff suppressed because it is too large.
Load diff
@@ -1,176 +0,0 @@
|
||||
/*
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2003 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 |
|
||||
| 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 |
|
||||
| obtain it through the world-wide-web, please send a note to |
|
||||
| license@zend.com so we can mail you a copy immediately. |
|
||||
+----------------------------------------------------------------------+
|
||||
| Authors: Andi Gutmans <andi@zend.com> |
|
||||
| Zeev Suraski <zeev@zend.com> |
|
||||
+----------------------------------------------------------------------+
|
||||
*/
|
||||
|
||||
/* $Id$ */
|
||||
|
||||
#ifndef ZEND_EXECUTE_H
|
||||
#define ZEND_EXECUTE_H
|
||||
|
||||
#include "zend_compile.h"
|
||||
#include "zend_hash.h"
|
||||
#include "zend_variables.h"
|
||||
#include "zend_operators.h"
|
||||
|
||||
typedef union _temp_variable {
|
||||
zval tmp_var;
|
||||
struct {
|
||||
zval **ptr_ptr;
|
||||
zval *ptr;
|
||||
struct {
|
||||
zval *str;
|
||||
zend_uint offset;
|
||||
} str_offset;
|
||||
zend_bool fcall_returned_reference;
|
||||
} var;
|
||||
zend_class_entry *class_entry;
|
||||
} temp_variable;
|
||||
|
||||
|
||||
BEGIN_EXTERN_C()
|
||||
ZEND_API extern void (*zend_execute)(zend_op_array *op_array TSRMLS_DC);
|
||||
ZEND_API extern void (*zend_execute_internal)(zend_execute_data *execute_data_ptr, int return_value_used TSRMLS_DC);
|
||||
|
||||
void init_executor(TSRMLS_D);
|
||||
void shutdown_executor(TSRMLS_D);
|
||||
ZEND_API void execute(zend_op_array *op_array TSRMLS_DC);
|
||||
ZEND_API void execute_internal(zend_execute_data *execute_data_ptr, int return_value_used TSRMLS_DC);
|
||||
ZEND_API int zend_is_true(zval *op);
|
||||
static inline void safe_free_zval_ptr(zval *p)
|
||||
{
|
||||
TSRMLS_FETCH();
|
||||
|
||||
if (p!=EG(uninitialized_zval_ptr)) {
|
||||
FREE_ZVAL(p);
|
||||
}
|
||||
}
|
||||
ZEND_API int zend_lookup_class(char *name, int name_length, zend_class_entry ***ce TSRMLS_DC);
|
||||
ZEND_API int zend_eval_string(char *str, zval *retval_ptr, char *string_name TSRMLS_DC);
|
||||
ZEND_API int zend_eval_string_ex(char *str, zval *retval_ptr, char *string_name, int handle_exceptions TSRMLS_DC);
|
||||
|
||||
static inline int i_zend_is_true(zval *op)
|
||||
{
|
||||
int result;
|
||||
|
||||
switch (op->type) {
|
||||
case IS_NULL:
|
||||
result = 0;
|
||||
break;
|
||||
case IS_LONG:
|
||||
case IS_BOOL:
|
||||
case IS_RESOURCE:
|
||||
result = (op->value.lval?1:0);
|
||||
break;
|
||||
case IS_DOUBLE:
|
||||
result = (op->value.dval ? 1 : 0);
|
||||
break;
|
||||
case IS_STRING:
|
||||
if (op->value.str.len == 0
|
||||
|| (op->value.str.len==1 && op->value.str.val[0]=='0')) {
|
||||
result = 0;
|
||||
} else {
|
||||
result = 1;
|
||||
}
|
||||
break;
|
||||
case IS_ARRAY:
|
||||
result = (zend_hash_num_elements(op->value.ht)?1:0);
|
||||
break;
|
||||
case IS_OBJECT:
|
||||
/* OBJ-TBI */
|
||||
result = 1;
|
||||
break;
|
||||
default:
|
||||
result = 0;
|
||||
break;
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
ZEND_API int zval_update_constant(zval **pp, void *arg TSRMLS_DC);
|
||||
|
||||
/* dedicated Zend executor functions - do not use! */
|
||||
static inline void zend_ptr_stack_clear_multiple(TSRMLS_D)
|
||||
{
|
||||
void **p = EG(argument_stack).top_element-2;
|
||||
int delete_count = (ulong) *p;
|
||||
|
||||
EG(argument_stack).top -= (delete_count+2);
|
||||
while (--delete_count>=0) {
|
||||
zval_ptr_dtor((zval **) --p);
|
||||
}
|
||||
EG(argument_stack).top_element = p;
|
||||
}
|
||||
|
||||
static inline int zend_ptr_stack_get_arg(int requested_arg, void **data TSRMLS_DC)
|
||||
{
|
||||
void **p = EG(argument_stack).top_element-2;
|
||||
int arg_count = (ulong) *p;
|
||||
|
||||
if (requested_arg>arg_count) {
|
||||
return FAILURE;
|
||||
}
|
||||
*data = (p-arg_count+requested_arg-1);
|
||||
return SUCCESS;
|
||||
}
|
||||
|
||||
void execute_new_code(TSRMLS_D);
|
||||
|
||||
|
||||
/* services */
|
||||
ZEND_API char *get_active_function_name(TSRMLS_D);
|
||||
ZEND_API char *zend_get_executed_filename(TSRMLS_D);
|
||||
ZEND_API uint zend_get_executed_lineno(TSRMLS_D);
|
||||
ZEND_API zend_bool zend_is_executing(TSRMLS_D);
|
||||
|
||||
ZEND_API void zend_set_timeout(long seconds);
|
||||
ZEND_API void zend_unset_timeout(TSRMLS_D);
|
||||
ZEND_API void zend_timeout(int dummy);
|
||||
ZEND_API zend_class_entry *zend_fetch_class(char *class_name, uint class_name_len, int fetch_type TSRMLS_DC);
|
||||
|
||||
#ifdef ZEND_WIN32
|
||||
void zend_init_timeout_thread();
|
||||
void zend_shutdown_timeout_thread();
|
||||
#define WM_REGISTER_ZEND_TIMEOUT (WM_USER+1)
|
||||
#define WM_UNREGISTER_ZEND_TIMEOUT (WM_USER+2)
|
||||
#endif
|
||||
|
||||
#define zendi_zval_copy_ctor(p) zval_copy_ctor(&(p))
|
||||
#define zendi_zval_dtor(p) zval_dtor(&(p))
|
||||
|
||||
#define active_opline (*EG(opline_ptr))
|
||||
|
||||
void zend_assign_to_variable_reference(znode *result, zval **variable_ptr_ptr, zval **value_ptr_ptr, temp_variable *Ts TSRMLS_DC);
|
||||
|
||||
#define IS_STRING_OFFSET 2
|
||||
|
||||
/* The following tries to resolve the classname of a zval of type object.
|
||||
* Since it is slow it should be only used in error messages.
|
||||
*/
|
||||
#define Z_OBJ_CLASS_NAME_P(zval) ((zval) && (zval)->type == IS_OBJECT && Z_OBJ_HT_P(zval)->get_class_entry != NULL && Z_OBJ_HT_P(zval)->get_class_entry(zval TSRMLS_CC) ? Z_OBJ_HT_P(zval)->get_class_entry(zval TSRMLS_CC)->name : "")
|
||||
|
||||
END_EXTERN_C()
|
||||
|
||||
#endif /* ZEND_EXECUTE_H */
|
||||
|
||||
/*
|
||||
* Local variables:
|
||||
* tab-width: 4
|
||||
* c-basic-offset: 4
|
||||
* indent-tabs-mode: t
|
||||
* End:
|
||||
*/
|
||||
File diff suppressed because it is too large.
Load diff
@@ -1,295 +0,0 @@
|
||||
/*
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2003 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 |
|
||||
| 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 |
|
||||
| obtain it through the world-wide-web, please send a note to |
|
||||
| license@zend.com so we can mail you a copy immediately. |
|
||||
+----------------------------------------------------------------------+
|
||||
| Authors: Andi Gutmans <andi@zend.com> |
|
||||
| Zeev Suraski <zeev@zend.com> |
|
||||
+----------------------------------------------------------------------+
|
||||
*/
|
||||
|
||||
/* $Id$ */
|
||||
|
||||
#include "zend_extensions.h"
|
||||
|
||||
ZEND_API zend_llist zend_extensions;
|
||||
static int last_resource_number;
|
||||
|
||||
int zend_load_extension(char *path)
|
||||
{
|
||||
#if ZEND_EXTENSIONS_SUPPORT
|
||||
DL_HANDLE handle;
|
||||
zend_extension *new_extension;
|
||||
zend_extension_version_info *extension_version_info;
|
||||
|
||||
handle = DL_LOAD(path);
|
||||
if (!handle) {
|
||||
#ifndef ZEND_WIN32
|
||||
fprintf(stderr, "Failed loading %s: %s\n", path, DL_ERROR());
|
||||
#else
|
||||
fprintf(stderr, "Failed loading %s\n", path);
|
||||
#endif
|
||||
return FAILURE;
|
||||
}
|
||||
|
||||
extension_version_info = (zend_extension_version_info *) DL_FETCH_SYMBOL(handle, "extension_version_info");
|
||||
if (!extension_version_info) {
|
||||
extension_version_info = (zend_extension_version_info *) DL_FETCH_SYMBOL(handle, "_extension_version_info");
|
||||
}
|
||||
new_extension = (zend_extension *) DL_FETCH_SYMBOL(handle, "zend_extension_entry");
|
||||
if (!new_extension) {
|
||||
new_extension = (zend_extension *) DL_FETCH_SYMBOL(handle, "_zend_extension_entry");
|
||||
}
|
||||
if (!extension_version_info || !new_extension) {
|
||||
fprintf(stderr, "%s doesn't appear to be a valid Zend extension\n", path);
|
||||
DL_UNLOAD(handle);
|
||||
return FAILURE;
|
||||
}
|
||||
|
||||
|
||||
/* allow extension to proclaim compatibility with any Zend version */
|
||||
if (extension_version_info->zend_extension_api_no != ZEND_EXTENSION_API_NO &&(!new_extension->api_no_check || new_extension->api_no_check(ZEND_EXTENSION_API_NO) != SUCCESS)) {
|
||||
if (extension_version_info->zend_extension_api_no > ZEND_EXTENSION_API_NO) {
|
||||
fprintf(stderr, "%s requires Zend Engine API version %d.\n"
|
||||
"The Zend Engine API version %d which is installed, is outdated.\n\n",
|
||||
new_extension->name,
|
||||
extension_version_info->zend_extension_api_no,
|
||||
ZEND_EXTENSION_API_NO);
|
||||
DL_UNLOAD(handle);
|
||||
return FAILURE;
|
||||
} else if (extension_version_info->zend_extension_api_no < ZEND_EXTENSION_API_NO) {
|
||||
fprintf(stderr, "%s requires Zend Engine API version %d.\n"
|
||||
"The Zend Engine API version %d which is installed, is newer.\n"
|
||||
"Contact %s at %s for a later version of %s.\n\n",
|
||||
new_extension->name,
|
||||
extension_version_info->zend_extension_api_no,
|
||||
ZEND_EXTENSION_API_NO,
|
||||
new_extension->author,
|
||||
new_extension->URL,
|
||||
new_extension->name);
|
||||
DL_UNLOAD(handle);
|
||||
return FAILURE;
|
||||
}
|
||||
} else if (ZTS_V!=extension_version_info->thread_safe) {
|
||||
fprintf(stderr, "Cannot load %s - it %s thread safe, whereas Zend %s\n",
|
||||
new_extension->name,
|
||||
(extension_version_info->thread_safe?"is":"isn't"),
|
||||
(ZTS_V?"is":"isn't"));
|
||||
DL_UNLOAD(handle);
|
||||
return FAILURE;
|
||||
} else if (ZEND_DEBUG!=extension_version_info->debug) {
|
||||
fprintf(stderr, "Cannot load %s - it %s debug information, whereas Zend %s\n",
|
||||
new_extension->name,
|
||||
(extension_version_info->debug?"contains":"does not contain"),
|
||||
(ZEND_DEBUG?"does":"does not"));
|
||||
DL_UNLOAD(handle);
|
||||
return FAILURE;
|
||||
}
|
||||
|
||||
return zend_register_extension(new_extension, handle);
|
||||
#else
|
||||
fprintf(stderr, "Extensions are not supported on this platform.\n");
|
||||
return FAILURE;
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
int zend_register_extension(zend_extension *new_extension, DL_HANDLE handle)
|
||||
{
|
||||
#if ZEND_EXTENSIONS_SUPPORT
|
||||
zend_extension extension;
|
||||
|
||||
extension = *new_extension;
|
||||
extension.handle = handle;
|
||||
|
||||
zend_extension_dispatch_message(ZEND_EXTMSG_NEW_EXTENSION, &extension);
|
||||
|
||||
zend_llist_add_element(&zend_extensions, &extension);
|
||||
|
||||
/*fprintf(stderr, "Loaded %s, version %s\n", extension.name, extension.version);*/
|
||||
#endif
|
||||
|
||||
return SUCCESS;
|
||||
}
|
||||
|
||||
|
||||
static void zend_extension_shutdown(zend_extension *extension TSRMLS_DC)
|
||||
{
|
||||
#if ZEND_EXTENSIONS_SUPPORT
|
||||
if (extension->shutdown) {
|
||||
extension->shutdown(extension);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
static int zend_extension_startup(zend_extension *extension)
|
||||
{
|
||||
#if ZEND_EXTENSIONS_SUPPORT
|
||||
if (extension->startup) {
|
||||
if (extension->startup(extension)!=SUCCESS) {
|
||||
return 1;
|
||||
}
|
||||
zend_append_version_info(extension);
|
||||
}
|
||||
#endif
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
int zend_startup_extensions_mechanism()
|
||||
{
|
||||
/* Startup extensions mechanism */
|
||||
zend_llist_init(&zend_extensions, sizeof(zend_extension), (void (*)(void *)) zend_extension_dtor, 1);
|
||||
last_resource_number = 0;
|
||||
return SUCCESS;
|
||||
}
|
||||
|
||||
|
||||
int zend_startup_extensions()
|
||||
{
|
||||
zend_llist_apply_with_del(&zend_extensions, (int (*)(void *)) zend_extension_startup);
|
||||
return SUCCESS;
|
||||
}
|
||||
|
||||
|
||||
void zend_shutdown_extensions(TSRMLS_D)
|
||||
{
|
||||
zend_llist_apply(&zend_extensions, (llist_apply_func_t) zend_extension_shutdown TSRMLS_CC);
|
||||
zend_llist_destroy(&zend_extensions);
|
||||
}
|
||||
|
||||
|
||||
void zend_extension_dtor(zend_extension *extension)
|
||||
{
|
||||
#if ZEND_EXTENSIONS_SUPPORT && !ZEND_DEBUG
|
||||
if (extension->handle) {
|
||||
DL_UNLOAD(extension->handle);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
static void zend_extension_message_dispatcher(zend_extension *extension, int num_args, va_list args TSRMLS_DC)
|
||||
{
|
||||
int message;
|
||||
void *arg;
|
||||
|
||||
if (!extension->message_handler || num_args!=2) {
|
||||
return;
|
||||
}
|
||||
message = va_arg(args, int);
|
||||
arg = va_arg(args, void *);
|
||||
extension->message_handler(message, arg);
|
||||
}
|
||||
|
||||
|
||||
ZEND_API void zend_extension_dispatch_message(int message, void *arg)
|
||||
{
|
||||
TSRMLS_FETCH();
|
||||
|
||||
zend_llist_apply_with_arguments(&zend_extensions, (llist_apply_with_args_func_t) zend_extension_message_dispatcher TSRMLS_CC, 2, message, arg);
|
||||
}
|
||||
|
||||
|
||||
ZEND_API int zend_get_resource_handle(zend_extension *extension)
|
||||
{
|
||||
if (last_resource_number<ZEND_MAX_RESERVED_RESOURCES) {
|
||||
extension->resource_number = last_resource_number;
|
||||
return last_resource_number++;
|
||||
} else {
|
||||
return -1;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
ZEND_API zend_extension *zend_get_extension(char *extension_name)
|
||||
{
|
||||
zend_llist_element *element;
|
||||
|
||||
for (element = zend_extensions.head; element; element = element->next) {
|
||||
zend_extension *extension = (zend_extension *) element->data;
|
||||
|
||||
if (!strcmp(extension->name, extension_name)) {
|
||||
return extension;
|
||||
}
|
||||
}
|
||||
return NULL;
|
||||
}
|
||||
|
||||
/*
|
||||
* Support for dynamic loading of MH_BUNDLEs on Darwin / Mac OS X
|
||||
*
|
||||
*/
|
||||
|
||||
#if HAVE_MACH_O_DYLD_H
|
||||
|
||||
void *zend_mh_bundle_load(char* bundle_path)
|
||||
{
|
||||
NSObjectFileImage bundle_image;
|
||||
NSModule bundle_handle;
|
||||
NSSymbol bundle_init_nssymbol;
|
||||
void (*bundle_init)(void);
|
||||
|
||||
if (NSCreateObjectFileImageFromFile(bundle_path, &bundle_image) != NSObjectFileImageSuccess) {
|
||||
return NULL;
|
||||
}
|
||||
|
||||
bundle_handle = NSLinkModule(bundle_image, bundle_path, NSLINKMODULE_OPTION_PRIVATE);
|
||||
NSDestroyObjectFileImage(bundle_image);
|
||||
|
||||
/* call the init function of the bundle */
|
||||
bundle_init_nssymbol = NSLookupSymbolInModule(bundle_handle, "__init");
|
||||
if (bundle_init_nssymbol != NULL) {
|
||||
bundle_init = NSAddressOfSymbol(bundle_init_nssymbol);
|
||||
bundle_init();
|
||||
}
|
||||
|
||||
return bundle_handle;
|
||||
}
|
||||
|
||||
int zend_mh_bundle_unload(void *bundle_handle)
|
||||
{
|
||||
NSSymbol bundle_fini_nssymbol;
|
||||
void (*bundle_fini)(void);
|
||||
|
||||
/* call the fini function of the bundle */
|
||||
bundle_fini_nssymbol = NSLookupSymbolInModule(bundle_handle, "__fini");
|
||||
if (bundle_fini_nssymbol != NULL) {
|
||||
bundle_fini = NSAddressOfSymbol(bundle_fini_nssymbol);
|
||||
bundle_fini();
|
||||
}
|
||||
|
||||
return (int) NSUnLinkModule(bundle_handle, NULL);
|
||||
}
|
||||
|
||||
void *zend_mh_bundle_symbol(void *bundle_handle, const char *symbol_name)
|
||||
{
|
||||
NSSymbol symbol;
|
||||
symbol = NSLookupSymbolInModule(bundle_handle, symbol_name);
|
||||
return NSAddressOfSymbol(symbol);
|
||||
}
|
||||
|
||||
const char *zend_mh_bundle_error(void)
|
||||
{
|
||||
/* Witness the state of the art error reporting */
|
||||
return NULL;
|
||||
}
|
||||
|
||||
#endif /* HAVE_MACH_O_DYLD_H */
|
||||
|
||||
/*
|
||||
* Local variables:
|
||||
* tab-width: 4
|
||||
* c-basic-offset: 4
|
||||
* indent-tabs-mode: t
|
||||
* End:
|
||||
*/
|
||||
@@ -1,125 +0,0 @@
|
||||
/*
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2003 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 |
|
||||
| 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 |
|
||||
| obtain it through the world-wide-web, please send a note to |
|
||||
| license@zend.com so we can mail you a copy immediately. |
|
||||
+----------------------------------------------------------------------+
|
||||
| Authors: Andi Gutmans <andi@zend.com> |
|
||||
| Zeev Suraski <zeev@zend.com> |
|
||||
+----------------------------------------------------------------------+
|
||||
*/
|
||||
|
||||
/* $Id$ */
|
||||
|
||||
#ifndef ZEND_EXTENSIONS_H
|
||||
#define ZEND_EXTENSIONS_H
|
||||
|
||||
#include "zend_compile.h"
|
||||
|
||||
#define ZEND_EXTENSION_API_NO 90021012
|
||||
|
||||
typedef struct _zend_extension_version_info {
|
||||
int zend_extension_api_no;
|
||||
char *required_zend_version;
|
||||
unsigned char thread_safe;
|
||||
unsigned char debug;
|
||||
} zend_extension_version_info;
|
||||
|
||||
|
||||
typedef struct _zend_extension zend_extension;
|
||||
|
||||
/* Typedef's for zend_extension function pointers */
|
||||
typedef int (*startup_func_t)(zend_extension *extension);
|
||||
typedef void (*shutdown_func_t)(zend_extension *extension);
|
||||
typedef void (*activate_func_t)(void);
|
||||
typedef void (*deactivate_func_t)(void);
|
||||
|
||||
typedef void (*message_handler_func_t)(int message, void *arg);
|
||||
|
||||
typedef void (*op_array_handler_func_t)(zend_op_array *op_array);
|
||||
|
||||
typedef void (*statement_handler_func_t)(zend_op_array *op_array);
|
||||
typedef void (*fcall_begin_handler_func_t)(zend_op_array *op_array);
|
||||
typedef void (*fcall_end_handler_func_t)(zend_op_array *op_array);
|
||||
|
||||
typedef void (*op_array_ctor_func_t)(zend_op_array *op_array);
|
||||
typedef void (*op_array_dtor_func_t)(zend_op_array *op_array);
|
||||
|
||||
struct _zend_extension {
|
||||
char *name;
|
||||
char *version;
|
||||
char *author;
|
||||
char *URL;
|
||||
char *copyright;
|
||||
|
||||
startup_func_t startup;
|
||||
shutdown_func_t shutdown;
|
||||
activate_func_t activate;
|
||||
deactivate_func_t deactivate;
|
||||
|
||||
message_handler_func_t message_handler;
|
||||
|
||||
op_array_handler_func_t op_array_handler;
|
||||
|
||||
statement_handler_func_t statement_handler;
|
||||
fcall_begin_handler_func_t fcall_begin_handler;
|
||||
fcall_end_handler_func_t fcall_end_handler;
|
||||
|
||||
op_array_ctor_func_t op_array_ctor;
|
||||
op_array_dtor_func_t op_array_dtor;
|
||||
|
||||
int (*api_no_check)(int api_no);
|
||||
void *reserved2;
|
||||
void *reserved3;
|
||||
void *reserved4;
|
||||
void *reserved5;
|
||||
void *reserved6;
|
||||
void *reserved7;
|
||||
void *reserved8;
|
||||
|
||||
DL_HANDLE handle;
|
||||
int resource_number;
|
||||
};
|
||||
|
||||
|
||||
ZEND_API int zend_get_resource_handle(zend_extension *extension);
|
||||
ZEND_API void zend_extension_dispatch_message(int message, void *arg);
|
||||
|
||||
#define ZEND_EXTMSG_NEW_EXTENSION 1
|
||||
|
||||
|
||||
#define ZEND_EXTENSION() \
|
||||
ZEND_EXT_API zend_extension_version_info extension_version_info = { ZEND_EXTENSION_API_NO, ZEND_VERSION, ZTS_V, ZEND_DEBUG }
|
||||
|
||||
#define STANDARD_ZEND_EXTENSION_PROPERTIES NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, -1
|
||||
#define COMPAT_ZEND_EXTENSION_PROPERTIES NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, -1
|
||||
|
||||
|
||||
ZEND_API extern zend_llist zend_extensions;
|
||||
|
||||
void zend_extension_dtor(zend_extension *extension);
|
||||
ZEND_API int zend_load_extension(char *path);
|
||||
ZEND_API int zend_register_extension(zend_extension *new_extension, DL_HANDLE handle);
|
||||
void zend_append_version_info(zend_extension *extension);
|
||||
int zend_startup_extensions_mechanism(void);
|
||||
int zend_startup_extensions(void);
|
||||
void zend_shutdown_extensions(TSRMLS_D);
|
||||
ZEND_API zend_extension *zend_get_extension(char *extension_name);
|
||||
|
||||
#endif /* ZEND_EXTENSIONS_H */
|
||||
|
||||
/*
|
||||
* Local variables:
|
||||
* tab-width: 4
|
||||
* c-basic-offset: 4
|
||||
* indent-tabs-mode: t
|
||||
* End:
|
||||
*/
|
||||
@@ -1,142 +0,0 @@
|
||||
/*
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2003 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 |
|
||||
| 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 |
|
||||
| obtain it through the world-wide-web, please send a note to |
|
||||
| license@zend.com so we can mail you a copy immediately. |
|
||||
+----------------------------------------------------------------------+
|
||||
| Authors: Andi Gutmans <andi@zend.com> |
|
||||
| Zeev Suraski <zeev@zend.com> |
|
||||
+----------------------------------------------------------------------+
|
||||
*/
|
||||
|
||||
/* $Id$ */
|
||||
|
||||
#ifndef ZEND_FAST_CACHE_H
|
||||
#define ZEND_FAST_CACHE_H
|
||||
|
||||
#ifndef ZEND_ENABLE_FAST_CACHE
|
||||
# if ZEND_DEBUG
|
||||
# define ZEND_ENABLE_FAST_CACHE 0
|
||||
# else
|
||||
# define ZEND_ENABLE_FAST_CACHE 0
|
||||
# endif
|
||||
#endif
|
||||
|
||||
typedef struct _zend_fast_cache_list_entry {
|
||||
struct _zend_fast_cache_list_entry *next;
|
||||
} zend_fast_cache_list_entry;
|
||||
|
||||
#define MAX_FAST_CACHE_TYPES 4
|
||||
|
||||
|
||||
#define ZVAL_CACHE_LIST 0
|
||||
#define HASHTABLE_CACHE_LIST 1
|
||||
|
||||
#if ZEND_ENABLE_FAST_CACHE
|
||||
|
||||
|
||||
#include "zend_globals.h"
|
||||
#include "zend_globals_macros.h"
|
||||
#include "zend_alloc.h"
|
||||
|
||||
|
||||
#if ZEND_DEBUG
|
||||
# define RECORD_ZVAL_CACHE_HIT(fc_type) AG(fast_cache_stats)[fc_type][1]++;
|
||||
# define RECORD_ZVAL_CACHE_MISS(fc_type) AG(fast_cache_stats)[fc_type][0]++;
|
||||
#else
|
||||
# define RECORD_ZVAL_CACHE_HIT(fc_type)
|
||||
# define RECORD_ZVAL_CACHE_MISS(fc_type)
|
||||
#endif
|
||||
|
||||
|
||||
#define ZEND_FAST_ALLOC(p, type, fc_type) \
|
||||
{ \
|
||||
TSRMLS_FETCH(); \
|
||||
\
|
||||
if (((p) = (type *) AG(fast_cache_list_head)[fc_type])) { \
|
||||
AG(fast_cache_list_head)[fc_type] = ((zend_fast_cache_list_entry *) AG(fast_cache_list_head)[fc_type])->next; \
|
||||
RECORD_ZVAL_CACHE_HIT(fc_type); \
|
||||
} else { \
|
||||
(p) = (type *) emalloc(sizeof(type)); \
|
||||
RECORD_ZVAL_CACHE_MISS(fc_type); \
|
||||
} \
|
||||
}
|
||||
|
||||
|
||||
#define ZEND_FAST_FREE(p, fc_type) \
|
||||
{ \
|
||||
TSRMLS_FETCH(); \
|
||||
\
|
||||
((zend_fast_cache_list_entry *) (p))->next = (zend_fast_cache_list_entry *) AG(fast_cache_list_head)[fc_type]; \
|
||||
AG(fast_cache_list_head)[fc_type] = (zend_fast_cache_list_entry *) (p); \
|
||||
}
|
||||
|
||||
#define ZEND_FAST_ALLOC_REL(p, type, fc_type) \
|
||||
ZEND_FAST_ALLOC(p, type, fc_type)
|
||||
|
||||
#define ZEND_FAST_FREE_REL(p, fc_type) \
|
||||
ZEND_FAST_FREE(p, fc_type)
|
||||
|
||||
|
||||
#else /* !ZEND_ENABLE_FAST_CACHE */
|
||||
|
||||
#define ZEND_FAST_ALLOC(p, type, fc_type) \
|
||||
(p) = (type *) emalloc(sizeof(type))
|
||||
|
||||
#define ZEND_FAST_FREE(p, fc_type) \
|
||||
efree(p)
|
||||
|
||||
#define ZEND_FAST_ALLOC_REL(p, type, fc_type) \
|
||||
(p) = (type *) emalloc_rel(sizeof(type))
|
||||
|
||||
#define ZEND_FAST_FREE_REL(p, fc_type) \
|
||||
efree_rel(p)
|
||||
|
||||
#endif /* ZEND_ENABLE_FAST_CACHE */
|
||||
|
||||
|
||||
|
||||
|
||||
/* fast cache for zval's */
|
||||
#define ALLOC_ZVAL(z) \
|
||||
ZEND_FAST_ALLOC(z, zval, ZVAL_CACHE_LIST)
|
||||
|
||||
#define FREE_ZVAL(z) \
|
||||
ZEND_FAST_FREE(z, ZVAL_CACHE_LIST)
|
||||
|
||||
#define ALLOC_ZVAL_REL(z) \
|
||||
ZEND_FAST_ALLOC_REL(z, zval, ZVAL_CACHE_LIST)
|
||||
|
||||
#define FREE_ZVAL_REL(z) \
|
||||
ZEND_FAST_FREE_REL(z, ZVAL_CACHE_LIST)
|
||||
|
||||
/* fast cache for HashTables */
|
||||
#define ALLOC_HASHTABLE(ht) \
|
||||
ZEND_FAST_ALLOC(ht, HashTable, HASHTABLE_CACHE_LIST)
|
||||
|
||||
#define FREE_HASHTABLE(ht) \
|
||||
ZEND_FAST_FREE(ht, HASHTABLE_CACHE_LIST)
|
||||
|
||||
#define ALLOC_HASHTABLE_REL(ht) \
|
||||
ZEND_FAST_ALLOC_REL(ht, HashTable, HASHTABLE_CACHE_LIST)
|
||||
|
||||
#define FREE_HASHTABLE_REL(ht) \
|
||||
ZEND_FAST_FREE_REL(ht, HASHTABLE_CACHE_LIST)
|
||||
|
||||
#endif /* ZEND_FAST_CACHE_H */
|
||||
|
||||
/*
|
||||
* Local variables:
|
||||
* tab-width: 4
|
||||
* c-basic-offset: 4
|
||||
* indent-tabs-mode: t
|
||||
* End:
|
||||
*/
|
||||
@@ -1,316 +0,0 @@
|
||||
/*
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2003 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 |
|
||||
| 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 |
|
||||
| obtain it through the world-wide-web, please send a note to |
|
||||
| license@zend.com so we can mail you a copy immediately. |
|
||||
+----------------------------------------------------------------------+
|
||||
| Authors: Andi Gutmans <andi@zend.com> |
|
||||
| Zeev Suraski <zeev@zend.com> |
|
||||
+----------------------------------------------------------------------+
|
||||
*/
|
||||
|
||||
/* $Id$ */
|
||||
|
||||
#ifndef ZEND_GLOBALS_H
|
||||
#define ZEND_GLOBALS_H
|
||||
|
||||
|
||||
#include <setjmp.h>
|
||||
|
||||
#include "zend_globals_macros.h"
|
||||
|
||||
#include "zend_stack.h"
|
||||
#include "zend_ptr_stack.h"
|
||||
#include "zend_hash.h"
|
||||
#include "zend_llist.h"
|
||||
#include "zend_fast_cache.h"
|
||||
#include "zend_objects.h"
|
||||
#include "zend_objects_API.h"
|
||||
|
||||
#ifdef ZEND_MULTIBYTE
|
||||
#include "zend_multibyte.h"
|
||||
#endif /* ZEND_MULTIBYTE */
|
||||
|
||||
/* Define ZTS if you want a thread-safe Zend */
|
||||
/*#undef ZTS*/
|
||||
|
||||
#ifdef ZTS
|
||||
|
||||
BEGIN_EXTERN_C()
|
||||
ZEND_API extern int compiler_globals_id;
|
||||
ZEND_API extern int executor_globals_id;
|
||||
ZEND_API extern int alloc_globals_id;
|
||||
END_EXTERN_C()
|
||||
|
||||
#endif
|
||||
|
||||
#define SYMTABLE_CACHE_SIZE 32
|
||||
|
||||
|
||||
#include "zend_compile.h"
|
||||
|
||||
/* excpt.h on Digital Unix 4.0 defines function_table */
|
||||
#undef function_table
|
||||
|
||||
|
||||
typedef struct _zend_declarables {
|
||||
zval ticks;
|
||||
} zend_declarables;
|
||||
|
||||
|
||||
struct _zend_compiler_globals {
|
||||
zend_stack bp_stack;
|
||||
zend_stack switch_cond_stack;
|
||||
zend_stack foreach_copy_stack;
|
||||
zend_stack object_stack;
|
||||
zend_stack declare_stack;
|
||||
|
||||
zend_class_entry *active_class_entry;
|
||||
|
||||
/* variables for list() compilation */
|
||||
zend_llist list_llist;
|
||||
zend_llist dimension_llist;
|
||||
zend_stack list_stack;
|
||||
|
||||
zend_stack function_call_stack;
|
||||
|
||||
char *compiled_filename;
|
||||
|
||||
int zend_lineno;
|
||||
int comment_start_line;
|
||||
char *heredoc;
|
||||
int heredoc_len;
|
||||
|
||||
zend_op_array *active_op_array;
|
||||
|
||||
HashTable *function_table; /* function symbol table */
|
||||
HashTable *class_table; /* class table */
|
||||
|
||||
HashTable filenames_table;
|
||||
|
||||
HashTable *auto_globals;
|
||||
|
||||
zend_bool in_compilation;
|
||||
zend_bool short_tags;
|
||||
zend_bool asp_tags;
|
||||
zend_bool allow_call_time_pass_reference;
|
||||
|
||||
zend_declarables declarables;
|
||||
|
||||
/* For extensions support */
|
||||
zend_bool extended_info; /* generate extension information for debugger/profiler */
|
||||
zend_bool handle_op_arrays; /* run op_arrays through op_array handlers */
|
||||
|
||||
zend_bool unclean_shutdown;
|
||||
|
||||
zend_bool ini_parser_unbuffered_errors;
|
||||
|
||||
zend_llist open_files;
|
||||
|
||||
zend_llist *throw_list;
|
||||
long catch_begin;
|
||||
|
||||
struct _zend_ini_parser_param *ini_parser_param;
|
||||
|
||||
int interactive;
|
||||
|
||||
zend_uint start_lineno;
|
||||
zend_bool increment_lineno;
|
||||
|
||||
znode implementing_class;
|
||||
|
||||
zend_uint access_type;
|
||||
|
||||
char *doc_comment;
|
||||
zend_uint doc_comment_len;
|
||||
|
||||
#ifdef ZEND_MULTIBYTE
|
||||
zend_encoding **script_encoding_list;
|
||||
int script_encoding_list_size;
|
||||
|
||||
zend_encoding *internal_encoding;
|
||||
|
||||
/* multibyte utility functions */
|
||||
zend_encoding_detector encoding_detector;
|
||||
zend_encoding_converter encoding_converter;
|
||||
zend_encoding_oddlen encoding_oddlen;
|
||||
#endif /* ZEND_MULTIBYTE */
|
||||
};
|
||||
|
||||
|
||||
struct _zend_executor_globals {
|
||||
zval **return_value_ptr_ptr;
|
||||
|
||||
zval uninitialized_zval;
|
||||
zval *uninitialized_zval_ptr;
|
||||
|
||||
zval error_zval;
|
||||
zval *error_zval_ptr;
|
||||
|
||||
zend_function_state *function_state_ptr;
|
||||
zend_ptr_stack arg_types_stack;
|
||||
|
||||
/* symbol table cache */
|
||||
HashTable *symtable_cache[SYMTABLE_CACHE_SIZE];
|
||||
HashTable **symtable_cache_limit;
|
||||
HashTable **symtable_cache_ptr;
|
||||
|
||||
zend_op **opline_ptr;
|
||||
|
||||
HashTable *active_symbol_table;
|
||||
HashTable symbol_table; /* main symbol table */
|
||||
|
||||
HashTable included_files; /* files already included */
|
||||
|
||||
jmp_buf bailout;
|
||||
|
||||
int error_reporting;
|
||||
int orig_error_reporting;
|
||||
int exit_status;
|
||||
|
||||
zend_op_array *active_op_array;
|
||||
|
||||
HashTable *function_table; /* function symbol table */
|
||||
HashTable *class_table; /* class table */
|
||||
HashTable *zend_constants; /* constants table */
|
||||
|
||||
zend_class_entry *scope;
|
||||
|
||||
zval *This;
|
||||
|
||||
long precision;
|
||||
|
||||
int ticks_count;
|
||||
|
||||
zend_bool in_execution;
|
||||
zend_bool bailout_set;
|
||||
zend_bool full_tables_cleanup;
|
||||
zend_bool implicit_clone;
|
||||
|
||||
/* for extended information support */
|
||||
zend_bool no_extensions;
|
||||
|
||||
#ifdef ZEND_WIN32
|
||||
zend_bool timed_out;
|
||||
#endif
|
||||
|
||||
HashTable regular_list;
|
||||
HashTable persistent_list;
|
||||
|
||||
zend_ptr_stack argument_stack;
|
||||
zval *free_op1, *free_op2;
|
||||
int (*unary_op)(zval *result, zval *op1);
|
||||
int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC);
|
||||
|
||||
zval *garbage[2];
|
||||
int garbage_ptr;
|
||||
|
||||
zval *user_error_handler;
|
||||
zval *user_exception_handler;
|
||||
zend_ptr_stack user_error_handlers;
|
||||
zend_ptr_stack user_exception_handlers;
|
||||
|
||||
/* timeout support */
|
||||
int timeout_seconds;
|
||||
|
||||
int lambda_count;
|
||||
|
||||
HashTable *ini_directives;
|
||||
zend_objects_store objects_store;
|
||||
zval *exception;
|
||||
|
||||
struct _zend_execute_data *current_execute_data;
|
||||
|
||||
zend_property_info std_property_info;
|
||||
|
||||
/* locale stuff */
|
||||
char float_separator[1];
|
||||
|
||||
void *reserved[ZEND_MAX_RESERVED_RESOURCES];
|
||||
};
|
||||
|
||||
#include "zend_mm.h"
|
||||
|
||||
struct _zend_alloc_globals {
|
||||
zend_mem_header *head; /* standard list */
|
||||
void *cache[MAX_CACHED_MEMORY][MAX_CACHED_ENTRIES];
|
||||
unsigned int cache_count[MAX_CACHED_MEMORY];
|
||||
void *fast_cache_list_head[MAX_FAST_CACHE_TYPES];
|
||||
|
||||
#ifdef ZEND_WIN32
|
||||
HANDLE memory_heap;
|
||||
#endif
|
||||
|
||||
#if ZEND_DEBUG
|
||||
/* for performance tuning */
|
||||
int cache_stats[MAX_CACHED_MEMORY][2];
|
||||
int fast_cache_stats[MAX_FAST_CACHE_TYPES][2];
|
||||
#endif
|
||||
#if MEMORY_LIMIT
|
||||
unsigned int memory_limit;
|
||||
unsigned int allocated_memory;
|
||||
unsigned int allocated_memory_peak;
|
||||
unsigned char memory_exhausted;
|
||||
#endif
|
||||
#ifdef ZEND_MM
|
||||
zend_mm_heap mm_heap;
|
||||
#endif
|
||||
};
|
||||
|
||||
struct _zend_scanner_globals {
|
||||
zend_file_handle *yy_in;
|
||||
zend_file_handle *yy_out;
|
||||
int yy_leng;
|
||||
char *yy_text;
|
||||
struct yy_buffer_state *current_buffer;
|
||||
char *c_buf_p;
|
||||
int init;
|
||||
int start;
|
||||
int lineno;
|
||||
char _yy_hold_char;
|
||||
int yy_n_chars;
|
||||
int _yy_did_buffer_switch_on_eof;
|
||||
int _yy_last_accepting_state; /* Must be of the same type as yy_state_type,
|
||||
* if for whatever reason it's no longer int!
|
||||
*/
|
||||
char *_yy_last_accepting_cpos;
|
||||
int _yy_more_flag;
|
||||
int _yy_more_len;
|
||||
int yy_start_stack_ptr;
|
||||
int yy_start_stack_depth;
|
||||
int *yy_start_stack;
|
||||
|
||||
#ifdef ZEND_MULTIBYTE
|
||||
/* original (unfiltered) script */
|
||||
char *script_org;
|
||||
int script_org_size;
|
||||
|
||||
/* filtered script */
|
||||
char *script_filtered;
|
||||
int script_filtered_size;
|
||||
|
||||
/* input/ouput filters */
|
||||
zend_encoding_filter input_filter;
|
||||
zend_encoding_filter output_filter;
|
||||
zend_encoding *script_encoding;
|
||||
zend_encoding *internal_encoding;
|
||||
#endif /* ZEND_MULTIBYTE */
|
||||
};
|
||||
|
||||
#endif /* ZEND_GLOBALS_H */
|
||||
|
||||
/*
|
||||
* Local variables:
|
||||
* tab-width: 4
|
||||
* c-basic-offset: 4
|
||||
* indent-tabs-mode: t
|
||||
* End:
|
||||
*/
|
||||
@@ -1,117 +0,0 @@
|
||||
/*
|
||||
+----------------------------------------------------------------------+
|
||||
| Zend Engine |
|
||||
+----------------------------------------------------------------------+
|
||||
| Copyright (c) 1998-2003 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 |
|
||||
| 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 |
|
||||
| obtain it through the world-wide-web, please send a note to |
|
||||
| license@zend.com so we can mail you a copy immediately. |
|
||||
+----------------------------------------------------------------------+
|
||||
| Authors: Andi Gutmans <andi@zend.com> |
|
||||
| Zeev Suraski <zeev@zend.com> |
|
||||
+----------------------------------------------------------------------+
|
||||
*/
|
||||
|
||||
/* $Id$ */
|
||||
|
||||
#ifndef ZEND_GLOBALS_MACROS_H
|
||||
#define ZEND_GLOBALS_MACROS_H
|
||||
|
||||
typedef struct _zend_compiler_globals zend_compiler_globals;
|
||||
typedef struct _zend_executor_globals zend_executor_globals;
|
||||
typedef struct _zend_alloc_globals zend_alloc_globals;
|
||||
typedef struct _zend_scanner_globals zend_scanner_globals;
|
||||
|
||||
/* Compiler */
|
||||
#ifdef ZTS
|
||||
# define CG(v) TSRMG(compiler_globals_id, zend_compiler_globals *, v)
|
||||
BEGIN_EXTERN_C()
|
||||
int zendparse(void *compiler_globals);
|
||||
END_EXTERN_C()
|
||||
#else
|
||||
# define CG(v) (compiler_globals.v)
|
||||
extern ZEND_API struct _zend_compiler_globals compiler_globals;
|
||||
int zendparse(void);
|
||||
#endif
|
||||
|
||||
|
||||
/* Executor */
|
||||
#ifdef ZTS
|
||||
# define EG(v) TSRMG(executor_globals_id, zend_executor_globals *, v)
|
||||
#else
|
||||
# define EG(v) (executor_globals.v)
|
||||
extern ZEND_API zend_executor_globals executor_globals;
|
||||
#endif
|
||||
|
||||
|
||||
/* Memory Manager */
|
||||
#ifdef ZTS
|
||||
# define AG(v) TSRMG(alloc_globals_id, zend_alloc_globals *, v)
|
||||
#else
|
||||
# define AG(v) (alloc_globals.v)
|
||||
extern ZEND_API zend_alloc_globals alloc_globals;
|
||||
#endif
|
||||
|
||||
|
||||
/* Language Scanner */
|
||||
#ifdef ZTS
|
||||
# define LANG_SCNG(v) TSRMG(language_scanner_globals_id, zend_scanner_globals *, v)
|
||||
extern ZEND_API ts_rsrc_id language_scanner_globals_id;
|
||||
#else
|
||||
# define LANG_SCNG(v) (language_scanner_globals.v)
|
||||
extern ZEND_API zend_scanner_globals language_scanner_globals;
|
||||
#endif
|
||||
|
||||
|
||||
/* INI Scanner */
|
||||
#ifdef ZTS
|
||||
# define INI_SCNG(v) TSRMG(ini_scanner_globals_id, zend_scanner_globals *, v)
|
||||
extern ZEND_API ts_rsrc_id ini_scanner_globals_id;
|
||||
#else
|
||||
# define INI_SCNG(v) (ini_scanner_globals.v)
|
||||
extern ZEND_API zend_scanner_globals ini_scanner_globals;
|
||||
#endif
|
||||
|
||||
|
||||
/* For limited downwards source compatibility */
|
||||
#define CLS_FETCH()
|
||||
#define ELS_FETCH()
|
||||
#define ALS_FETCH()
|
||||
#define PLS_FETCH()
|
||||
#define SLS_FETCH()
|
||||
#define CLS_D
|
||||
#define ELS_D
|
||||
#define ALS_D
|
||||
#define PLS_D
|
||||
#define SLS_D
|
||||
#define CLS_DC
|
||||
#define ELS_DC
|
||||
#define ALS_DC
|
||||
#define PLS_DC
|
||||
#define SLS_DC
|
||||
#define CLS_C
|
||||
#define ELS_C
|
||||
#define ALS_C
|
||||
#define PLS_C
|
||||
#define SLS_C
|
||||
#define CLS_CC
|
||||
#define ELS_CC
|
||||
#define ALS_CC
|
||||
#define PLS_CC
|
||||
#define SLS_CC
|
||||
|
||||
|
||||
#endif /* ZEND_GLOBALS_MACROS_H */
|
||||
|
||||
/*
|
||||
* Local variables:
|
||||
* tab-width: 4
|
||||
* c-basic-offset: 4
|
||||
* indent-tabs-mode: t
|
||||
* End:
|
||||
*/
|
||||
Loaded 100 of 2041 files, more files were not shown because too many files have changed in this diff.
Show more
Reference in new issue
Block a user