Commit Graph

76874 Commits

Author SHA1 Message Date
Dmitry Stogov
1e161a9c0f Merge branch 'PHP-5.5' into PHP-5.6
* PHP-5.5:
  Revered func_get_args() changes, because they were not completly transparent and broke some tricky PHP code that worked because of luck before php-5.5.6 (see Bug #66107). The changes are going to be kept in PHP-5.6.
2013-12-10 16:08:46 +04:00
Dmitry Stogov
a46f644b3a Revered func_get_args() changes, because they were not completly transparent and broke some tricky PHP code that worked because of luck before php-5.5.6 (see Bug #66107). The changes are going to be kept in PHP-5.6. 2013-12-10 16:02:59 +04:00
Dmitry Stogov
4c3492b050 Merge branch 'PHP-5.6' of git.php.net:php-src into PHP-5.6
* 'PHP-5.6' of git.php.net:php-src:
  Zend: fix overflow handling bug in non-x86 fast_add_function()
2013-12-10 15:16:30 +04:00
Dmitry Stogov
49d7e98025 Fixed memory leaks introdused by:
commit 611da37617
	Author: Igor Wiedler <igor@wiedler.ch>
	Date:   Sat Nov 9 13:48:23 2013 -0500
2013-12-10 15:13:53 +04:00
Ard Biesheuvel
60d2e70c06 Zend: fix overflow handling bug in non-x86 fast_add_function()
The 'result' argument of fast_add_function() may alias with either
of its operands (or both). Take care not to write to 'result' before
reading op1 and op2.
2013-12-10 12:12:14 +01:00
Dmitry Stogov
5a87b7ff39 Fixed bug #66252 (Problems in AST evaluation invalidating valid parent:: reference. Constant expessions have to be evaluated in context of defining class). 2013-12-10 14:19:17 +04:00
Dmitry Stogov
5ad1117419 Merge branch 'PHP-5.5' into PHP-5.6
* PHP-5.5:
  Arguments passed to user function have to be properly allocated on heap
2013-12-10 13:03:09 +04:00
Dmitry Stogov
a6516653b7 Arguments passed to user function have to be properly allocated on heap 2013-12-10 13:00:45 +04:00
Ard Biesheuvel
f33265d572 cli: don't cast away const in select() timeout argument
The timeout argument to select() is modified to reflect the time
remaining when the function returns on a non-timeout condition.
Passing a pointer to const data and casting away the const-ness is
asking for trouble, but for some reason, this trouble manifests
itself only on non-x86 architectures [whose implementation of select()
in glibc is different from the one supplied for x86]

Fix this by passing a stack copy of the timeout argument to select()
2013-12-09 16:54:42 +01:00
Stanislav Malyshev
cfd5ea4301 Merge branch 'PHP-5.5' into PHP-5.6
* PHP-5.5:
  Replace invalid code with a proper #error
2013-12-08 15:53:41 -08:00
Stanislav Malyshev
744f35d2ab Merge branch 'PHP-5.4' into PHP-5.5
* PHP-5.4:
  Replace invalid code with a proper #error
2013-12-08 15:52:56 -08:00
Lior Kaplan
c062c18d42 Replace invalid code with a proper #error
This code creates a nasty error as mentioned in bugs #31131, #37062
Patch taken from Debian's PHP package: 044-strtod_arm_fix
2013-12-08 15:49:22 -08:00
Adam Harvey
d7a45a67be Merge branch 'PHP-5.4' into PHP-5.5
* PHP-5.4:
  Switch to using freetype-config for freetype detection.
2013-12-07 19:41:23 -08:00
Adam Harvey
a0955f351c Switch to using freetype-config for freetype detection.
This fixes GD compilation against libfreetype 2.5.1 and later after they made
the rather interesting decision to change their include directory layout in a
point release.

The original suggestion in the bug was to use pkg-config, but my inclination is
to use freetype-config instead: we should be able to get the same configuration
information without actually needing pkg-config installed, since pkg-config is
by no means guaranteed to exist on many Unices and distros, whereas
freetype-config should always be present if a libfreetype build environment is
installed. Let's try it out and see what happens.

Fixes bug #64405 (Use freetype-config for determining freetype2 dir(s)).
2013-12-07 19:39:40 -08:00
Ferenc Kovacs
9feb87b017 Merge branch 'igorw-use-function' into PHP-5.6 2013-12-06 11:06:41 +01:00
Michael Wallner
1135f3a042 Merge branch 'PHP-5.5' into PHP-5.6
* PHP-5.5:
  BFN
2013-12-06 10:39:10 +01:00
Michael Wallner
51f01a43a7 BFN 2013-12-06 10:39:02 +01:00
Michael Wallner
9ea2489f5c Merge branch 'PHP-5.5' into PHP-5.6
* PHP-5.5:
  Fixed bug #61645 (fopen and O_NONBLOCK)
  fix possibly uninitialized value
2013-12-06 10:33:47 +01:00
Michael Wallner
a48d82d238 Merge branch 'PHP-5.4' into PHP-5.5
* PHP-5.4:
  Fixed bug #61645 (fopen and O_NONBLOCK)
  fix possibly uninitialized value
2013-12-06 10:33:10 +01:00
Michael Wallner
b5f5bff965 Fixed bug #61645 (fopen and O_NONBLOCK)
if a mode like "rn" was passed to fopen(), then
php_stream_parse_fopen_modes() would assign O_WRONLY to
flags, because O_NONBLOCK tainted flags for the r/w/+ check
2013-12-06 10:29:24 +01:00
Michael Wallner
098d2a5d0f fix possibly uninitialized value 2013-12-06 10:27:33 +01:00
Ferenc Kovacs
562fa252ad Merge branch 'use-function' of git://github.com/igorw/php-src into igorw-use-function 2013-12-06 05:39:49 +01:00
Sara Golemon
f0248bdce5 Merge branch 'PHP-5.5' into PHP-5.6
* PHP-5.5:
  Use 'user@example.com' rather than 'user@company.com' in tests
2013-12-04 07:50:45 -08:00
Sara Golemon
32a4cc8353 Use 'user@example.com' rather than 'user@company.com' in tests
Using some arbitrary 3rd party's domain name is clowny,
even if it never tries to send.
2013-12-04 07:49:16 -08:00
Andrey Hristov
97909ef4ef Merge branch 'PHP-5.5' into PHP-5.6 2013-12-04 12:39:11 +02:00
Andrey Hristov
ceb1b7e20f Merge branch 'PHP-5.4' into PHP-5.5 2013-12-04 12:07:18 +02:00
Andrey Hristov
86aad97979 Fix loss of precision 2013-12-04 12:06:59 +02:00
Sara Golemon
df755deb45 Merge branch 'PHP-5.5' into PHP-5.6
* PHP-5.5:
  Fix php_module_startup() when loading more than one additional module
2013-12-03 18:21:12 -08:00
Sara Golemon
00a7b1ff7f Fix php_module_startup() when loading more than one additional module
Dereferencing addition_modules within php_module_startup would
point to a vector entirely on the stack (which is of course, wrong).

Use a specialized helper to keep BC with the current php_module_startup()
calling semantics.

Fixes 63159
Thanks to @a-j-k
2013-12-03 18:20:19 -08:00
Adam Harvey
44697c115b Merge branch 'PHP-5.5' into PHP-5.6
* PHP-5.5:
  Remove 128.0.0.0/16 and 191.255.0.0/16 from the reserved list.
2013-12-03 14:52:35 -08:00
Adam Harvey
6f52f566f3 Merge branch 'PHP-5.4' into PHP-5.5
* PHP-5.4:
  Remove 128.0.0.0/16 and 191.255.0.0/16 from the reserved list.
2013-12-03 14:51:03 -08:00
Adam Harvey
d1314893fd Remove 128.0.0.0/16 and 191.255.0.0/16 from the reserved list.
These were returned to the general allocation pool by RFC 3330, and hence
shouldn't cause an IP address validation failure due to being reserved. At
least 128.0.0.0/16 is in use on the public Internet today.

Fixes bug #66229 (128.0.0.0/16 isn't reserved any longer).
2013-12-03 14:46:15 -08:00
Nikita Popov
00c74ccf69 Support gmp_remroot() on GMP 4.1 2013-12-02 20:11:06 +01:00
Bob Weinand
2d230254de Added note about const scalar exprs in UPGRADING file 2013-12-02 18:39:01 +01:00
Michael Wallner
f254476f99 Merge branch 'PHP-5.5' into PHP-5.6
* PHP-5.5:
  BFN
  Fix bug #65196
2013-12-02 17:02:13 +01:00
Michael Wallner
ffbb56685f BFN 2013-12-02 17:02:01 +01:00
Michael Wallner
9c0a70c1de Merge branch 'PHP-5.4' into PHP-5.5
* PHP-5.4:
  Fix bug #65196
2013-12-02 17:01:25 +01:00
Michael Wallner
22fa3fbc5f Fix bug #65196
Passing DOMDocumentFragment to DOMDocument::saveHTML()
produces invalid markup, because a DocumentFragment is just a container
for child nodes and not a real node itself.
2013-12-02 17:00:13 +01:00
Michael Wallner
733259c211 Merge branch 'PHP-5.5' into PHP-5.6
* PHP-5.5:
  BFN
  fix bug #49634x
2013-12-02 12:15:27 +01:00
Michael Wallner
6eae927413 BFN 2013-12-02 12:14:26 +01:00
Michael Wallner
e4b310d2a9 Merge branch 'PHP-5.4' into PHP-5.5
* PHP-5.4:
  fix bug #49634x
2013-12-02 12:10:59 +01:00
Michael Wallner
6408a1a59e fix bug #49634x 2013-12-02 12:10:00 +01:00
Dmitry Stogov
0f39089384 Merge branch 'PHP-5.5' into PHP-5.6
* PHP-5.5:
  Fixed tests
2013-12-02 12:05:29 +04:00
Dmitry Stogov
2f5ab04c5f Merge branch 'PHP-5.4' into PHP-5.5
* PHP-5.4:
  Fixed tests
2013-12-02 12:04:07 +04:00
Dmitry Stogov
edbefd1d5c Fixed tests 2013-12-02 11:53:35 +04:00
Dmitry Stogov
9447181d0c Merge branch 'PHP-5.5' into PHP-5.6
* PHP-5.5:
  Fixed ability to build non-specialized GOTO VM
2013-12-02 11:03:17 +04:00
Dmitry Stogov
7efcbecda9 Merge branch 'PHP-5.4' into PHP-5.5
* PHP-5.4:
  Fixed ability to build non-specialized GOTO VM

Conflicts:
	Zend/zend_vm_gen.php
2013-12-02 11:02:40 +04:00
Dmitry Stogov
9ed605892d Fixed ability to build non-specialized GOTO VM 2013-12-02 10:59:32 +04:00
Nikita Popov
b3546e64bd Merge branch 'PHP-5.5' into PHP-5.6 2013-12-01 13:45:22 +01:00
Nikita Popov
02dca18b90 Fix bug #65764
I'm not exactly sure whether this is the right way to fix it. The
question is whether Generator::throw() on a newborn generator (i.e.
a generator that is not yet at yield expression) should first advance to
the first yield and throw the exception there or whether it should
instead throw the exception in the caller's context.

The old behavior was to throw it at the start of the function (i.e.
the very first opcode), which causes issues like the one in #65764.
Effectively it's impossible to properly handle the exceptions in this
case.

For now I choose the variant where the generator advances to the
first yield before throwing, as that's consistent with how all other
methods on the Generator object currently behave. This does not
necessarily match the behavior in other languages, e.g. Python would throw
the exception in the caller's context. But then our send() method already
has this kind of deviation, so it stays internally consistent at least.
2013-12-01 13:37:56 +01:00