From 64f3d8f67db09e0c84ed3ff009b86d0127fe82b4 Mon Sep 17 00:00:00 2001 From: Havoc Pennington Date: Sun, 24 Apr 2005 14:04:16 +0000 Subject: 2005-04-23 Havoc Pennington * dbus/dbus-message.c (dbus_message_append_args): fix doc comment, reported by Tony Houghton * test/test-service.c (main): test dbus_connection_get_object_path_data() * dbus/dbus-object-tree.c (find_handler): be sure we always init the exact_match (_dbus_object_tree_get_user_data_unlocked): new function used by dbus_connection_get_object_path_data() (do_register): add assertion test for get_user_data_unlocked (object_tree_test_iteration): more tests * dbus/dbus-connection.c (dbus_connection_get_object_path_data): new function from Dan Reed to let you get the user data from dbus_connection_register_object_path() --- test/test-service.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'test/test-service.c') diff --git a/test/test-service.c b/test/test-service.c index 9316b626..040a0300 100644 --- a/test/test-service.c +++ b/test/test-service.c @@ -188,9 +188,17 @@ main (int argc, if (!dbus_connection_register_object_path (connection, echo_path, &echo_vtable, - NULL)) + (void*) 0xdeadbeef)) die ("No memory"); + { + void *d; + if (!dbus_connection_get_object_path_data (connection, echo_path, &d)) + die ("No memory"); + if (d != (void*) 0xdeadbeef) + die ("dbus_connection_get_object_path_data() doesn't seem to work right\n"); + } + result = dbus_bus_request_name (connection, "org.freedesktop.DBus.TestSuiteEchoService", 0, &error); if (dbus_error_is_set (&error)) -- cgit