From f36fce8e4a7afc67edbbfa06b0f0661198d209f6 Mon Sep 17 00:00:00 2001 From: Matthias Clasen Date: Thu, 4 Feb 2010 23:13:37 -0500 Subject: [PATCH 09/22] Add a hash table for inhibitors --- src/ck-manager.c | 6 ++++++ 1 files changed, 6 insertions(+), 0 deletions(-) diff --git a/src/ck-manager.c b/src/ck-manager.c index a24cabf..8002c67 100644 --- a/src/ck-manager.c +++ b/src/ck-manager.c @@ -73,6 +73,7 @@ struct CkManagerPrivate GHashTable *seats; GHashTable *sessions; GHashTable *leaders; + GHashTable *inhibitors; DBusGProxy *bus_proxy; DBusGConnection *connection; @@ -2552,6 +2553,10 @@ ck_manager_init (CkManager *manager) g_str_equal, g_free, (GDestroyNotify) g_object_unref); + manager->priv->inhibitors = g_hash_table_new_full (g_direct_hash, + g_direct_equal, + NULL, + (GDestroyNotify) g_object_unref); manager->priv->logger = ck_event_logger_new (LOG_FILE); @@ -2604,6 +2609,7 @@ ck_manager_finalize (GObject *object) g_hash_table_destroy (manager->priv->seats); g_hash_table_destroy (manager->priv->sessions); g_hash_table_destroy (manager->priv->leaders); + g_hash_table_destroy (manager->priv->inhibitors); if (manager->priv->bus_proxy != NULL) { g_object_unref (manager->priv->bus_proxy); } -- 1.6.6