On Wed, 28 Aug 2024 06:32:44 GMT, Alan Bateman <al...@openjdk.org> wrote:
>> Brent Christian has updated the pull request incrementally with one >> additional commit since the last revision: >> >> move getContentLength() inside try block > > src/java.base/share/classes/jdk/internal/loader/Resource.java line 89: > >> 87: // can propagate upwards without being caught too early >> 88: InputStream in = cachedInputStream(); >> 89: int len = getContentLength(); > > Pre-existing issue but I wonder if this should move into the try block so > that the input stream is closed in the event of getContentLength failing. I agree, that seems like a good idea. ------------- PR Review Comment: https://git.openjdk.org/jdk/pull/20736#discussion_r1735128133