Skip to content

Commit

Permalink
[-] reduce memory allocations
Browse files Browse the repository at this point in the history
  • Loading branch information
alex-karpovich committed Jan 9, 2024
1 parent d79cf6a commit ae16185
Showing 1 changed file with 6 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1193,12 +1193,14 @@ private void openOrSeek (FileInput in, int toOffset)
}

private void close(FileInput in) {
if (in != null && in.close()) {
if (LOGGER.isDebugEnabled())
LOGGER.debug().append("closing ").append(getPathString()).commit();
if (in != null) {
if (in.close()) {
if (LOGGER.isDebugEnabled())
LOGGER.debug().append("closing ").append(getPathString()).commit();
root.releaseSharedLock();
}

inputs.release(in);
root.releaseSharedLock();
}
}

Expand Down

0 comments on commit ae16185

Please sign in to comment.