gimp r26574 - in trunk: . plug-ins/file-ico
- From: neo svn gnome org
- To: svn-commits-list gnome org
- Subject: gimp r26574 - in trunk: . plug-ins/file-ico
- Date: Fri, 15 Aug 2008 17:50:15 +0000 (UTC)
Author: neo
Date: Fri Aug 15 17:50:15 2008
New Revision: 26574
URL: http://svn.gnome.org/viewvc/gimp?rev=26574&view=rev
Log:
2008-08-15 Sven Neumann <sven gimp org>
* plug-ins/file-ico/ico-save.c: applied patch from Aurimas JuÅka
that fixes an endianness issue (bug #529629).
Modified:
trunk/ChangeLog
trunk/plug-ins/file-ico/ico-save.c
Modified: trunk/plug-ins/file-ico/ico-save.c
==============================================================================
--- trunk/plug-ins/file-ico/ico-save.c (original)
+++ trunk/plug-ins/file-ico/ico-save.c Fri Aug 15 17:50:15 2008
@@ -1082,6 +1082,14 @@
entries[i].size = ftell (fp) - entries[i].offset;
}
+ for (i = 0; i < info.num_icons; i++)
+ {
+ entries[i].planes = GUINT16_TO_LE (entries[i].planes);
+ entries[i].bpp = GUINT16_TO_LE (entries[i].bpp);
+ entries[i].size = GUINT32_TO_LE (entries[i].size);
+ entries[i].offset = GUINT32_TO_LE (entries[i].offset);
+ }
+
if (fseek (fp, sizeof(IcoFileHeader), SEEK_SET) < 0
|| fwrite (entries, sizeof (IcoFileEntry), info.num_icons, fp) <= 0)
{
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]