RFR : 7148584 Jar tools fails to generate manifest correctly when boundary condition hit
Alan Bateman
Alan.Bateman at oracle.com
Fri Mar 9 16:18:27 UTC 2012
On 09/03/2012 15:52, Seán Coffey wrote:
> Issue seen when the inner Manifest.FastInputStream.peek() method is
> called just as we hit EOF of main buffer being parsed (the manifest
> input file)
>
> Simple fix involves getting peek() to return -1 if a fill() request
> fails to read anything.
>
> webrev : http://cr.openjdk.java.net/~coffeys/webrev.7148584.jdk8/
> Bug report : http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=7148584
>
> regards,
> Sean.
>
The change looks okay to me.
On the test case then I assume it could have been done with the
java.util.jar APIs rather than calling into the jar command. Also it
might be cleaner to use try-with-resources.
-Alan.
More information about the core-libs-dev
mailing list