X-Git-Url: http://git.nikiroo.be/?p=fanfix.git;a=blobdiff_plain;f=src%2Fbe%2Fnikiroo%2Ffanfix%2FMain.java;h=41206560a3bde407bf0d1f12ddc1f9081dc00d4d;hp=42f3924daa811bdb1bb6e121d38c01b651bf828b;hb=81b5e730677858a7e9c9fc6f2f8f7992a4b8b1c3;hpb=ad6716a95fa10579b2073fdcc98542ca39ec7bcf diff --git a/src/be/nikiroo/fanfix/Main.java b/src/be/nikiroo/fanfix/Main.java index 42f3924..4120656 100644 --- a/src/be/nikiroo/fanfix/Main.java +++ b/src/be/nikiroo/fanfix/Main.java @@ -351,12 +351,18 @@ public class Main { } } - try { - Instance.getTempFiles().close(); - } catch (IOException e) { - Instance.getTraceHandler() - .error(new IOException( - "Cannot dispose of the temporary files", e)); + // We cannot do it when in GUI mode, because it is async... + // So if we close the temp files before it is actually used, + // we have a problem... + // TODO: close it at the correct time (for now, finalize try to do it) + if (false) { + try { + Instance.getTempFiles().close(); + } catch (IOException e) { + Instance.getTraceHandler().error( + new IOException( + "Cannot dispose of the temporary files", e)); + } } if (exitCode == 255) {