Error interpreting JPEG image file (Not a JPEG file: starts with 0x89 0x50)

今天在ubuntu16.04下,打开一张jpg图片时,显示下图错误:


Error interpreting JPEG image file (Not a JPEG file: starts with 0x89 0x50)


但是在同一个文件夹中的,另一张JPG文件可以正常打开,很郁闷,于是上网搜索,原因如下:


Not a JPEG file: starts with 0x89 0x50 的意思,是告诉我们这个档案根本不是 jpg,因为档头是 0x89 0x50,而0x89 0x50是 png 的。于是将该等图片延伸档名更改为 png ,就可以成功看到了。


Error interpreting JPEG image file (Not a JPEG file: starts with 0x89 0x50)


参考:

Linux 下看不到图片问题的解决