mirror of
https://github.com/jenkinsci/jenkins.git
synced 2026-11-10 02:26:18 +00:00
[FIXED HUDSON-4611] hudson.proc.RemoteProc.kill() was a no-op.
git-svn-id: https://hudson.dev.java.net/svn/hudson/trunk/hudson/main@23526 71c3de6d-444a-0410-be80-ed276b4c234a
This commit is contained in:
1 parent
01f8034b32
commit
6ccad2bc32
4 files changed
+152
-9
No files matched your search
@@ -33,6 +33,7 @@ import java.io.IOException;
|
||||
import java.io.InputStream;
|
||||
import java.io.OutputStream;
|
||||
import java.util.Map;
|
||||
import java.util.concurrent.CancellationException;
|
||||
import java.util.concurrent.ExecutionException;
|
||||
import java.util.concurrent.Future;
|
||||
import java.util.logging.Level;
|
||||
@@ -281,7 +282,6 @@ public abstract class Proc {
|
||||
@Override
|
||||
public void kill() throws IOException, InterruptedException {
|
||||
process.cancel(true);
|
||||
join();
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -296,6 +296,8 @@ public abstract class Proc {
|
||||
if(e.getCause() instanceof IOException)
|
||||
throw (IOException)e.getCause();
|
||||
throw new IOException2("Failed to join the process",e);
|
||||
} catch (CancellationException x) {
|
||||
return -1;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user