diff options
author | Simon McVittie <simon.mcvittie@collabora.co.uk> | 2015-03-12 14:29:38 +0000 |
---|---|---|
committer | Simon McVittie <simon.mcvittie@collabora.co.uk> | 2015-04-17 14:23:28 +0100 |
commit | 41e55057decfe02ed66a388ab2c180ac06c7d51f (patch) | |
tree | b941697f30a61127874f65db976a5e047abfb923 | |
parent | 04b8ea5a43c2471615965848bf60383626307a18 (diff) |
bus_unix_fds_passing_test: the results of _dbus_socketpair are sockets
-rw-r--r-- | bus/dispatch.c | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/bus/dispatch.c b/bus/dispatch.c index feeaec5e..10b3acf1 100644 --- a/bus/dispatch.c +++ b/bus/dispatch.c @@ -5018,7 +5018,8 @@ bus_unix_fds_passing_test(const DBusString *test_data_dir) DBusConnection *foo, *bar; DBusError error; DBusMessage *m; - int one[2], two[2], x, y, z; + DBusSocket one[2], two[2]; + int x, y, z; char r; dbus_error_init (&error); @@ -5073,9 +5074,9 @@ bus_unix_fds_passing_test(const DBusString *test_data_dir) DBUS_TYPE_INVALID)) _dbus_assert_not_reached("Failed to attach fds."); - if (!_dbus_close(one[0], &error)) + if (!_dbus_close_socket (one[0], &error)) _dbus_assert_not_reached("Failed to close pipe #1 "); - if (!_dbus_close(two[0], &error)) + if (!_dbus_close_socket (two[0], &error)) _dbus_assert_not_reached("Failed to close pipe #2 "); if (!(dbus_connection_can_send_type(foo, DBUS_TYPE_UNIX_FD))) @@ -5142,9 +5143,9 @@ bus_unix_fds_passing_test(const DBusString *test_data_dir) if (read(two[1], &r, 1) != 1 || r != 'Z') _dbus_assert_not_reached("Failed to read value from pipe."); - if (!_dbus_close(one[1], &error)) + if (!_dbus_close_socket (one[1], &error)) _dbus_assert_not_reached("Failed to close pipe #1 "); - if (!_dbus_close(two[1], &error)) + if (!_dbus_close_socket (two[1], &error)) _dbus_assert_not_reached("Failed to close pipe #2 "); _dbus_verbose ("Disconnecting foo\n"); |