Find this useful? Enter your email to receive occasional updates for securing PHP code.
Signing you up...
Thank you for signing up!
PHP Decode
<?php /* * This file is part of the Symfony package. * * (c) Fabien Potencier <fabien@..
Decoded Output download
<?php
/*
* This file is part of the Symfony package.
*
* (c) Fabien Potencier <[email protected]>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace RectorPrefix202406\Symfony\Component\Console\SignalRegistry;
/**
* @author Grgoire Pineau <[email protected]>
*/
class SignalMap
{
/**
* @var mixed[]
*/
private static $map;
public static function getSignalName(int $signal) : ?string
{
if (!\extension_loaded('pcntl')) {
return null;
}
if (!isset(self::$map)) {
$r = new \ReflectionExtension('pcntl');
$c = $r->getConstants();
$map = rray_filter($c, function ($k) {
return \strncmp($k, 'SIG', \strlen('SIG')) === 0 && \strncmp($k, 'SIG_', \strlen('SIG_')) !== 0;
}, \ARRAY_FILTER_USE_KEY);
self::$map = rray_flip($map);
}
return self::$map[$signal] ?? null;
}
}
?>
Did this file decode correctly?
Original Code
<?php
/*
* This file is part of the Symfony package.
*
* (c) Fabien Potencier <[email protected]>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace RectorPrefix202406\Symfony\Component\Console\SignalRegistry;
/**
* @author Grgoire Pineau <[email protected]>
*/
class SignalMap
{
/**
* @var mixed[]
*/
private static $map;
public static function getSignalName(int $signal) : ?string
{
if (!\extension_loaded('pcntl')) {
return null;
}
if (!isset(self::$map)) {
$r = new \ReflectionExtension('pcntl');
$c = $r->getConstants();
$map = \array_filter($c, function ($k) {
return \strncmp($k, 'SIG', \strlen('SIG')) === 0 && \strncmp($k, 'SIG_', \strlen('SIG_')) !== 0;
}, \ARRAY_FILTER_USE_KEY);
self::$map = \array_flip($map);
}
return self::$map[$signal] ?? null;
}
}
Function Calls
None |
Stats
MD5 | 5d73d17f641103f4b48915aa93b70945 |
Eval Count | 0 |
Decode Time | 165 ms |