mirror of
https://github.com/php/php-src.git
synced 2026-04-28 02:33:17 +02:00
Merge branch 'PHP-5.4' into PHP-5.5
* PHP-5.4: Fix run-tests.php with Valgrind >= 3.10.0. Conflicts: run-tests.php
This commit is contained in:
+3
-3
@@ -581,8 +581,8 @@ if (isset($argc) && $argc > 1) {
|
||||
if (!$valgrind_header) {
|
||||
error("Valgrind returned no version info, cannot proceed.\nPlease check if Valgrind is installed.");
|
||||
} else {
|
||||
$valgrind_version = preg_replace("/valgrind-(\d)\.(\d)\.(\d+)([.\w_-]+)?(\s+)/", '$1$2$3', $valgrind_header, 1, $replace_count);
|
||||
if ($replace_count != 1 || !is_numeric($valgrind_version)) {
|
||||
$valgrind_version = preg_replace("/valgrind-(\d+)\.(\d+)\.(\d+)([.\w_-]+)?(\s+)/", '$1.$2.$3', $valgrind_header, 1, $replace_count);
|
||||
if ($replace_count != 1) {
|
||||
error("Valgrind returned invalid version info (\"$valgrind_header\"), cannot proceed.");
|
||||
}
|
||||
$valgrind_header = trim($valgrind_header);
|
||||
@@ -1780,7 +1780,7 @@ TEST $file
|
||||
$env['USE_ZEND_ALLOC'] = '0';
|
||||
$env['ZEND_DONT_UNLOAD_MODULES'] = 1;
|
||||
|
||||
if ($valgrind_version >= 330) {
|
||||
if (version_compare($valgrind_version, '3.3.0', '>=')) {
|
||||
/* valgrind 3.3.0+ doesn't have --log-file-exactly option */
|
||||
$cmd = "valgrind -q --tool=memcheck --trace-children=yes --log-file=$memcheck_filename $cmd";
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user