Skip to contentSkip to conversation

avahi: don't call DBus init script directly

PATCH New Ross Burton 1 participant 2 messages Apr 16, 2013

lore
Share & tools
lore
#0 lore raw

PATCH 1/2 avahi: don't call DBus init script directly

After installing Avahi we need DBus to reload it's configuration. In a pure-systemd image there isn't a DBus init script to reload, so cut out the middleman and just sent SIGHUP to all running dbus-daemon processes instead.

---
 meta/recipes-connectivity/avahi/avahi.inc |    6 +-----
 1 file changed, 1 insertion(+), 5 deletions(-)
meta/recipes-connectivity/avahi/avahi.inc +1 -5
index d8d9a9d..c302f87 100644
@@ -136,11 +136,7 @@ do_install() {
 
 pkg_postinst_avahi-daemon () {
 if [ -z "$D" ]; then
-	DBUSPID=`pidof dbus-daemon`
-
-	if [ "x$DBUSPID" != "x" ]; then
-		/etc/init.d/dbus-1 force-reload
-	fi
+	killall -q -HUP dbus-daemon || true
 fi
 }
 
Signature · 1 line
1.7.10.4
#1 lore raw

PATCH 2/2 wpa-supplicant: don't call DBus init script directly

After installing Avahi we need DBus to reload it's configuration. In a pure-systemd image there isn't a DBus init script to reload, so cut out the middleman and just sent SIGHUP to all running dbus-daemon processes instead.

---
 meta/recipes-connectivity/wpa-supplicant/wpa-supplicant-2.0.inc |    6 +-----
 1 file changed, 1 insertion(+), 5 deletions(-)
meta/recipes-connectivity/wpa-supplicant/wpa-supplicant-2.0.inc +1 -5
index dd85057..e5f7881 100644
@@ -84,9 +84,5 @@ pkg_postinst_wpa-supplicant () {
 		exit 0
 	fi
 
-	DBUSPID=`pidof dbus-daemon`
-
-	if [ "x$DBUSPID" != "x" ]; then
-		/etc/init.d/dbus-1 reload || true
-	fi
+	killall -q -HUP dbus-daemon || true
 }
Signature · 1 line
1.7.10.4