Factor out some utility functions from test/dbus-daemon*
authorSimon McVittie <simon.mcvittie@collabora.co.uk>
Mon, 26 Jan 2015 19:02:59 +0000 (19:02 +0000)
committerSimon McVittie <simon.mcvittie@collabora.co.uk>
Tue, 3 Feb 2015 16:18:57 +0000 (16:18 +0000)
commit8b238f3f0dee18395769f9f009e98623cdce951c
treef861c1f94242d8c8f9ef81ee8373479f42e7eb50
parent6976a7f1997472e06bf83b0a8828f335a1c65c4a
Factor out some utility functions from test/dbus-daemon*

In the process, make test_kill_pid() safer: do not try to terminate
more than one pid, or the NULL handle.

Also stop leaking the address_fd in spawn_dbus_daemon, a pre-existing
bug that was spotted by Philip Withnall during review.

Bug: https://bugs.freedesktop.org/show_bug.cgi?id=88810
Reviewed-by: Philip Withnall
test/Makefile.am
test/dbus-daemon-eavesdrop.c
test/dbus-daemon.c
test/test-utils-glib.c [new file with mode: 0644]
test/test-utils-glib.h [new file with mode: 0644]
test/test-utils.c
test/test-utils.h