[glib] GDBusConnection: Make interface lookups O(1)
- From: David Zeuthen <davidz src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [glib] GDBusConnection: Make interface lookups O(1)
- Date: Mon, 28 Mar 2011 15:39:41 +0000 (UTC)
commit 91f97ebbaad602115b3b26e36592a3b3a22cf9e6
Author: David Zeuthen <davidz redhat com>
Date: Mon Mar 28 11:33:36 2011 -0400
GDBusConnection: Make interface lookups O(1)
Signed-off-by: David Zeuthen <davidz redhat com>
gio/gdbusconnection.c | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
---
diff --git a/gio/gdbusconnection.c b/gio/gdbusconnection.c
index 44d5446..4227bda 100644
--- a/gio/gdbusconnection.c
+++ b/gio/gdbusconnection.c
@@ -3662,6 +3662,7 @@ typedef struct
static void
exported_interface_free (ExportedInterface *ei)
{
+ g_dbus_interface_info_cache_release (ei->interface_info);
g_dbus_interface_info_unref ((GDBusInterfaceInfo *) ei->interface_info);
call_destroy_notify (ei->context,
@@ -4731,6 +4732,7 @@ g_dbus_connection_register_object (GDBusConnection *connection,
ei->user_data_free_func = user_data_free_func;
ei->vtable = _g_dbus_interface_vtable_copy (vtable);
ei->interface_info = g_dbus_interface_info_ref (interface_info);
+ g_dbus_interface_info_cache_build (ei->interface_info);
ei->interface_name = g_strdup (interface_info->name);
ei->context = g_main_context_get_thread_default ();
if (ei->context != NULL)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]