Index: trunk/phase3/includes/installer/Installer.php |
— | — | @@ -654,7 +654,11 @@ |
655 | 655 | foreach ( $names as $name ) { |
656 | 656 | $command = "$path/$name"; |
657 | 657 | |
658 | | - if ( @file_exists( $command ) ) { |
| 658 | + wfSuppressWarnings(); |
| 659 | + $file_exists = file_exists( $command ); |
| 660 | + wfRestoreWarnings(); |
| 661 | + |
| 662 | + if ( $file_exists ) { |
659 | 663 | if ( !$versionInfo ) { |
660 | 664 | return $command; |
661 | 665 | } |
— | — | @@ -677,9 +681,15 @@ |
678 | 682 | */ |
679 | 683 | public function envCheckGraphics() { |
680 | 684 | $imcheck = array( "/usr/bin", "/opt/csw/bin", "/usr/local/bin", "/sw/bin", "/opt/local/bin" ); |
| 685 | + |
681 | 686 | foreach( $imcheck as $dir ) { |
682 | 687 | $im = "$dir/convert"; |
683 | | - if( @file_exists( $im ) ) { |
| 688 | + |
| 689 | + wfSuppressWarnings(); |
| 690 | + $file_exists = file_exists( $im ); |
| 691 | + wfRestoreWarnings(); |
| 692 | + |
| 693 | + if( $file_exists ) { |
684 | 694 | $this->showMessage( 'config-imagemagick', $im ); |
685 | 695 | $this->setVar( 'wgImageMagickConvertCommand', $im ); |
686 | 696 | return true; |