Fix loading of inline JPEG images