Index: trunk/phase3/includes/GlobalFunctions.php |
— | — | @@ -2468,14 +2468,15 @@ |
2469 | 2469 | if( wfIniGetBool( 'safe_mode' ) ) { |
2470 | 2470 | wfDebug( "wfShellExec can't run in safe_mode, PHP's exec functions are too broken.\n" ); |
2471 | 2471 | $disabled = 'safemode'; |
| 2472 | + } else { |
| 2473 | + $functions = explode( ',', ini_get( 'disable_functions' ) ); |
| 2474 | + $functions = array_map( 'trim', $functions ); |
| 2475 | + $functions = array_map( 'strtolower', $functions ); |
| 2476 | + if ( in_array( 'passthru', $functions ) ) { |
| 2477 | + wfDebug( "passthru is in disabled_functions\n" ); |
| 2478 | + $disabled = 'passthru'; |
| 2479 | + } |
2472 | 2480 | } |
2473 | | - $functions = explode( ',', ini_get( 'disable_functions' ) ); |
2474 | | - $functions = array_map( 'trim', $functions ); |
2475 | | - $functions = array_map( 'strtolower', $functions ); |
2476 | | - if ( in_array( 'passthru', $functions ) ) { |
2477 | | - wfDebug( "passthru is in disabled_functions\n" ); |
2478 | | - $disabled = 'passthru'; |
2479 | | - } |
2480 | 2481 | } |
2481 | 2482 | if ( $disabled ) { |
2482 | 2483 | $retval = 1; |