Skip to content
Permalink
Browse files

fixed JENKINS-8614 ProcessTreeTest fails on Windows

  • Loading branch information...
lmwang committed Apr 6, 2013
1 parent 4709490 commit cdc18ec56987204535c9919ea385c555d3d66863
Showing with 10 additions and 9 deletions.
  1. +10 −9 core/src/main/java/hudson/util/ProcessTree.java
@@ -425,16 +425,17 @@ public void kill() throws InterruptedException {

@Override
public synchronized EnvVars getEnvironmentVariables() {
if(env==null)
if(env !=null)
return env;
env = new EnvVars();

try
{
try
{
env = new EnvVars(p.getEnvironmentVariables());
} catch (WinpException e)
{
LOGGER.log(FINE, "Failed to get environment variable ", e);
}
}
env.putAll(p.getEnvironmentVariables());
} catch (WinpException e)
{
LOGGER.log(FINE, "Failed to get environment variable ", e);
}
return env;
}
});

0 comments on commit cdc18ec

Please sign in to comment.
You can’t perform that action at this time.