Bug #74635 [NEW]: when call a disabled function,php not throw a fatal error

From: Date: Tue, 23 May 2017 05:03:43 +0000
Subject: Bug #74635 [NEW]: when call a disabled function,php not throw a fatal error
Groups: php.standards 
Request: Send a blank email to standards-+get-1272@lists.php.net to get a copy of this message
From: shengbin_xu at 163 dot com Operating system: ubuntu PHP version: 7.1.5 Package: PHP Language Specification Bug Type: Bug Bug description:when call a disabled function,php not throw a fatal error Description: ------------ in php.ini,popen function is in disable functions: disable_functions => passthru,system,popen,chroot,escapeshellcmd,proc_get_status => passthru,system,popen,chroot,escapeshellcmd,proc_get_status function_exists('popen') return false,but when call popen, php only give a notice,but not throw a fatal error。 Test script: --------------- <?php error_reporting(E_ALL); ini_set('display_errors','on'); var_dump(function_exists('popen'));//false $handle = popen("/bin/ls", "r");//null Warning: popen() has been disabled for security reasons in var_dump($handle); echo gettype($handle); Expected result: ---------------- when popen function is called,php should throw a fatal error。 -- Edit bug report at https://bugs.php.net/bug.php?id=74635&edit=1 -- Try a snapshot (PHP 5.4): https://bugs.php.net/fix.php?id=74635&r=trysnapshot54 Try a snapshot (PHP 5.5): https://bugs.php.net/fix.php?id=74635&r=trysnapshot55 Try a snapshot (trunk): https://bugs.php.net/fix.php?id=74635&r=trysnapshottrunk Fixed in SVN: https://bugs.php.net/fix.php?id=74635&r=fixed Fixed in release: https://bugs.php.net/fix.php?id=74635&r=alreadyfixed Need backtrace: https://bugs.php.net/fix.php?id=74635&r=needtrace Need Reproduce Script: https://bugs.php.net/fix.php?id=74635&r=needscript Try newer version: https://bugs.php.net/fix.php?id=74635&r=oldversion Not developer issue: https://bugs.php.net/fix.php?id=74635&r=support Expected behavior: https://bugs.php.net/fix.php?id=74635&r=notwrong Not enough info: https://bugs.php.net/fix.php?id=74635&r=notenoughinfo Submitted twice: https://bugs.php.net/fix.php?id=74635&r=submittedtwice register_globals: https://bugs.php.net/fix.php?id=74635&r=globals PHP 4 support discontinued: https://bugs.php.net/fix.php?id=74635&r=php4 Daylight Savings: https://bugs.php.net/fix.php?id=74635&r=dst IIS Stability: https://bugs.php.net/fix.php?id=74635&r=isapi Install GNU Sed: https://bugs.php.net/fix.php?id=74635&r=gnused Floating point limitations: https://bugs.php.net/fix.php?id=74635&r=float No Zend Extensions: https://bugs.php.net/fix.php?id=74635&r=nozend MySQL Configuration Error: https://bugs.php.net/fix.php?id=74635&r=mysqlcfg

« previous php.standards (#1272) next »