RFR: 8359707: Add classfile modification code to RedefineClassHelper [v2]
Coleen Phillimore
coleenp at openjdk.org
Mon Jun 23 12:46:33 UTC 2025
On Fri, 20 Jun 2025 21:35:33 GMT, Leonid Mesnik <lmesnik at openjdk.org> wrote:
>> Coleen Phillimore has updated the pull request incrementally with one additional commit since the last revision:
>>
>> Add a byte buffer version and rename parameters.
>
> test/lib/RedefineClassHelper.java line 68:
>
>> 66:
>> 67: private static byte[] getBytecodes(ClassLoader loader, String name) throws Exception {
>> 68: InputStream is = loader.getResourceAsStream(name + ".class");
>
> I think this should be
> try(InputStream is = loader.getResourceAsStream(name + ".class");) {
> ...
getBytecodes propagates the exception from getResourceAsStream. If I catch IOException (?), what should it do?
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/25857#discussion_r2161533545
More information about the serviceability-dev
mailing list