summaryrefslogtreecommitdiff
path: root/src/fl_images_core.cxx
diff options
context:
space:
mode:
authorAlbrecht Schlosser <albrechts.fltk@online.de>2020-06-15 02:17:20 +0200
committerAlbrecht Schlosser <albrechts.fltk@online.de>2020-06-15 02:17:20 +0200
commit91b78572c7ab2e4bd7692d2aa5352fcbbb33b236 (patch)
tree4dffe4cccca0c3f9c307f61c28ce97048e521d5d /src/fl_images_core.cxx
parenta7a1e1594c7c574b135a99f80edbf47a7352e974 (diff)
Fix overly restrictive JPEG filter (#81)
See https://github.com/fltk/fltk/issues/81 Fixes #81
Diffstat (limited to 'src/fl_images_core.cxx')
-rw-r--r--src/fl_images_core.cxx6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/fl_images_core.cxx b/src/fl_images_core.cxx
index d610fb8c4..624b6f4c3 100644
--- a/src/fl_images_core.cxx
+++ b/src/fl_images_core.cxx
@@ -86,10 +86,8 @@ fl_check_images(const char *name, // I - Filename
#endif // HAVE_LIBPNG
#ifdef HAVE_LIBJPEG
- if (memcmp(header, "\377\330\377", 3) == 0 &&
- // Start-of-Image
- header[3] >= 0xc0 && header[3] <= 0xef)
- // APPn for JPEG file
+ if (memcmp(header, "\377\330\377", 3) == 0 && // Start-of-Image
+ header[3] >= 0xc0 && header[3] <= 0xfe) // APPn .. comment for JPEG file
return new Fl_JPEG_Image(name);
#endif // HAVE_LIBJPEG