~jamesodhunt/upstart/bug-1235649

Viewing all changes in revision 1547.

  • Committer: James Hunt
  • Date: 2013-10-25 13:49:49 UTC
  • Revision ID: james.hunt@ubuntu.com-20131025134949-gfwgrtgd3r9b7gb8
* dbus/com.ubuntu.Upstart.xml: Added 'NotifyDBusAddress' method.
* init/control.c:
  - control_bus_open(): Connect to the D-Bus bus specified
    by control_bus_address when running as a Session Init (LP: #1203595, #1235649).
  - control_disconnected(): Display calculated bus type rather than hard-coding.
  - control_handle_bus_type(): Removed.
  - control_get_bus_type(): Determine type of D-Bus bus that will be used.
  - control_notify_dbus_address(): Implementation of D-Bus 'NotifyDBusAddress' method
    that sets control_bus_address.
* init/main.c:
  - main():
    - Just check USE_SESSION_BUS_ENV variable rather than calling
      control_handle_bus_type().
    - Don't register SIGUSR1 handler for Session Init.
  - usr1_handler(): Display calculated bus type rather than hard-coding.
* init/test_control.c: Updated strings used by tests which check error
  messages to include 'D-Bus'.
* util/initctl.c: Added new 'notify-dbus-address' command.
* util/man/initctl.8:
  - Documentation for new 'notify-dbus-address' command.
  - reset-env: Troff fix.
  - Explain '--user' implicit in user mode.
* util/tests/test_initctl.c: test_dbus_connection(): New function providing
  the following new tests:
  - "ensure non-priv non-Session Init connects to D-Bus session bus on startup".
  - "ensure Session Init does not connect to D-Bus session bus on startup".
  - "ensure Session Init connects to D-Bus session bus when notified".
  - "ensure Session Init does not connect to another bus when notified twice".

expand all expand all

Show diffs side-by-side

added added

removed removed

Lines of Context: