summaryrefslogtreecommitdiffstats
path: root/org.eclipse.jgit
diff options
context:
space:
mode:
Diffstat (limited to 'org.eclipse.jgit')
-rw-r--r--org.eclipse.jgit/src/org/eclipse/jgit/util/FS.java8
1 files changed, 7 insertions, 1 deletions
diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/util/FS.java b/org.eclipse.jgit/src/org/eclipse/jgit/util/FS.java
index 229355c50a..1cc39bd46c 100644
--- a/org.eclipse.jgit/src/org/eclipse/jgit/util/FS.java
+++ b/org.eclipse.jgit/src/org/eclipse/jgit/util/FS.java
@@ -497,7 +497,13 @@ public abstract class FS {
if (env != null) {
pb.environment().putAll(env);
}
- Process p = pb.start();
+ Process p;
+ try {
+ p = pb.start();
+ } catch (IOException e) {
+ // Process failed to start
+ throw new CommandFailedException(-1, e.getMessage(), e);
+ }
p.getOutputStream().close();
GobblerThread gobbler = new GobblerThread(p, command, dir);
gobbler.start();