Skip to content

Commit 1a50c27

Browse files
committed
Merge remote-tracking branch 'origin/PHP-5.6' into str_size_and_int64_56_backport
* origin/PHP-5.6: (170 commits) Fixed possible crash because of race conditions on modifying constants in shared memory remove the NEWS entry for the reverted fpm fix remove the NEWS entry for the reverted fpm fix remove the NEWS entry for the reverted fpm fix Revert "Fix Bug #67530 error_log=syslog ignored" --enable-fpm for the travis build fix the last fpm NEWS entry, the other bug is related, but not the same what we fixed here NEWS NEWS Fix bug #67091: make install fails to install libphp5.so on FreeBSD 10.0 adding NEWS entry for the fix for bug #65641 Updated NEWS file for recent phpdbg fixes Fixed issue krakjoe/phpdbg#94 - List behavior is inconsistent Fix issue krakjoe/phpdbg#97 - list now appends a newline if there is none The prompt should always ensure it is on a newline Fixed test Inform about back command existence in help - Fixes krakjoe/phpdbg#100 No way to list the current stack/frames Fix issue krakjoe/phpdbg#98 break if does not seem to work Fix issue krakjoe/phpdbg#99 register function has the same behavior as run Fix readline/libedit (Thanks to @remicollet) Replace incorrect `E` command with `ev` in watch help ... Conflicts: Zend/zend_compile.c ext/standard/basic_functions.c ext/standard/http_fopen_wrapper.c ext/standard/var.c ext/tokenizer/tokenizer_data.c sapi/phpdbg/phpdbg_list.c
2 parents d4cfc15 + 2330be5 commit 1a50c27

File tree

158 files changed

+3743
-4328
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

158 files changed

+3743
-4328
lines changed

.travis.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,4 +32,6 @@ before_script:
3232
- . ./travis/ext/pdo_pgsql/setup.sh
3333

3434
# Run PHPs run-tests.php
35-
script: ./sapi/cli/php run-tests.php -p `pwd`/sapi/cli/php -g "FAIL,XFAIL,BORK,WARN,LEAK,SKIP" --show-diff --set-timeout 120
35+
script:
36+
- ./sapi/cli/php run-tests.php -p `pwd`/sapi/cli/php -g "FAIL,XFAIL,BORK,WARN,LEAK,SKIP" --show-diff --set-timeout 120
37+
- ./sapi/cli/php sapi/phpdbg/tests/run-tests.php -diff2stdout --phpdbg sapi/phpdbg/phpdbg

LICENSE

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
--------------------------------------------------------------------
22
The PHP License, version 3.01
3-
Copyright (c) 1999 - 2012 The PHP Group. All rights reserved.
3+
Copyright (c) 1999 - 2014 The PHP Group. All rights reserved.
44
--------------------------------------------------------------------
55

66
Redistribution and use in source and binary forms, with or without

NEWS

Lines changed: 88 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,93 @@
11
PHP NEWS
22
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
3-
?? ??? 2014, PHP 5.6.0 Release Candidate 1
3+
?? ??? 2014, PHP 5.6.0 Release Candidate 2
4+
5+
- Core:
6+
. Fixed bug #67368 (Memory leak with immediately dereferenced array in class
7+
constant). (Laruence)
8+
. Fixed bug #67468 (Segfault in highlight_file()/highlight_string()).
9+
(Andreas Ferber)
10+
. Fixed bug #67091 (make install fails to install libphp5.so on FreeBSD 10.0).
11+
(Ferenc)
12+
13+
- FPM:
14+
. Fix bug #67531 (syslog cannot be set in pool configuration). (Remi)
15+
. Fix bug #67541 (Fix Apache 2.4.10+ SetHandler proxy:fcgi://
16+
incompatibilities). (David Zuelke)
17+
18+
- phpdbg:
19+
. Fix Bug #67499 (readline feature not enabled when build with libedit). (Remi)
20+
. Fix issue krakjoe/phpdbg#94 (List behavior is inconsistent). (Bob)
21+
. Fix issue krakjoe/phpdbg#97 (The prompt should always ensure it is on a
22+
newline). (Bob)
23+
. Fix issue krakjoe/phpdbg#98 (break if does not seem to work). (Bob)
24+
. Fix issue krakjoe/phpdbg#99 (register function has the same behavior as
25+
run). (Bob)
26+
. Fix issue krakjoe/phpdbg#100 (No way to list the current stack/frames)
27+
(Help entry was missing). (Bob)
28+
29+
19 Jun 2014, PHP 5.6.0 Release Candidate 1
30+
31+
- Core:
32+
. Implemented FR #64744 (Differentiate between member function call on a null
33+
and non-null, non-objects). (Boro Sitnikovski)
34+
. Fixed bug #67436 (Autoloader isn't called if two method definitions don't
35+
match). (Bob)
36+
. Fixed bug #66622 (Closures do not correctly capture the late bound class
37+
(static::) in some cases). (Levi Morrison)
38+
. Fixed bug #67390 (insecure temporary file use in the configure script).
39+
(Remi) (CVE-2014-3981)
40+
. Fixed bug #67392 (dtrace breaks argument unpack). (Nikita)
41+
. Fixed bug #67428 (header('Location: foo') will override a 308-399 response
42+
code). (Adam)
43+
. Fixed bug #67433 (SIGSEGV when using count() on an object implementing
44+
Countable). (Matteo)
45+
. Fixed bug #67399 (putenv with empty variable may lead to crash). (Stas)
46+
47+
- CLI server:
48+
. Implemented FR #67429 (CLI server is missing some new HTTP response codes).
49+
(Adam)
50+
. Fixed Bug #67406 (built-in web-server segfaults on startup). (Remi)
51+
52+
- Fileinfo:
53+
. Fixed bug #67410 (fileinfo: mconvert incorrect handling of truncated pascal
54+
string size). (Francisco Alonso, Jan Kaluza, Remi)
55+
. Fixed bug #67411 (fileinfo: cdf_check_stream_offset insufficient boundary
56+
check). (Francisco Alonso, Jan Kaluza, Remi)
57+
. Fixed bug #67412 (fileinfo: cdf_count_chain insufficient boundary check).
58+
(Francisco Alonso, Jan Kaluza, Remi)
59+
. Fixed bug #67413 (fileinfo: cdf_read_property_info insufficient boundary
60+
check). (Francisco Alonso, Jan Kaluza, Remi)
61+
62+
- mysqlnd:
63+
. Added support for gb18030 from MySQL 5.7. (Andrey)
64+
65+
- Network:
66+
. Fixed bug #67432 (Fix potential segfault in dns_get_record()).
67+
(CVE-2014-4049). (Sara)
68+
69+
- OpenSSL:
70+
. Fixed bug #65698 (certificates validity parsing does not work past 2050).
71+
(Paul Oehler)
72+
. Fixed bug #66636 (openssl_x509_parse warning with V_ASN1_GENERALIZEDTIME).
73+
(Paul Oehler)
74+
75+
- phpdbg:
76+
. Fixed bug #67212 (phpdbg uses non-standard TIOCGWINSZ). (Ferenc)
77+
78+
- SOAP:
79+
. Implemented FR #49898 (Add SoapClient::__getCookies()). (Boro Sitnikovski)
80+
81+
- SPL:
82+
. Fixed bug #66127 (Segmentation fault with ArrayObject unset). (Stas)
83+
. Fixed request #67453 (Allow to unserialize empty data). (Remi)
84+
85+
- Streams:
86+
. Fixed bug #67430 (http:// wrapper doesn't follow 308 redirects). (Adam)
87+
88+
- Tokenizer:
89+
. Fixed bug #67395 (token_name() does not return name for T_POW and T_POW_EQUAL
90+
token). (Ferenc)
491

592
05 Jun 2014, PHP 5.6.0 Beta 4
693

Zend/tests/67468.phpt

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
--TEST--
2+
Bug #67468 (Segfault in highlight_file()/highlight_string())
3+
--SKIPIF--
4+
<?php if(!function_exists("leak")) print "skip only for debug builds"; ?>
5+
--FILE--
6+
<?php
7+
highlight_string("<?php __CLASS__;", true);
8+
echo "done";
9+
?>
10+
--EXPECT--
11+
done

Zend/tests/bug67368.phpt

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
--TEST--
2+
Bug #67368 (Memory leak with immediately dereferenced array in class constant)
3+
--INI--
4+
report_memleaks=1
5+
--FILE--
6+
<?php
7+
class FooBar {
8+
const bar = ["bar" => 3]["bar"];
9+
}
10+
echo "okey";
11+
--EXPECTF--
12+
okey

Zend/tests/bug67436/a.php

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
<?php
2+
3+
class a {
4+
public function test($arg = c::TESTCONSTANT) {
5+
echo __METHOD__ . "($arg)\n";
6+
}
7+
8+
static public function staticTest() {
9+
}
10+
}

Zend/tests/bug67436/b.php

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
<?php
2+
3+
class b extends a {
4+
public function test() {
5+
echo __METHOD__ . "()\n";
6+
parent::test();
7+
}
8+
}

Zend/tests/bug67436/bug67436.phpt

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
--TEST--
2+
bug67436: Autoloader isn't called if user defined error handler is present
3+
4+
--INI--
5+
error_reporting=
6+
7+
--FILE--
8+
<?php
9+
10+
spl_autoload_register(function($classname) {
11+
if (in_array($classname, array('a','b','c'))) {
12+
require_once ($classname . '.php');
13+
}
14+
});
15+
16+
set_error_handler(function ($errno, $errstr, $errfile, $errline) {
17+
}, error_reporting());
18+
19+
a::staticTest();
20+
21+
$b = new b();
22+
$b->test();
23+
24+
--EXPECT--
25+
b::test()
26+
a::test(c::TESTCONSTANT)
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
--TEST--
2+
bug67436: E_STRICT instead of custom error handler
3+
4+
--INI--
5+
error_reporting=-1
6+
7+
--FILE--
8+
<?php
9+
10+
spl_autoload_register(function($classname) {
11+
if (in_array($classname, array('a','b','c'))) {
12+
require_once ($classname . '.php');
13+
}
14+
});
15+
16+
a::staticTest();
17+
18+
$b = new b();
19+
$b->test();
20+
21+
--EXPECTF--
22+
Strict Standards: Declaration of b::test() should be compatible with a::test($arg = c::TESTCONSTANT) in %s/bug67436/b.php on line %d
23+
b::test()
24+
a::test(c::TESTCONSTANT)

Zend/tests/bug67436/c.php

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
<?php
2+
3+
class c {
4+
const TESTCONSTANT = "c::TESTCONSTANT";
5+
}

Zend/tests/closure_049.phpt

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
--TEST--
2+
Closure 049: static::class in static closure in non-static method.
3+
4+
--FILE--
5+
<?php
6+
7+
class A {
8+
function foo() {
9+
$f = static function() {
10+
return static::class;
11+
};
12+
return $f();
13+
}
14+
}
15+
16+
class B extends A {}
17+
18+
$b = new B;
19+
20+
var_dump($b->foo());
21+
--EXPECT--
22+
string(1) "B"

Zend/tests/closure_050.phpt

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
--TEST--
2+
Closure 050: static::class in non-static closure in non-static method.
3+
4+
--FILE--
5+
<?php
6+
7+
class A {
8+
function foo() {
9+
$f = function() {
10+
return static::class;
11+
};
12+
return $f();
13+
}
14+
}
15+
16+
class B extends A {}
17+
18+
$b = new B;
19+
var_dump($b->foo());
20+
21+
--EXPECT--
22+
string(1) "B"

Zend/tests/closure_051.phpt

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
--TEST--
2+
Closure 051: static::class in static closure in static method.
3+
4+
--FILE--
5+
<?php
6+
7+
class A {
8+
static function foo() {
9+
$f = static function() {
10+
return static::class;
11+
};
12+
return $f();
13+
}
14+
}
15+
16+
class B extends A {}
17+
18+
var_dump(B::foo());
19+
20+
--EXPECT--
21+
string(1) "B"

Zend/tests/closure_052.phpt

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
--TEST--
2+
Closure 052: static::class in non-static closure in static method.
3+
4+
--FILE--
5+
<?php
6+
7+
class A {
8+
static function foo() {
9+
$f = function() {
10+
return static::class;
11+
};
12+
return $f();
13+
}
14+
}
15+
16+
class B extends A {}
17+
18+
var_dump(B::foo());
19+
20+
--EXPECT--
21+
string(1) "B"

Zend/tests/closure_053.phpt

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
--TEST--
2+
Closure 053: self::class in static closure in non-static method.
3+
4+
--FILE--
5+
<?php
6+
7+
class A {
8+
function foo() {
9+
$f = static function() {
10+
return self::class;
11+
};
12+
return $f();
13+
}
14+
}
15+
16+
class B extends A {}
17+
18+
$b = new B;
19+
var_dump($b->foo());
20+
21+
--EXPECT--
22+
string(1) "A"

Zend/tests/closure_054.phpt

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
--TEST--
2+
Closure 054: self::class in non-static closure in non-static method.
3+
4+
--FILE--
5+
<?php
6+
7+
class A {
8+
function foo() {
9+
$f = function() {
10+
return self::class;
11+
};
12+
return $f();
13+
}
14+
}
15+
16+
class B extends A {}
17+
18+
$b = new B;
19+
var_dump($b->foo());
20+
21+
--EXPECT--
22+
string(1) "A"

Zend/tests/closure_055.phpt

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
--TEST--
2+
Closure 055: self::class in static closure in static method.
3+
4+
--FILE--
5+
<?php
6+
7+
class A {
8+
static function foo() {
9+
$f = static function() {
10+
return self::class;
11+
};
12+
return $f();
13+
}
14+
}
15+
16+
class B extends A {}
17+
18+
var_dump(B::foo());
19+
20+
--EXPECT--
21+
string(1) "A"

Zend/tests/closure_056.phpt

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
--TEST--
2+
Closure 056: self::class in non-static closure in static method.
3+
4+
--FILE--
5+
<?php
6+
7+
class A {
8+
static function foo() {
9+
$f = function() {
10+
return self::class;
11+
};
12+
return $f();
13+
}
14+
}
15+
16+
class B extends A {}
17+
18+
var_dump(B::foo());
19+
20+
--EXPECT--
21+
string(1) "A"

0 commit comments

Comments
 (0)