OpenCV-Java crashes JVM when calling Core.kmeans with NaN element (Bug #4371)


Added by Hendy Irawan almost 10 years ago. Updated over 9 years ago.


Status:New Start date:2015-06-01
Priority:Normal Due date:
Assignee:Andrey Pavlenko % Done:

0%

Category:java bindings
Target version:2.4.11
Affected version:2.4.9 (latest release) Operating System:Linux
Difficulty: HW Platform:x64
Pull request:

Description

If any input to kmeans() contains NaN element, the JVM will crash immediately (see attachment).

Although NaN is invalid input, it should throw a Java Exception with appropriate error message, even more helpful if showing the coordinate of the affected element.

Affects both 2.4.8 and 2.4.11.

Adding -Xcheck:jni to JVM arguments doesn't help.


hs_err_pid15052.log - JVM crash log (193.1 kB) Hendy Irawan, 2015-06-01 11:55 am


History

Updated by Maksim Shabunin over 9 years ago

Issue has been transferred to GitHub: https://github.com/Itseez/opencv/issues/5006

Also available in: Atom PDF