From: Tim Starling Date: Tue, 14 Dec 2010 10:57:41 +0000 (+0000) Subject: Update references for wfEscapeShellArg() for r69732 etc. The very useful mailing... X-Git-Tag: 1.31.0-rc.0~33321 X-Git-Url: http://git.cyclocoop.org/%22%20.%20generer_url_aide%28?a=commitdiff_plain;h=84f3b30f9ce9e2d4f5838d738d0f08f06f6a96a9;p=lhc%2Fweb%2Fwiklou.git Update references for wfEscapeShellArg() for r69732 etc. The very useful mailing list post that I cited has disappeared from the web! --- diff --git a/includes/GlobalFunctions.php b/includes/GlobalFunctions.php index e0d70ad786..3aa22c8753 100644 --- a/includes/GlobalFunctions.php +++ b/includes/GlobalFunctions.php @@ -1442,8 +1442,12 @@ function wfEscapeShellArg( ) { } if ( wfIsWindows() ) { - // Escaping for an MSVC-style command line parser - // Ref: http://mailman.lyra.org/pipermail/scite-interest/2002-March/000436.html + // Escaping for an MSVC-style command line parser and CMD.EXE + // Refs: + // * http://web.archive.org/web/20020708081031/http://mailman.lyra.org/pipermail/scite-interest/2002-March/000436.html + // * http://technet.microsoft.com/en-us/library/cc723564.aspx + // * Bug #13518 + // * CR r63214 // Double the backslashes before any double quotes. Escape the double quotes. $tokens = preg_split( '/(\\\\*")/', $arg, -1, PREG_SPLIT_DELIM_CAPTURE ); $arg = '';