Bug 48600 - dbus-tube-chan test assumes abstract sockets are supported
Summary: dbus-tube-chan test assumes abstract sockets are supported
Status: RESOLVED FIXED
Alias: None
Product: Telepathy
Classification: Unclassified
Component: tp-glib (show other bugs)
Version: git master
Hardware: Other All
: medium normal
Assignee: Simon McVittie
QA Contact: Telepathy bugs list
URL:
Whiteboard:
Keywords: patch
Depends on:
Blocks:
 
Reported: 2012-04-12 04:59 UTC by Simon McVittie
Modified: 2012-04-12 08:07 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments
dbus-tube-chan test: listen on a random address appropriate for the OS (1.79 KB, patch)
2012-04-12 06:02 UTC, Simon McVittie
Details | Splinter Review

Description Simon McVittie 2012-04-12 04:59:29 UTC
dbus-tube-chan.c assumes that abstract sockets are supported, which isn't true on most non-Linux platforms. For instance, see this log from Debian:

https://buildd.debian.org/status/fetch.php?pkg=telepathy-glib&arch=kfreebsd-i386&ver=0.18.0-1&stamp=1333416042
Comment 1 Simon McVittie 2012-04-12 06:02:20 UTC
Created attachment 59857 [details] [review]
dbus-tube-chan test: listen on a random address appropriate  for the OS

Instead of hard-coding the abstract Unix socket '\000dbus-tube-test',
listen on a random (abstract or real) Unix socket in /tmp if on Unix,
or a random port on 127.0.0.1 if not. These are the same listening
addresses I used in test/loopback.c in libdbus. The Unix version also
matches what the session bus normally uses.

This fixes the test on non-Linux Unix (not insisting on
abstract-namespace sockets working), when run twice in parallel on Linux
(not insisting on using a particular hard-coded name), and in theory
also on Windows (not trying to use Unix sockets).
Comment 2 Guillaume Desmottes 2012-04-12 06:48:50 UTC
Comment on attachment 59857 [details] [review]
dbus-tube-chan test: listen on a random address appropriate  for the OS

Review of attachment 59857 [details] [review]:
-----------------------------------------------------------------

++
Comment 3 Simon McVittie 2012-04-12 08:07:32 UTC
Thanks, fixed in git for 0.18.1, 0.19.0


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.