ignore reading jpeg thumbnail image with no content

(srezic: tweaked original commit to fix indentation)
preparing 1.35_51