HHH-9528 close InputStreams in jpamodelgen JpaDescriptorParser
This commit is contained in:
parent
f1a9a9f006
commit
7f17e50c72
|
@ -139,6 +139,13 @@ public class JpaDescriptorParser {
|
|||
Diagnostic.Kind.WARNING, "Unable to parse persistence.xml: " + e.getMessage()
|
||||
);
|
||||
}
|
||||
|
||||
try {
|
||||
stream.close();
|
||||
} catch (IOException e) {
|
||||
// eat it
|
||||
}
|
||||
|
||||
return persistence;
|
||||
}
|
||||
|
||||
|
@ -161,6 +168,12 @@ public class JpaDescriptorParser {
|
|||
if ( mapping != null ) {
|
||||
entityMappings.add( mapping );
|
||||
}
|
||||
|
||||
try {
|
||||
stream.close();
|
||||
} catch (IOException e) {
|
||||
// eat it
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue