totem r5054 - in trunk: . src/plugins



Author: pwithnall
Date: Thu Jan 31 18:05:27 2008
New Revision: 5054
URL: http://svn.gnome.org/viewvc/totem?rev=5054&view=rev

Log:
2008-01-31  Philip Withnall  <pwithnall svn gnome org>

	* src/plugins/totem-python-module.c:
	(totem_python_module_finalize): Protect finalisation
	of plugins which haven't loaded properly. (Closes: #513467)



Modified:
   trunk/ChangeLog
   trunk/src/plugins/totem-python-module.c

Modified: trunk/src/plugins/totem-python-module.c
==============================================================================
--- trunk/src/plugins/totem-python-module.c	(original)
+++ trunk/src/plugins/totem-python-module.c	Thu Jan 31 18:05:27 2008
@@ -367,10 +367,13 @@
 totem_python_module_finalize (GObject *object)
 {
 	TotemPythonModulePrivate *priv = TOTEM_PYTHON_MODULE_GET_PRIVATE (object);
-	g_debug ("Finalizing Python module %s", g_type_name (priv->type));
 
-	g_free (priv->module);
-	g_free (priv->path);
+	if (priv && priv->type) {
+		g_debug ("Finalizing Python module %s", g_type_name (priv->type));
+
+		g_free (priv->module);
+		g_free (priv->path);
+	}
 
 	G_OBJECT_CLASS (totem_python_module_parent_class)->finalize (object);
 }



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