Skip to content

Commit a3b286a

Browse files
committed
Rename to error_include_args
Avoid a negative which is harder to reason about; matches RFC change
1 parent dc66fb0 commit a3b286a

8 files changed

Lines changed: 12 additions & 12 deletions

File tree

Zend/tests/display_error_function_args.phpt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
--TEST--
22
Displaying function arguments in errors
33
--INI--
4-
error_ignore_args=Off
4+
error_include_args=On
55
--FILE--
66
<?php
77

@@ -14,7 +14,7 @@ unlink('/');
1414
$flags = ["salt" => "123456789012345678901" . chr(0), "cost" => 4];
1515
password_hash("test", PASSWORD_BCRYPT, $flags);
1616

17-
ini_set("error_ignore_args", "On");
17+
ini_set("error_include_args", "Off");
1818

1919
unlink('/');
2020
password_hash("test", PASSWORD_BCRYPT, $flags);

ext/openssl/tests/ServerClientTestCase.inc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ class ServerClientTestCase
101101
$cmd = sprintf(
102102
'%s %s "%s" %s',
103103
// XXX: TEST_PHP_EXTRA_ARGS for run-test values won't work here?
104-
PHP_BINARY, $ini ? "-n -c $ini -d error_ignore_args=1" : "",
104+
PHP_BINARY, $ini ? "-n -c $ini -d error_include_args=0" : "",
105105
__FILE__,
106106
WORKER_ARGV_VALUE
107107
);

main/main.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -802,7 +802,7 @@ PHP_INI_BEGIN()
802802
STD_PHP_INI_ENTRY_EX("display_errors", "1", PHP_INI_ALL, OnUpdateDisplayErrors, display_errors, php_core_globals, core_globals, display_errors_mode)
803803
STD_PHP_INI_BOOLEAN("display_startup_errors", "1", PHP_INI_ALL, OnUpdateBool, display_startup_errors, php_core_globals, core_globals)
804804
STD_PHP_INI_BOOLEAN("enable_dl", "1", PHP_INI_SYSTEM, OnUpdateBool, enable_dl, php_core_globals, core_globals)
805-
STD_PHP_INI_BOOLEAN("error_ignore_args", "0", PHP_INI_ALL, OnUpdateBool, error_ignore_args, php_core_globals, core_globals)
805+
STD_PHP_INI_BOOLEAN("error_include_args", "1", PHP_INI_ALL, OnUpdateBool, error_include_args, php_core_globals, core_globals)
806806
STD_PHP_INI_BOOLEAN("expose_php", "1", PHP_INI_SYSTEM, OnUpdateBool, expose_php, php_core_globals, core_globals)
807807
STD_PHP_INI_ENTRY("docref_root", "", PHP_INI_ALL, OnUpdateString, docref_root, php_core_globals, core_globals)
808808
STD_PHP_INI_ENTRY("docref_ext", "", PHP_INI_ALL, OnUpdateString, docref_ext, php_core_globals, core_globals)
@@ -1135,7 +1135,7 @@ PHPAPI ZEND_COLD void php_verror(const char *docref, const char *params, int typ
11351135
/* if we still have memory then format the origin */
11361136
if (is_function) {
11371137
zend_string *dynamic_params = NULL;
1138-
if (PG(error_ignore_args) == false) {
1138+
if (PG(error_include_args)) {
11391139
dynamic_params = zend_trace_current_function_args_string();
11401140
}
11411141
origin_len = spprintf(&origin, 0, "%s%s%s(%s)", class_name, space, function, dynamic_params ? ZSTR_VAL(dynamic_params) : params);

main/php_globals.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ struct _php_core_globals {
5959

6060
uint8_t display_errors;
6161
bool display_startup_errors;
62-
bool error_ignore_args;
62+
bool error_include_args;
6363
bool log_errors;
6464
bool ignore_repeated_errors;
6565
bool ignore_repeated_source;

php.ini-development

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -612,13 +612,13 @@ ignore_repeated_source = Off
612612
;fatal_error_backtraces = On
613613

614614
; This directive controls whether PHP will print the actual arguments of a
615-
; function upon an error. If this is on (or there was an error fetching the
615+
; function upon an error. If this is off (or there was an error fetching the
616616
; arguments), the function providing the error may optionally provide some
617617
; additional information after the problem function's name.
618618
; Default Value: Off
619619
; Development Value: Off
620620
; Production Value: Off
621-
;error_ignore_args = Off
621+
;error_include_args = Off
622622

623623
;;;;;;;;;;;;;;;;;
624624
; Data Handling ;

php.ini-production

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -614,13 +614,13 @@ ignore_repeated_source = Off
614614
;fatal_error_backtraces = On
615615

616616
; This directive controls whether PHP will print the actual arguments of a
617-
; function upon an error. If this is on (or there was an error fetching the
617+
; function upon an error. If this is off (or there was an error fetching the
618618
; arguments), the function providing the error may optionally provide some
619619
; additional information after the problem function's name.
620620
; Default Value: Off
621621
; Development Value: Off
622622
; Production Value: Off
623-
;error_ignore_args = Off
623+
;error_include_args = Off
624624

625625
;;;;;;;;;;;;;;;;;
626626
; Data Handling ;

run-tests.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -273,7 +273,7 @@ function main(): void
273273
'fatal_error_backtraces=Off',
274274
'display_errors=1',
275275
'display_startup_errors=1',
276-
'error_ignore_args=1',
276+
'error_include_args=0',
277277
'log_errors=0',
278278
'html_errors=0',
279279
'track_errors=0',

sapi/cli/tests/php_cli_server.inc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ function php_cli_server_start(
2525
}
2626

2727
// XXX: This should ideally use the same INI overrides as run-tests
28-
$cmd = [$php_executable, '-d', 'error_ignore_args=1', '-t', $doc_root, '-n', ...$cmd_args, '-S', 'localhost:0'];
28+
$cmd = [$php_executable, '-d', 'error_include_args=0', '-t', $doc_root, '-n', ...$cmd_args, '-S', 'localhost:0'];
2929
if (!is_null($router)) {
3030
$cmd[] = $router;
3131
}

0 commit comments

Comments
 (0)