[maemo-commits] [maemo-commits] r15020 - in projects/haf/trunk/hildon-thumbnail: . thumbs

From: subversion at stage.maemo.org subversion at stage.maemo.org
Date: Wed Jan 9 12:27:20 EET 2008
Author: marivoll
Date: 2008-01-09 12:27:19 +0200 (Wed, 09 Jan 2008)
New Revision: 15020

Modified:
   projects/haf/trunk/hildon-thumbnail/ChangeLog
   projects/haf/trunk/hildon-thumbnail/thumbs/hildon-thumbnail-factory.c
Log:
	* thumbs/hildon-thumbnail-factory.c (register_pixbuf_formats):
	Duplicate pixbuf_cmd before storing it away and free the original
	at the end.  This gets the memory handling right when there is
	more than one mime_type (M2083).  Thanks to Jiri Benc!


Modified: projects/haf/trunk/hildon-thumbnail/ChangeLog
===================================================================
--- projects/haf/trunk/hildon-thumbnail/ChangeLog	2008-01-09 10:07:30 UTC (rev 15019)
+++ projects/haf/trunk/hildon-thumbnail/ChangeLog	2008-01-09 10:27:19 UTC (rev 15020)
@@ -1,3 +1,10 @@
+2007-10-09  Marius Vollmer  <marius.vollmer at nokia.com>
+
+	* thumbs/hildon-thumbnail-factory.c (register_pixbuf_formats):
+	Duplicate pixbuf_cmd before storing it away and free the original
+	at the end.  This gets the memory handling right when there is
+	more than one mime_type (M2083).  Thanks to Jiri Benc!
+
 2007-08-30  Marius Vollmer  <marius.vollmer at nokia.com>
 
 	Released 0.14

Modified: projects/haf/trunk/hildon-thumbnail/thumbs/hildon-thumbnail-factory.c
===================================================================
--- projects/haf/trunk/hildon-thumbnail/thumbs/hildon-thumbnail-factory.c	2008-01-09 10:07:30 UTC (rev 15019)
+++ projects/haf/trunk/hildon-thumbnail/thumbs/hildon-thumbnail-factory.c	2008-01-09 10:27:19 UTC (rev 15020)
@@ -624,7 +624,7 @@
         mime_types = mime_type = gdk_pixbuf_format_get_mime_types(format->data);
 
         while(*mime_type != NULL) {
-            add_mime_handler(*mime_type, pixbuf_cmd);
+	    add_mime_handler(*mime_type, g_strdup (pixbuf_cmd));
 
             mime_type++;
         }
@@ -634,6 +634,7 @@
         format = format->next;
     }
 
+    g_free (pixbuf_cmd);
     g_slist_free(formats);
 }
 


More information about the maemo-commits mailing list