summaryrefslogtreecommitdiff
path: root/test/relay.c
diff options
context:
space:
mode:
authorSimon McVittie <smcv@debian.org>2011-09-21 15:31:36 +0100
committerSimon McVittie <smcv@debian.org>2011-09-21 15:31:36 +0100
commit5c56c903340521d9ad6fec85786b3666b8e30b37 (patch)
tree3fd32e0cfa736c4e8ca1ef225b91235c02c24779 /test/relay.c
parent201e26f277511adf0fbb67aa39d335f281c6085f (diff)
downloaddbus-5c56c903340521d9ad6fec85786b3666b8e30b37.tar.gz
Imported Upstream version 1.4.16upstream/1.4.16
Diffstat (limited to 'test/relay.c')
-rw-r--r--test/relay.c12
1 files changed, 8 insertions, 4 deletions
diff --git a/test/relay.c b/test/relay.c
index bad39f47..f4129d0a 100644
--- a/test/relay.c
+++ b/test/relay.c
@@ -137,12 +137,15 @@ test_connect (Fixture *f,
gconstpointer data G_GNUC_UNUSED)
{
dbus_bool_t have_mem;
+ char *address;
g_assert (f->left_server_conn == NULL);
g_assert (f->right_server_conn == NULL);
- f->left_client_conn = dbus_connection_open_private (
- dbus_server_get_address (f->server), &f->e);
+ address = dbus_server_get_address (f->server);
+ g_assert (address != NULL);
+
+ f->left_client_conn = dbus_connection_open_private (address, &f->e);
assert_no_error (&f->e);
g_assert (f->left_client_conn != NULL);
dbus_connection_setup_with_g_main (f->left_client_conn, NULL);
@@ -153,12 +156,13 @@ test_connect (Fixture *f,
g_main_context_iteration (NULL, TRUE);
}
- f->right_client_conn = dbus_connection_open_private (
- dbus_server_get_address (f->server), &f->e);
+ f->right_client_conn = dbus_connection_open_private (address, &f->e);
assert_no_error (&f->e);
g_assert (f->right_client_conn != NULL);
dbus_connection_setup_with_g_main (f->right_client_conn, NULL);
+ dbus_free (address);
+
while (f->right_server_conn == NULL)
{
g_print (".");