Bug 63163

Summary: test/internals/syslog.c fails when using systemd as pid 1
Product: dbus Reporter: Simon McVittie <smcv>
Component: coreAssignee: Havoc Pennington <hp>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: medium CC: walters
Version: unspecified   
Hardware: Other   
OS: All   
Whiteboard:
i915 platform: i915 features:
Attachments: Do not suppress syslog test's stderr just because init is systemd

Description Simon McVittie 2013-04-05 12:27:04 UTC
test/internals/syslog.c asserts that we log stuff to stderr.

For Bug #61399, we turned off logging to stderr when under systemd, because systemd collects both stderr and syslog. This makes the test fail if pid 1 is systemd.

I think the solution is to assume that systemd will capture dbus-daemon's stderr, but nobody else's.

(Regression since 1.7.0.)
Comment 1 Simon McVittie 2013-04-05 12:29:32 UTC
Created attachment 77473 [details] [review]
Do not suppress syslog test's stderr just because init is  systemd

This causes the test to fail. The assumption implicitly being made was
"if pid 1 is systemd, then every caller of _dbus_init_system_log() is a
systemd service" which is not valid for the regression test.
Comment 2 Colin Walters 2013-04-05 18:49:20 UTC
Comment on attachment 77473 [details] [review]
Do not suppress syslog test's stderr just because init is  systemd

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

This looks OK to me.  The syslog test seems kind of odd, but anyways, sorry about not running it.
Comment 3 Simon McVittie 2013-04-19 11:32:05 UTC
Fixed in git for 1.7.2

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.