Brian Wolff has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/140880

Change subject: Only use limit.sh if /bin/bash executable, instead of if linux.
......................................................................

Only use limit.sh if /bin/bash executable, instead of if linux.

gute on irc just mentioned how his BusyBox server identifies as
linux but doesn't have bash installed. Additionally I see no
reason to limit limit.sh to linux, if for example somebody has
installed bash on a different *nix.

Change-Id: I51677295ab6bbc58fc5152106cf2c4c32bd1b0ea
---
M includes/GlobalFunctions.php
1 file changed, 1 insertion(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/80/140880/1

diff --git a/includes/GlobalFunctions.php b/includes/GlobalFunctions.php
index c95c380..eb40e34 100644
--- a/includes/GlobalFunctions.php
+++ b/includes/GlobalFunctions.php
@@ -2891,7 +2891,7 @@
        $cmd = $envcmd . $cmd;
 
        $useLogPipe = false;
-       if ( php_uname( 's' ) == 'Linux' ) {
+       if ( is_executable( '/bin/bash' ) ) {
                $time = intval ( isset( $limits['time'] ) ? $limits['time'] : 
$wgMaxShellTime );
                if ( isset( $limits['walltime'] ) ) {
                        $wallTime = intval( $limits['walltime'] );

-- 
To view, visit https://gerrit.wikimedia.org/r/140880
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I51677295ab6bbc58fc5152106cf2c4c32bd1b0ea
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Brian Wolff <[email protected]>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to