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 56837 - ICO loader crash - assert
ICO loader crash - assert
Status: RESOLVED FIXED
Product: gdk-pixbuf
Classification: Platform
Component: general
git master
Other Linux
: Normal major
: ---
Assigned To: gtk-bugs
gtk-bugs
: 61045 75888 78717 83548 84753 85012 85903 112845 (view as bug list)
Depends on: 61179
Blocks:
 
 
Reported: 2001-06-28 23:07 UTC by Yanko Kaneti
Modified: 2010-07-10 04:05 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
the crasher (1.12 KB, application/octet-stream)
2001-06-28 23:08 UTC, Yanko Kaneti
Details

Description Yanko Kaneti 2001-06-28 23:07:28 UTC
hi this is duplicate of GdkPixbuf bug in ximian's bugzilla
http://bugzilla.ximian.com/show_bug.cgi?id=2065
i was not sure if someone is watching there so i copied that here


gtk+ HEAD from today

here is the assert and i'll attach the image (its also in the URL)

Visual type = direct color, depth = 24, ff0000:ff00:ff; score=9100
Visual type = true color, depth = 24, ff0000:ff00:ff (system); score=9111
Chose visual type=true color depth=24, image bpp=32, lsb first

lt-testpixbuf (pid:8839): ** ERROR **: file io-ico.c: line 352
(DecodeHeader): assertion failed: (State->LineBuf != NULL)
aborting...
Trace/breakpoint trap (core dumped)
Comment 1 Yanko Kaneti 2001-06-28 23:08:13 UTC
Created attachment 693 [details]
the crasher
Comment 2 Yanko Kaneti 2001-07-14 21:57:43 UTC
small addition

the patch from sandmann@daimi.au.dk
http://bugzilla.gnome.org/showattachment.cgi?attach_id=737
attached to
http://bugzilla.gnome.org/show_bug.cgi?id=50187
improves the situation
now the loader dosnt crash
lt-testpixbuf (pid:4053): ** WARNING **: Error loading image: Failed
to load image '/home/yaneti/favicon.ico': Not enough memory to load icon

i guess this is also a bug but at least its not crashing
Comment 3 Yanko Kaneti 2001-08-27 16:40:40 UTC
this got worse again: todays cvsVisual type = direct color, depth =
16, f800:7e0:1f; score=8100
Visual type = direct color, depth = 16, f800:7e0:1f; score=8100
Visual type = true color, depth = 16, f800:7e0:1f (system); score=8111
Visual type = true color, depth = 16, f800:7e0:1f; score=8101
Chose visual type=true color depth=16, image bpp=16, lsb first

lt-testpixbuf (pid:23004): ** CRITICAL **: file gdk-pixbuf.c: line 149
(gdk_pixbuf_new): assertion `height > 0' failed

lt-testpixbuf (pid:23004): ** ERROR **: file io-wbmp.c: line 281
(gdk_pixbuf__wbmp_image_load_increment): assertion failed:
(context->pixbuf)
aborting...
Trace/breakpoint trap (core dumped)

Comment 4 Yanko Kaneti 2001-09-25 00:00:33 UTC
*** Bug 61045 has been marked as a duplicate of this bug. ***
Comment 5 Yanko Kaneti 2001-09-25 00:02:26 UTC
here is another ico crasher comming from the duplicate above

http://www.diario16.es/favicon.ico

right now i am unable to test with HEAD so please excuse me if its working

Comment 6 Federico Mena Quintero 2001-09-25 21:33:41 UTC
Fixed on CVS.
Comment 7 Federico Mena Quintero 2001-09-25 23:52:12 UTC
Reopening because this bug refers to the GTK+/gdk-pixbuf version, not
to the stable branch of gdk-pixbuf where it was indeed fixed.
Comment 8 Yanko Kaneti 2001-10-04 10:57:36 UTC
just wanted to add that indeed all these are valid icons

here is another testcase

http://phpclasses.upperdesign.com/favicon.ico
Comment 9 Matthias Clasen 2001-10-25 14:32:27 UTC
The last testcase (the php icon) seems to be not valid. Inserting

g_message ("Icon %d of %d: w %d h %d c %d --> score %d", 
           I+1, IconCount, ThisWidth, ThisHeight, ThisColors,
           ThisScore);
DumpBIH(Data + ((Ptr[15]<<24) + (Ptr[14]<<16) + (Ptr[13]<<8) +
                (Ptr[12])));

after the assignment to ThisScore in the IconCount loop in 
DecodeHeader yields the following, which seems to indicate
that the ICO header is broken for the last contained image:

Message: Icon 1 of 4: w 16 h 16 c 256 --> score 262400
biSize      = 40
biWidth     = 16
biHeight    = 32
biPlanes    = 1
biBitCount  = 8
biCompress  = 0
biSizeImage = 288
biXPels     = 0
biYPels     = 0
biClrUsed   = 256
biClrImprtnt= 0
Message: Icon 2 of 4: w 32 h 32 c 256 --> score 263168
biSize      = 40
biWidth     = 32
biHeight    = 64
biPlanes    = 1
biBitCount  = 8
biCompress  = 0
biSizeImage = 1152
biXPels     = 0
biYPels     = 0
biClrUsed   = 256
biClrImprtnt= 0
Message: Icon 3 of 4: w 48 h 48 c 256 --> score 264448
biSize      = 40
biWidth     = 48
biHeight    = 96
biPlanes    = 1
biBitCount  = 8
biCompress  = 0
biSizeImage = 2688
biXPels     = 0
biYPels     = 0
biClrUsed   = 256
biClrImprtnt= 0
Message: Icon 4 of 4: w 64 h 64 c 256 --> score 266240
biSize      = 0
biWidth     = -16842752
biHeight    = 0
biPlanes    = 0
biBitCount  = 65279
biCompress  = 0
biSizeImage = -67174400
biXPels     = 0
biYPels     = -67174400
biClrUsed   = 0
biClrImprtnt= -65536
biSize      = 0
biWidth     = -16842752
biHeight    = 0
biPlanes    = 0
biBitCount  = 65279
biCompress  = 0
biSizeImage = -67174400
biXPels     = 0
biYPels     = -67174400
biClrUsed   = 0
biClrImprtnt= -65536                                                            

Comment 10 Matthias Clasen 2001-10-25 15:02:43 UTC
Opening the php icon in the MSVC++ resource editor gives the same
impression: three valid images, followed by rubbish. I don't know
if we should "fix" the ico loader to fall back to one of the lower
score images if it finds rubbish.
Comment 11 Owen Taylor 2002-01-23 19:25:14 UTC
What needs fixing for now is assertion failures or crashes;
if it fails to load ico formats it doesn't know about; that
can be left for later.
Comment 12 Matthias Clasen 2002-01-24 16:05:43 UTC
With 1.3.12, the crashers attached above give:

testpixbuf (pid:3656): ** WARNING **: Error loading image: Failed to load image
'animations/ico1.ico': Not enough memory to load icon                           
and 

testpixbuf (pid:3657): ** WARNING **: Error loading image: Failed to load image
'animations/ico2.ico': Icon has zero height                                     
which looks like nice GError returns to me, so I guess this bug can
be closed.
Comment 13 Matthias Clasen 2002-02-08 14:31:59 UTC
Closing this now.
Comment 14 Yanko Kaneti 2002-03-22 11:35:48 UTC
*** Bug 75888 has been marked as a duplicate of this bug. ***
Comment 15 Yanko Kaneti 2002-04-15 05:08:42 UTC
*** Bug 78717 has been marked as a duplicate of this bug. ***
Comment 16 Yanko Kaneti 2002-05-30 15:34:05 UTC
*** Bug 83548 has been marked as a duplicate of this bug. ***
Comment 17 Yanko Kaneti 2002-06-10 16:20:23 UTC
*** Bug 84753 has been marked as a duplicate of this bug. ***
Comment 18 Yanko Kaneti 2002-06-12 14:50:27 UTC
*** Bug 85012 has been marked as a duplicate of this bug. ***
Comment 19 Yanko Kaneti 2002-06-19 05:12:10 UTC
*** Bug 85903 has been marked as a duplicate of this bug. ***
Comment 20 Yanko Kaneti 2003-04-01 08:18:11 UTC
*** Bug 109664 has been marked as a duplicate of this bug. ***
Comment 21 Yanko Kaneti 2003-05-12 17:11:15 UTC
*** Bug 112845 has been marked as a duplicate of this bug. ***
Comment 22 Bugzilla Maintainers 2004-04-01 23:44:57 UTC
The URL field has been removed from bugzilla.gnome.org. This URL was in the old URL field, and is being added as a comment so that the data is not lost. Please email bugmaster@gnome.org if you have any questions.

URL: 
http://www.joystick.fr/favicon.ico
Comment 23 Max Kanat-Alexander 2009-08-21 03:20:03 UTC
This bug was marked RESOLVED without a resolution, which Bugzilla does not allow (and so I am fixing it). It is assumed that the bug was intended to be marked as FIXED. If the bug should have some other resolution, please change its resolution.