pig-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From g...@apache.org
Subject svn commit: r1362684 - in /pig/trunk: CHANGES.txt src/org/apache/pig/PigServer.java
Date Tue, 17 Jul 2012 22:10:06 GMT
Author: gdfm
Date: Tue Jul 17 22:10:05 2012
New Revision: 1362684

URL: http://svn.apache.org/viewvc?rev=1362684&view=rev
Log:
PIG-2800: pig.additional.jars path separator should align with File.pathSeparator instead
of being hard-coded to ":" (jgordon via azaroth)

Modified:
    pig/trunk/CHANGES.txt
    pig/trunk/src/org/apache/pig/PigServer.java

Modified: pig/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/pig/trunk/CHANGES.txt?rev=1362684&r1=1362683&r2=1362684&view=diff
==============================================================================
--- pig/trunk/CHANGES.txt (original)
+++ pig/trunk/CHANGES.txt Tue Jul 17 22:10:05 2012
@@ -24,6 +24,8 @@ INCOMPATIBLE CHANGES
 
 IMPROVEMENTS
 
+PIG-2800: pig.additional.jars path separator should align with File.pathSeparator instead
of being hard-coded to ":" (jgordon via azaroth)
+
 PIG-2797: Tests should not create their own file URIs through string concatenation, should
use Util.generateURI instead (jgordon via azaroth)
 
 PIG-2820: relToAbsolutePath is not replayed properly when Grunt reparses the script after
PIG-2699 (julien)

Modified: pig/trunk/src/org/apache/pig/PigServer.java
URL: http://svn.apache.org/viewvc/pig/trunk/src/org/apache/pig/PigServer.java?rev=1362684&r1=1362683&r2=1362684&view=diff
==============================================================================
--- pig/trunk/src/org/apache/pig/PigServer.java (original)
+++ pig/trunk/src/org/apache/pig/PigServer.java Tue Jul 17 22:10:05 2012
@@ -219,8 +219,12 @@ public class PigServer {
     private void addJarsFromProperties() throws ExecException {
         //add jars from properties to extraJars
         String jar_str = pigContext.getProperties().getProperty("pig.additional.jars");
+
         if(jar_str != null){
-            for(String jar : jar_str.split(":")){
+            // Use File.pathSeparator (":" on Linux, ";" on Windows)
+            // to correctly handle path aggregates as they are represented
+            // on the Operating System.
+            for(String jar : jar_str.split(File.pathSeparator)){
                 try {
                     registerJar(jar);
                 } catch (IOException e) {



Mime
View raw message