RFR: 8059767: FileHandler should allow 'long' limits and handle overflow of MeteredStream.written.

Daniel Fuchs daniel.fuchs at oracle.com
Tue Oct 7 13:13:13 UTC 2014


Hi,

Please find below a patch for:

8059767: FileHandler should allow 'long' limits and handle overflow
          of MeteredStream.written.
https://bugs.openjdk.java.net/browse/JDK-8059767

webrev:
http://cr.openjdk.java.net/~dfuchs/webrev_8059767/webrev.00/

This follows an issue reported on this list:
http://mail.openjdk.java.net/pipermail/core-libs-dev/2014-August/028280.html

The patch changes 'limit' from 'int' to 'long', fixes the
handling of overflow, and adds a new constructor that allows
to pass a long for 'limit'.
It also makes it possible to specify a long value for 'limit'
in the configuration.

The test checks the handling of overflow by tweaking the
internal of MeteredStream through reflection. Not ideal, but
I couldn't find any other way.

best regards,

-- daniel



More information about the core-libs-dev mailing list