Skip to content

Commit 0710dec

Browse files
author
James Leigh
committed
Fix #774: Change all SailSourceModel fields to be synchronized
Signed-off-by: James Leigh <james.leigh@ontotext.com>
1 parent 8fea325 commit 0710dec

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

core/sail/nativerdf/src/main/java/org/eclipse/rdf4j/sail/nativerdf/SailSourceModel.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -239,7 +239,7 @@ public synchronized boolean add(Resource subj, IRI pred, Value obj, Resource...
239239
if (subj == null || pred == null || obj == null)
240240
throw new UnsupportedOperationException("Incomplete statement");
241241
try {
242-
if (contains(dataset, subj, pred, obj, contexts)) {
242+
if (contains(subj, pred, obj, contexts)) {
243243
logger.trace("already contains statement {} {} {} {}", subj, pred, obj, contexts);
244244
return false;
245245
}
@@ -383,7 +383,7 @@ public synchronized void removeTermIteration(Iterator<Statement> iter, Resource
383383
}
384384
}
385385

386-
private SailSink sink()
386+
private synchronized SailSink sink()
387387
throws SailException
388388
{
389389
if (sink == null) {
@@ -392,7 +392,7 @@ private SailSink sink()
392392
return sink;
393393
}
394394

395-
private SailDataset dataset()
395+
private synchronized SailDataset dataset()
396396
throws SailException
397397
{
398398
if (sink != null) {

0 commit comments

Comments
 (0)