HHH-9528 close InputStreams in jpamodelgen JpaDescriptorParser
This commit is contained in:
parent
8e84c7d896
commit
218851e6fe
|
@ -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