[libgdata] [media] Fixed a crasher when trying to free static memory



commit 20cad32f52be0505a25305bad7d6167df6ad8de6
Author: Philip Withnall <philip tecnocode co uk>
Date:   Sun Jun 28 22:31:44 2009 +0100

    [media] Fixed a crasher when trying to free static memory
    
    Static memory was being inserted into a hash table, then later freed.
    Also updated the list of allowed commit tags in HACKING.

 gdata/media/gdata-media-group.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/gdata/media/gdata-media-group.c b/gdata/media/gdata-media-group.c
index 0b44341..0bf49f5 100644
--- a/gdata/media/gdata-media-group.c
+++ b/gdata/media/gdata-media-group.c
@@ -235,7 +235,7 @@ parse_xml (GDataParsable *parsable, xmlDoc *doc, xmlNode *node, gpointer user_da
 		xmlFree (countries);
 
 		/* Add "all" to the table, since it's an exception table */
-		g_hash_table_insert (self->priv->restricted_countries, (gchar*) "all", GUINT_TO_POINTER (!relationship_bool));
+		g_hash_table_insert (self->priv->restricted_countries, g_strdup ("all"), GUINT_TO_POINTER (!relationship_bool));
 
 		/* Add all the listed countries to the restricted countries table */
 		for (country = country_list; *country != NULL; country++)



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]