RFR: 8347334: JimageDiffGenerator code clean-ups [v2]
Severin Gehwolf
sgehwolf at openjdk.org
Fri Jan 10 10:14:08 UTC 2025
On Thu, 9 Jan 2025 18:51:09 GMT, Henry Jen <henryjen at openjdk.org> wrote:
>> Severin Gehwolf has updated the pull request incrementally with one additional commit since the last revision:
>>
>> Review feedback
>
> src/jdk.jlink/share/classes/jdk/tools/jlink/internal/runtimelink/JimageDiffGenerator.java line 135:
>
>> 133: bytesRead2 = is2.readNBytes(buf2, 0, buf2.length);
>> 134: if (bytesRead1 == 0 || bytesRead2 == 0) {
>> 135: break; // no more bytes for a stream
>
> break after test same amount of bytes can remove the test exit the while loop.
I went with @archiecobbs suggestion which simplifies this.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/23014#discussion_r1910142221
More information about the core-libs-dev
mailing list