From af6be759e7ab6c25bd54f10ca509735251358871 Mon Sep 17 00:00:00 2001 From: CalDescent Date: Sun, 12 Feb 2023 13:20:31 +0000 Subject: [PATCH] Fixed long term issue where logs would report "Repository in use by another process?" when the database actually failed to start for some other reason. It will now log the correct reason. --- src/main/java/org/qortal/controller/Controller.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/java/org/qortal/controller/Controller.java b/src/main/java/org/qortal/controller/Controller.java index 054e5530..69995180 100644 --- a/src/main/java/org/qortal/controller/Controller.java +++ b/src/main/java/org/qortal/controller/Controller.java @@ -407,8 +407,8 @@ public class Controller extends Thread { RepositoryManager.rebuildTransactionSequences(repository); } } catch (DataException e) { - // If exception has no cause then repository is in use by some other process. - if (e.getCause() == null) { + // If exception has no cause or message then repository is in use by some other process. + if (e.getCause() == null && e.getMessage() == null) { LOGGER.info("Repository in use by another process?"); Gui.getInstance().fatalError("Repository issue", "Repository in use by another process?"); } else {