ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Will Stranathan <w...@thestranathans.com>
Subject [PATCH] Commandline.java
Date Tue, 02 Jan 2001 17:50:50 GMT
I'm sorry - I had sent a patch yesterday for Commandline.java to correct
the path separator to whatever the system one is.  I perused the code
later on and found that everywhere else it's assumed that the file
separator character is only 1 char long, which is probably true 100% of 
the time, now, anyhow.

Here is a better patch than the one I had provided yesterday.

Please let me know when this can go in - the TDK is dependant on this 
functionality, and we'd prefer to use an "official" build.

Thanks!

Will Stranathan

Index: Commandline.java
===================================================================
RCS file: 
/home/cvspublic/jakarta-ant/src/main/org/apache/tools/ant/types/Commandline.java,v
retrieving revision 1.13
diff -u -r1.13 Commandline.java
--- Commandline.java	2000/11/23 11:32:49	1.13
+++ Commandline.java	2001/01/02 17:48:07
@@ -206,7 +206,8 @@
       */
      public void setExecutable(String executable) {
          if (executable == null || executable.length() == 0) return;
-        this.executable = executable;
+        this.executable = executable.replace('/', File.separatorChar).
+          replace('\\', File.separatorChar);
      }



Mime
View raw message