After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 397643 - two small io-jpeg.c fixes
two small io-jpeg.c fixes
Status: RESOLVED FIXED
Product: gdk-pixbuf
Classification: Platform
Component: general
git master
Other All
: Normal normal
: ---
Assigned To: gtk-bugs
gtk-bugs
Depends on:
Blocks:
 
 
Reported: 2007-01-17 14:52 UTC by Michael Natterer
Modified: 2010-07-10 04:07 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Patch fixing the bugs (2.03 KB, patch)
2007-01-17 14:54 UTC, Michael Natterer
none Details | Review
pixbuf-load.c by tko (1.21 KB, text/x-csrc)
2007-03-28 13:23 UTC, Tim Janik
  Details
corrupted jpeg test file (65.20 KB, image/jpeg)
2007-03-28 13:26 UTC, Tim Janik
  Details

Description Michael Natterer 2007-01-17 14:52:25 UTC
Attached patch from maemo-gtk fixes two small things in io-jpeg.c
Comment 1 Michael Natterer 2007-01-17 14:54:09 UTC
Created attachment 80513 [details] [review]
Patch fixing the bugs

- return the right boolean value from stop_load()
- pull check for infinite looping out of else branch in load_increment()
Comment 2 Matthias Clasen 2007-02-16 05:05:39 UTC
Mitch, did we come to a conclusion about this patch ? Did tko dig out test cases ?
Comment 3 Tim Janik 2007-03-28 13:23:59 UTC
Created attachment 85442 [details]
pixbuf-load.c by tko

pixbuf-load will load & scale a pixbuf when options -w or -h are given, using gdk_pixbuf_new_from_file_at_size() which uses different loader code paths than gdk_pixbuf_new_from_file().
Comment 4 Tim Janik 2007-03-28 13:26:57 UTC
Created attachment 85443 [details]
corrupted jpeg test file

this jpeg file when loaded with gdk_pixbuf_new_from_file_at_size(), like:
  ./pixbuf-load -w 64 -h 54 scale+hang.jpg 
will cause the pixbuf loaders to hang.
Comment 5 Tim Janik 2007-03-28 13:33:28 UTC
Wed Mar 28 15:27:35 2007  Tim Janik  <timj@imendio.com>

        * io-jpeg.c: applied JPEG loader fix from maemo. this fix makes sure
        stop_load() doesn't forget about its return value, and it pulls the
        check for infinite looping out of an else branch in load_increment()
        so it runs unconditionally, fixes #397643.