RFR: 8313900: Possible NULL pointer access in NativeAudioSpectrum and NativeVideoBuffer
Kevin Rushforth
kcr at openjdk.org
Tue Aug 8 11:36:39 UTC 2023
On Mon, 7 Aug 2023 23:33:37 GMT, Alexander Matveev <almatvee at openjdk.org> wrote:
> - Fixed by checking for `NULL` pointer after memory allocation.
> - In `NativeVideoBuffer` `std::nothrow` was added when allocating `jint` array, so `new` will return `NULL` instead of throwing exception. This done for consistency and also it is not clear how well JNI handles C++ exceptions in this case and what value will Java code get if exception is thrown.
LGTM
-------------
Marked as reviewed by kcr (Lead).
PR Review: https://git.openjdk.org/jfx/pull/1204#pullrequestreview-1567094779
More information about the openjfx-dev
mailing list