]> gerrit.simantics Code Review - simantics/platform.git/blobdiff - bundles/org.simantics.db.indexing/src/org/simantics/db/indexing/IndexedRelationsSearcherBase.java
IndexedRelationsSearcherBase possible deadlock with semaphore
[simantics/platform.git] / bundles / org.simantics.db.indexing / src / org / simantics / db / indexing / IndexedRelationsSearcherBase.java
index c70650ede27bb92c86222654b22e2f039fd12d8a..71db7f6168ac525d69cf1356329f1af081068792 100644 (file)
@@ -698,10 +698,10 @@ abstract public class IndexedRelationsSearcherBase {
                                 }
                             }
                         }
                                 }
                             }
                         }
-
-                        s.release();
                     } catch (DatabaseException e) {
                         throw new IllegalStateException(e);
                     } catch (DatabaseException e) {
                         throw new IllegalStateException(e);
+                    } finally {
+                        s.release();
                     }
                 });
             }
                     }
                 });
             }