Skip to content

Commit 5331478

Browse files
fix FileSynchronizer null handling in java class.
1 parent cb61f55 commit 5331478

1 file changed

Lines changed: 5 additions & 3 deletions

File tree

module/storage/src/main/java/org/openbase/jul/storage/registry/FileSynchronizedRegistryImpl.java

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -213,10 +213,12 @@ public ENTRY remove(final ENTRY entry) throws CouldNotPerformException {
213213
fileSynchronizerMapLock.writeLock().unlock();
214214
}
215215

216-
filePluginPool.beforeRemove(entry, fileSynchronizer);
217-
fileSynchronizer.delete();
216+
if (fileSynchronizer != null) {
217+
filePluginPool.beforeRemove(entry, fileSynchronizer);
218+
fileSynchronizer.delete();
219+
filePluginPool.afterRemove(entry, fileSynchronizer);
220+
}
218221
fileSynchronizerMap.remove(entry.getId());
219-
filePluginPool.afterRemove(entry, fileSynchronizer);
220222
return removedValue;
221223
} catch (InterruptedException ex) {
222224
Thread.currentThread().interrupt();

0 commit comments

Comments
 (0)