Skip to content

Commit

Permalink
ensure installed ini don't interfere
Browse files Browse the repository at this point in the history
  • Loading branch information
remicollet committed Aug 21, 2020
1 parent ff66e49 commit 8c57474
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion sapi/cli/tests/bug62294.phpt
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Bug #62294: register_shutdown_function() does not handle exit code correctly
<?php

$php = getenv('TEST_PHP_EXECUTABLE');
exec($php . ' ' . __DIR__ . '/bug62294.inc', $output, $exit_status);
exec($php . ' -n ' . __DIR__ . '/bug62294.inc', $output, $exit_status);
var_dump($exit_status);

?>
Expand Down

3 comments on commit 8c57474

@nikic
Copy link
Member

@nikic nikic commented on 8c57474 Aug 24, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do you know which ini setting was problematic here? I think this may indicate a bug where some particular code path doesn't handle require failure correctly.

@nikic
Copy link
Member

@nikic nikic commented on 8c57474 Aug 24, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah no, this looks more like a difference in error logging, probably stderr is used and thus bypasses the exec output buffer. This change is fine.

@remicollet
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@nikic another way is to set the proper config in --INI-- section, but this means to also honours TEST_PHP_ARGS in exec command.... so -n seems simpler in this simple case.

(log_errors = On in production/development settings, Off by default)

Please sign in to comment.