You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pig.apache.org by da...@apache.org on 2012/11/01 00:20:19 UTC
svn commit: r1404418 - in /pig/trunk: CHANGES.txt
src/org/apache/pig/parser/StreamingCommandUtils.java
Author: daijy
Date: Wed Oct 31 23:20:19 2012
New Revision: 1404418
URL: http://svn.apache.org/viewvc?rev=1404418&view=rev
Log:
PIG-2953: "which" utility does not exist on Windows (daijy)
Modified:
pig/trunk/CHANGES.txt
pig/trunk/src/org/apache/pig/parser/StreamingCommandUtils.java
Modified: pig/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/pig/trunk/CHANGES.txt?rev=1404418&r1=1404417&r2=1404418&view=diff
==============================================================================
--- pig/trunk/CHANGES.txt (original)
+++ pig/trunk/CHANGES.txt Wed Oct 31 23:20:19 2012
@@ -523,6 +523,8 @@ Release 0.10.1 - Unreleased
BUG FIXES
+PIG-2953: "which" utility does not exist on Windows (daijy)
+
PIG-2960: Increase the timeout for unit test (daijy)
PIG-2942: DevTests, TestLoad has a false failure on Windows (jgordon via daijy)
Modified: pig/trunk/src/org/apache/pig/parser/StreamingCommandUtils.java
URL: http://svn.apache.org/viewvc/pig/trunk/src/org/apache/pig/parser/StreamingCommandUtils.java?rev=1404418&r1=1404417&r2=1404418&view=diff
==============================================================================
--- pig/trunk/src/org/apache/pig/parser/StreamingCommandUtils.java (original)
+++ pig/trunk/src/org/apache/pig/parser/StreamingCommandUtils.java Wed Oct 31 23:20:19 2012
@@ -166,8 +166,12 @@ public class StreamingCommandUtils {
private static String which(String file) {
try {
+ String utility = "which";
+ if (Util.WINDOWS) {
+ utility = "where";
+ }
ProcessBuilder processBuilder =
- new ProcessBuilder(new String[] {"which", file});
+ new ProcessBuilder(new String[] {utility, file});
Process process = processBuilder.start();
BufferedReader stdout =