On Tue, 27 Oct 2026 09:07:33 GMT, Alexey Ushakov <[email protected]> wrote:
>> Matthias Baesken has updated the pull request incrementally with one
>> additional commit since the last revision:
>>
>> ProcessPath.c has similar code
>
> src/java.desktop/share/native/libawt/java2d/loops/ProcessPath.c line 1794:
>
>> 1792: if ((PTR)->plgPnts == (PTR)->dfPlgPnts) {
>> \
>> 1793: Point* _newp = (Point*)malloc(newMax*sizeof(Point));
>> \
>> 1794: if (_newp == NULL) break;
>> \
>
> If we want to add this check, we should properly recover from the allocation
> failure: return an error code to the caller and handle it there. Otherwise,
> we’re just silencing the warning.
Should we then convert the current macro FD_ADD_POINT to an (inline) function
with a boolean return code?
Currently the FD_ADD_POINT is only used at 2 places in StoreFixedLine; not sure
what we would/should do there in case of alloc-failures.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/33513#discussion_r4387328212