wait up to 5 seconds for the headless firefox to die(sounds creepy when I say it like that)

This commit is contained in:
idk
2022-09-07 11:49:21 -04:00
parent 368d9c3423
commit 4d605d40b2

View File

@ -444,6 +444,7 @@ public class I2PFirefox extends I2PCommonBrowser {
println("Headless browser run completed, exit: " + hev);
if (!hev)
hp.destroy();
hev = hp.waitFor(5, TimeUnit.SECONDS);
if (hp.isAlive()) {
int forcedExitCode = hp.destroyForcibly().waitFor();
println("Headless browser run forcibly terminated, exit: " +