[Libreoffice-commits] core.git: Branch 'libreoffice-6-2' - jurt/com

Libreoffice Gerrit user logerrit at kemper.freedesktop.org
Mon Feb 18 17:58:52 UTC 2019


 jurt/com/sun/star/lib/util/AsynchronousFinalizer.java |    4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

New commits:
commit f249cb6e142e9fcc771cc8a40e347a13b201760e
Author:     Samuel Mehrbrodt <Samuel.Mehrbrodt at cib.de>
AuthorDate: Fri Feb 15 11:31:04 2019 +0100
Commit:     Michael Stahl <Michael.Stahl at cib.de>
CommitDate: Mon Feb 18 18:58:32 2019 +0100

    tdf#123481 jurt: Avoid thread deadlocking
    
    Change-Id: I7b6454090aeb1046a814520166a5b8c39b716f6d
    Reviewed-on: https://gerrit.libreoffice.org/67861
    Tested-by: Jenkins
    Reviewed-by: Noel Grandin <noel.grandin at collabora.co.uk>
    Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt at cib.de>
    (cherry picked from commit ea3c25358e3136cf900bc4e7d1bd6387dcca7883)
    Reviewed-on: https://gerrit.libreoffice.org/67958
    Reviewed-by: Stephan Bergmann <sbergman at redhat.com>
    Reviewed-by: Michael Stahl <Michael.Stahl at cib.de>

diff --git a/jurt/com/sun/star/lib/util/AsynchronousFinalizer.java b/jurt/com/sun/star/lib/util/AsynchronousFinalizer.java
index 0e7ecc41ba4d..588b8fe388f6 100644
--- a/jurt/com/sun/star/lib/util/AsynchronousFinalizer.java
+++ b/jurt/com/sun/star/lib/util/AsynchronousFinalizer.java
@@ -92,7 +92,9 @@ public final class AsynchronousFinalizer {
             done = true;
             queue.notify();
         }
-        thread.join();
+        // tdf#123481 Only join if we are not in our own thread, else we have a deadlock
+        if (Thread.currentThread() != thread)
+            thread.join();
     }
 
     /**


More information about the Libreoffice-commits mailing list