bug fix for a crash when input image is small