Skip to content

Commit 1e83f0b

Browse files
line-oadamretter
authored andcommitted
[bugfix] PermissionDeniedExcpetion in defragXMLResource
1 parent 9ca293b commit 1e83f0b

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

exist-core/src/main/java/org/exist/storage/NativeBroker.java

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3033,8 +3033,7 @@ public Object start() {
30333033
}
30343034
}.run();
30353035
// create a copy of the old doc to copy the nodes into it
3036-
final DocumentImpl tempDoc = new DocumentImpl(null, doc.getDocId(), doc);
3037-
tempDoc.copyOf(this, doc, doc);
3036+
final DocumentImpl tempDoc = new DocumentImpl(null, pool, doc.getCollection(), doc.getDocId(), doc.getFileURI());
30383037
final StreamListener listener = getIndexController().getStreamListener(doc, ReindexMode.STORE);
30393038
// copy the nodes
30403039
final NodeList nodes = doc.getChildNodes();
@@ -3067,7 +3066,7 @@ public Object start() {
30673066
if (LOG.isDebugEnabled()) {
30683067
LOG.debug("Defragmentation took {} ms.", (System.currentTimeMillis() - start));
30693068
}
3070-
} catch(final PermissionDeniedException | IOException e) {
3069+
} catch(IOException e) {
30713070
LOG.error(e);
30723071
}
30733072
}

0 commit comments

Comments
 (0)