From: thomas.sondergaard@... Date: 2015-03-14T10:46:21+00:00 Subject: [ruby-core:68526] [Ruby trunk - Bug #10973] [Open] Silent failure when launching ruby with command line parameters for script that matches directory and contains [ Issue #10973 has been reported by Thomas Sondergaard. ---------------------------------------- Bug #10973: Silent failure when launching ruby with command line parameters for script that matches directory and contains [ https://bugs.ruby-lang.org/issues/10973 * Author: Thomas Sondergaard * Status: Open * Priority: Normal * Assignee: * ruby -v: ruby 2.2.1p85 (2015-02-26 revision 49769) [x64-mingw32] * Backport: 2.0.0: UNKNOWN, 2.1: UNKNOWN, 2.2: UNKNOWN ---------------------------------------- I have a script that passes a regular expression to a ruby script that matches a file path. This regular expression contains the character '['. After upgrading from ruby 2.0.0 to ruby 2.2.1 on Windows ruby no longer works when a script is passed a command line argument that partially matches a directory and contains the character '['. See the following example: First example: Current working dir is D:\ and 'D:\foo' doesn't exist. The script executes without incident: d:\>ruby -e "puts 'hello'" D:/foo/bar/[ hello d:\>echo %errorlevel% 0 Second example: Same current working directory and same command, only now there is a directory D:\foo: d:\>mkdir foo d:\>ruby -e "puts 'hello'" D:/foo/bar/[ d:\>echo %errorlevel% -1073741819 This is a regression from earlier version of ruby. I have not tested on other platforms than Windows. -- https://bugs.ruby-lang.org/