Commits

James Dumay committed bdcdce8

should use isWindows() to check if we need to use winp to destroy the process and catch all throwables around the winp usage

  • Participants
  • Parent commits 6fe61d4

Comments (0)

Files changed (1)

File src/main/java/com/atlassian/utils/process/ExternalProcess.java

 
         if (process != null)
         {
-            if (OS_NAME.startsWith("Windows"))
+            if (isWindows())
             {
                 try
                 {
                     final WinProcess winProcess = new WinProcess(process);
                     winProcess.killRecursively();
                 }
-                catch (UnsatisfiedLinkError e)
+                catch (Throwable e)
                 {
                     log.error("Could not recursively kill windows process using winp; falling back to java.lang.Process#destroy", e);
                     process.destroy();