Skip to content

Commit

Permalink
Merge branch '3.4' into 4.4
Browse files Browse the repository at this point in the history
* 3.4:
  [Http Foundation] Fix clear cookie samesite
  [Security] Check if firewall is stateless before checking for session/previous session
  [Form] Support customized intl php.ini settings
  [Security] Remember me: allow to set the samesite cookie flag
  [Debug] fix for PHP 7.3.16+/7.4.4+
  [Validator] Backport translations
  Prevent warning in proc_open()
  • Loading branch information
nicolas-grekas committed Mar 23, 2020
1 parent 642b771 commit 3727fe3
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
4 changes: 2 additions & 2 deletions ErrorHandler.php
Original file line number Diff line number Diff line change
Expand Up @@ -519,7 +519,7 @@ public function handleError(int $type, string $message, string $file, int $line)
if ($this->isRecursive) {
$log = 0;
} else {
if (!\defined('HHVM_VERSION')) {
if (\PHP_VERSION_ID < (\PHP_VERSION_ID < 70400 ? 70316 : 70404)) {
$currentErrorHandler = set_error_handler('var_dump');
restore_error_handler();
}
Expand All @@ -531,7 +531,7 @@ public function handleError(int $type, string $message, string $file, int $line)
} finally {
$this->isRecursive = false;

if (!\defined('HHVM_VERSION')) {
if (\PHP_VERSION_ID < (\PHP_VERSION_ID < 70400 ? 70316 : 70404)) {
set_error_handler($currentErrorHandler);
}
}
Expand Down
6 changes: 4 additions & 2 deletions Tests/ErrorHandlerTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -363,8 +363,6 @@ public function testHandleDeprecation()
$handler = new ErrorHandler();
$handler->setDefaultLogger($logger);
@$handler->handleError(E_USER_DEPRECATED, 'Foo deprecation', __FILE__, __LINE__, []);

restore_error_handler();
}

/**
Expand Down Expand Up @@ -618,6 +616,10 @@ public function errorHandlerWhenLoggingProvider(): iterable

public function testAssertQuietEval()
{
if ('-1' === ini_get('zend.assertions')) {
$this->markTestSkipped('zend.assertions is forcibly disabled');
}

$ini = [
ini_set('zend.assertions', 1),
ini_set('assert.active', 1),
Expand Down

0 comments on commit 3727fe3

Please sign in to comment.