Integrated: 8309508: Possible memory leak in JPEG image loader
Jayathirth D V
jdv at openjdk.org
Mon Jun 12 16:01:51 UTC 2023
On Fri, 9 Jun 2023 05:18:16 GMT, Jayathirth D V <jdv at openjdk.org> wrote:
> On code inspection it is revealed that in jpegloader.c->decompressIndirect() we are allocating memory for "scanline_ptr", but if we error_exit() from jpeg_read_scanlines() we are not releasing this memory.
>
> Added release of "scanline_ptr" with NULL check at appropriate places.
> As part of this fix also added RELEASE_ARRAYS() call for stream/pixel buffer in all cases where we move back to Java code.
>
> Its difficult to create definite pass/fail regression test for memory leak, added noreg-hard label in JBS.
This pull request has now been integrated.
Changeset: bd24fc72
Author: Jayathirth D V <jdv at openjdk.org>
Committer: Kevin Rushforth <kcr at openjdk.org>
URL: https://git.openjdk.org/jfx/commit/bd24fc7286725358f109863e6cc8a6c3abb354e1
Stats: 14 lines in 1 file changed: 9 ins; 0 del; 5 mod
8309508: Possible memory leak in JPEG image loader
Reviewed-by: kcr, arapte
-------------
PR: https://git.openjdk.org/jfx/pull/1151
More information about the openjfx-dev
mailing list