From e86ab796f0e834acc3ac503e4a526d8d19b08218 Mon Sep 17 00:00:00 2001 From: Michael Stack Date: Wed, 20 Apr 2011 18:11:48 +0000 Subject: [PATCH] Reenable the windoze check since this doest not seem to be cause of jenkins test failure of TestShell git-svn-id: https://svn.apache.org/repos/asf/hbase/trunk@1095470 13f79535-47bb-0310-9956-ffa450edef68 --- src/main/ruby/irb/hirb.rb | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/main/ruby/irb/hirb.rb b/src/main/ruby/irb/hirb.rb index 4c58ae1a666..584f70087f4 100644 --- a/src/main/ruby/irb/hirb.rb +++ b/src/main/ruby/irb/hirb.rb @@ -17,13 +17,10 @@ # See the License for the specific language governing permissions and # limitations under the License. # -#require 'rbconfig' +require 'rbconfig' module IRB - # WINDOZE = Config::CONFIG['host_os'] =~ /mswin|mingw/ - # Map the '/dev/null' according to the runing platform - # Under Windows platform the 'dev/null' is not fully compliant with unix, - # and the 'NUL' object need to be use instead. + WINDOZE = Config::CONFIG['host_os'] =~ /mswin|mingw/ # Subclass of IRB so can intercept methods class HIRB < Irb @@ -37,8 +34,11 @@ module IRB # happen is the shell exiting because of failed IRB construction with # no error (though we're not blanking STDERR) begin + # Map the '/dev/null' according to the runing platform + # Under Windows platform the 'dev/null' is not fully compliant with unix, + # and the 'NUL' object need to be use instead. devnull = "/dev/null" - #devnull = "NUL" if WINDOZE + devnull = "NUL" if WINDOZE f = File.open(devnull, "w") $stdout = f super