DfsInserter#openStream: Suppress resource warning about DfsReader
DfsReader is not opened in a try-with-resource because in the case where the method returns an ObjectStream.Filter, the DfsReader should only be closed from within the Filter's close() method. Suppress the resource warning. Change-Id: Ifcaf5e4a326bd1d03c6331b476c645ca43943b34 Signed-off-by: David Pursehouse <david.pursehouse@gmail.com>
This commit is contained in:
parent
b3a4ace695
commit
84a6318eae
|
@ -669,6 +669,7 @@ private class StreamLoader extends ObjectLoader {
|
|||
|
||||
@Override
|
||||
public ObjectStream openStream() throws IOException {
|
||||
@SuppressWarnings("resource") // Explicitly closed below
|
||||
final DfsReader ctx = db.newReader();
|
||||
if (srcPack != packKey) {
|
||||
try {
|
||||
|
|
Loading…
Reference in New Issue