From 17c580267f768f2153c674e4e9da37dce9a6a0fe Mon Sep 17 00:00:00 2001 From: Armin Schrenk Date: Wed, 18 Nov 2020 14:35:16 +0100 Subject: [PATCH] prevent race conditions --- .../cryptomator/common/mountpoint/IrregularUnmountCleaner.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/main/commons/src/main/java/org/cryptomator/common/mountpoint/IrregularUnmountCleaner.java b/main/commons/src/main/java/org/cryptomator/common/mountpoint/IrregularUnmountCleaner.java index 4e9866fda..6bcb36f9a 100644 --- a/main/commons/src/main/java/org/cryptomator/common/mountpoint/IrregularUnmountCleaner.java +++ b/main/commons/src/main/java/org/cryptomator/common/mountpoint/IrregularUnmountCleaner.java @@ -28,7 +28,7 @@ class IrregularUnmountCleaner { } - public void clearIrregularUnmountDebrisIfNeeded() { + public synchronized void clearIrregularUnmountDebrisIfNeeded() { if (alreadyChecked || tmpMountPointDir.isEmpty()) { return; //nuthin to do }