[前][次][番号順一覧][スレッド一覧]

ruby-changes:12675

From: usa <ko1@a...>
Date: Tue, 4 Aug 2009 22:16:06 +0900 (JST)
Subject: [ruby-changes:12675] Ruby:r24390 (ruby_1_8): * win32/win32.c (has_redirection): need to execute shell if commandline

usa	2009-08-04 22:15:50 +0900 (Tue, 04 Aug 2009)

  New Revision: 24390

  http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=24390

  Log:
    * win32/win32.c (has_redirection): need to execute shell if commandline
      includes newline.  cf. [ruby-core:24560]

  Modified files:
    branches/ruby_1_8/ChangeLog
    branches/ruby_1_8/win32/win32.c

Index: ruby_1_8/ChangeLog
===================================================================
--- ruby_1_8/ChangeLog	(revision 24389)
+++ ruby_1_8/ChangeLog	(revision 24390)
@@ -1,3 +1,8 @@
+Tue Aug  4 22:15:27 2009  NAKAMURA Usaku  <usa@r...>
+
+	* win32/win32.c (has_redirection): need to execute shell if commandline
+	  includes newline.  cf. [ruby-core:24560]
+
 Tue Aug  4 03:56:51 2009  Hidetoshi NAGAI  <nagai@a...>
 
 	* ext/tk/lib/tcltklib.c: fix trouble on old-style C function
Index: ruby_1_8/win32/win32.c
===================================================================
--- ruby_1_8/win32/win32.c	(revision 24389)
+++ ruby_1_8/win32/win32.c	(revision 24390)
@@ -1196,8 +1196,8 @@
     const char *ptr;
 
     //
-    // Scan the string, looking for redirection (< or >) or pipe 
-    // characters (|) that are not in a quoted string
+    // Scan the string, looking for redirection characters (< or >), pipe
+    // character (|) or newline (\n) that are not in a quoted string
     //
 
     for (ptr = cmd; *ptr;) {
@@ -1214,6 +1214,7 @@
 	  case '>':
 	  case '<':
 	  case '|':
+	  case '\n':
 	    if (!quote)
 		return TRUE;
 	    ptr++;

--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]