fix judgement of JPEG support