-
-
Notifications
You must be signed in to change notification settings - Fork 56.5k
Closed
Labels
Description
- OpenCV => 3.2.0 (recent code from github 2017-02-26)
- Operating System / Platform => openSUSE Leap 42.2 64 Bit / Windows 7 64 Bit
- Compiler => gcc 4.8.5 / Visual Studio 2015
If the function "medianBlur" is called with an invalid image (thus the pointer src.ptr() becomes NULL) and "ksize" is greater or equal "7" the calling application crashes with an accessviolation (German: "Speicherzugriffsfehler").
The crash can be reproduced with a simple python3 script:
```.py
import numpy,cv2
img = numpy.zeros((10,10,1),numpy.uint8)# create arbitrary test image
a = 0 # with a = 1 no crash occurs
slc = img[0:a,:] # create empty slice
cv2.medianBlur(slc, 7) # value >= 7 is essential to crash the program
```
(And unfortunately this crash can NOT be handled by a python try-except block.)
Reactions are currently unavailable