[grilo] core: Do not free plugin descriptors in GrlMediaPlugin's finalize function, they are const members t
- From: Iago Toral Quiroga <itoral src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [grilo] core: Do not free plugin descriptors in GrlMediaPlugin's finalize function, they are const members t
- Date: Fri, 3 Sep 2010 09:28:11 +0000 (UTC)
commit 92de127e655d6c31dbc64c3e5a389b8bc6de12c8
Author: Iago Toral Quiroga <itoral igalia com>
Date: Fri Sep 3 10:34:17 2010 +0200
core: Do not free plugin descriptors in GrlMediaPlugin's finalize function,
they are const members to be freed by the registry only when plugins are
unloaded, they should not be freed when a source spawned by the plugin is
unloaded.
src/grl-media-plugin.c | 7 ++-----
1 files changed, 2 insertions(+), 5 deletions(-)
---
diff --git a/src/grl-media-plugin.c b/src/grl-media-plugin.c
index 71fbe06..30cad89 100644
--- a/src/grl-media-plugin.c
+++ b/src/grl-media-plugin.c
@@ -81,11 +81,8 @@ grl_media_plugin_finalize (GObject *object)
{
GrlMediaPlugin *plugin = GRL_MEDIA_PLUGIN (object);
- if (plugin->priv->info->optional_info) {
- g_hash_table_destroy (plugin->priv->info->optional_info);
- }
-
- g_free (plugin->priv->info->filename);
+ /* Do not free priv->info here, for that is a "const" member
+ Plugin specs are freed by the registry when plugins are unloaded */
G_OBJECT_CLASS (grl_media_plugin_parent_class)->finalize (object);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]