commit 45b2cc8d68add94dc2c0ff336c8d3c014c333fe8
Author: Christophe Fergeau <t...@gnome.org>
Date:   Mon Sep 20 15:10:58 2010 +0200

    Don't try to destroy NULL GHashTable
    
    FImport::pcounts2 is only non-NULL on iOS devices where some
    songs have been played since last sync. Make sure we don't try to
    free it if it wasn't created or we get a warning from glib.

 src/itdb_itunesdb.c |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)
---
diff --git a/src/itdb_itunesdb.c b/src/itdb_itunesdb.c
index 0a81ffb..36a3e95 100644
--- a/src/itdb_itunesdb.c
+++ b/src/itdb_itunesdb.c
@@ -1308,7 +1308,9 @@ static void itdb_free_fimp (FImport *fimp)
        g_list_free (fimp->pos_glist);
        g_list_free (fimp->tracks);
        playcounts_free (fimp);
-       g_hash_table_destroy (fimp->pcounts2);
+       if (fimp->pcounts2 != NULL) {
+           g_hash_table_destroy (fimp->pcounts2);
+       }
        g_free (fimp);
     }
 }

------------------------------------------------------------------------------
Start uncovering the many advantages of virtual appliances
and start using them to simplify application deployment and
accelerate your shift to cloud computing.
http://p.sf.net/sfu/novell-sfdev2dev
_______________________________________________
gtkpod-cvs2 mailing list
gtkpod-cvs2@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gtkpod-cvs2

Reply via email to