summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSjoerd Simons <sjoerd@luon.net>2014-08-12 09:22:23 +0200
committerSjoerd Simons <sjoerd@luon.net>2014-08-13 22:26:52 +0200
commit39bc94ef0eefedaf8928614289abd9d273843320 (patch)
tree598183c9a1da810cce4d86816092d88f8c72bfe8
parentbba4c89432d5ab8829add7a81f44f8f633bbaed5 (diff)
downloaddbus-39bc94ef0eefedaf8928614289abd9d273843320.tar.gz
debian/dbus.posinst: When triggered only poke the dbus-daemon, don't run update-rc.d/invoke-rc.d as added by dh_installinit. This prevent some odd-corner when being triggered during init system upgrade (Closes: #754404)
-rw-r--r--debian/changelog9
-rw-r--r--debian/dbus.postinst30
2 files changed, 29 insertions, 10 deletions
diff --git a/debian/changelog b/debian/changelog
index 751b4ef7..c76819ff 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,12 @@
+dbus (1.8.6-2) UNRELEASED; urgency=medium
+
+ * debian/dbus.posinst: When triggered only poke the dbus-daemon, don't run
+ update-rc.d/invoke-rc.d as added by dh_installinit. This prevent some
+ odd-corner when being triggered during init system upgrade
+ (Closes: #754404)
+
+
+ -- Sjoerd Simons <sjoerd@debian.org> Tue, 12 Aug 2014 09:06:21 +0200
dbus (1.8.6-1) unstable; urgency=high
* New upstream release
diff --git a/debian/dbus.postinst b/debian/dbus.postinst
index 0c71bbbb..a93f8551 100644
--- a/debian/dbus.postinst
+++ b/debian/dbus.postinst
@@ -8,6 +8,25 @@ MESSAGEUSER=messagebus
MESSAGEHOME=/var/run/dbus
LAUNCHER=/usr/lib/dbus-1.0/dbus-daemon-launch-helper
+# This is what the init script would do, but it's simpler (and less
+# dependent on sysvinit vs. Upstart vs. etc.) if we do it directly. It is not
+# conditional on "$1" because it's also the right thing to do for the
+# /etc/dbus-1/system.d and /usr/share/dbus-1/system-services triggers.
+#
+# If it's not running (perhaps we're in a chroot) this will just fail
+# harmlessly, so there's no need to condition on status.
+reload_dbus_config() {
+ dbus-send --print-reply --system --type=method_call \
+ --dest=org.freedesktop.DBus \
+ / org.freedesktop.DBus.ReloadConfig > /dev/null || true
+}
+
+
+if [ "$1" = triggered ]; then
+ reload_dbus_config
+ exit 0
+fi
+
if [ "$1" = configure ]; then
adduser --system \
--quiet \
@@ -45,15 +64,6 @@ if [ "$1" = configure ] && [ -n "$2" ]; then
fi
fi
-# This is what the init script would do, but it's simpler (and less
-# dependent on sysvinit vs. Upstart vs. etc.) if we do it directly. It is not
-# conditional on "$1" because it's also the right thing to do for the
-# /etc/dbus-1/system.d and /usr/share/dbus-1/system-services triggers.
-#
-# If it's not running (perhaps we're in a chroot) this will just fail
-# harmlessly, so there's no need to condition on status.
-dbus-send --print-reply --system --type=method_call \
- --dest=org.freedesktop.DBus \
- / org.freedesktop.DBus.ReloadConfig > /dev/null || true
+reload_dbus_config
#DEBHELPER#