From: David ‘Bombe’ Roden Date: Wed, 24 Dec 2008 00:56:08 +0000 (+0100) Subject: Throw exception instead of simply returning in case the lockfile override is not... X-Git-Tag: 0.7~16 X-Git-Url: https://git.pterodactylus.net/?a=commitdiff_plain;h=195933c1bcb643143275b2725b01acecda59bcce;p=jSite.git Throw exception instead of simply returning in case the lockfile override is not activated. --- diff --git a/src/de/todesbaum/jsite/main/Main.java b/src/de/todesbaum/jsite/main/Main.java index 909ffa6..b04473d 100644 --- a/src/de/todesbaum/jsite/main/Main.java +++ b/src/de/todesbaum/jsite/main/Main.java @@ -154,7 +154,7 @@ public class Main implements ActionListener, ListSelectionListener, WizardListen if (!configuration.createLockFile()) { int option = JOptionPane.showOptionDialog(null, I18n.getMessage("jsite.main.already-running"), "", JOptionPane.YES_NO_OPTION, JOptionPane.QUESTION_MESSAGE, null, new Object[] { I18n.getMessage("jsite.main.already-running.override"), I18n.getMessage("jsite.wizard.quit") }, I18n.getMessage("jsite.wizard.quit")); if (option != 0) { - return; + throw new IllegalStateException("Lockfile override not active, refusing start."); } configuration.removeLockfileOnExit(); }