[maemo-commits] [maemo-commits] r15183 - projects/connectivity/bluez-utils-debian/trunk
From: subversion at stage.maemo.org subversion at stage.maemo.orgDate: Mon Feb 18 10:31:43 EET 2008
- Previous message: [maemo-commits] r15182 - projects/haf/tags/hail
- Next message: [maemo-commits] r15184 - projects/connectivity/bluez-utils-debian/trunk
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Author: jh
Date: 2008-02-18 10:31:41 +0200 (Mon, 18 Feb 2008)
New Revision: 15183
Modified:
projects/connectivity/bluez-utils-debian/trunk/bluez-utils.init
projects/connectivity/bluez-utils-debian/trunk/changelog
Log:
Fix issues with dbus-send commands
Modified: projects/connectivity/bluez-utils-debian/trunk/bluez-utils.init
===================================================================
--- projects/connectivity/bluez-utils-debian/trunk/bluez-utils.init 2008-02-14 07:54:51 UTC (rev 15182)
+++ projects/connectivity/bluez-utils-debian/trunk/bluez-utils.init 2008-02-18 08:31:41 UTC (rev 15183)
@@ -22,19 +22,23 @@
case "$1" in
start)
if [ -e /tmp/first-boot-flag-tmp ]; then
- if [ -f "/etc/bluetooth/audio.service" ] && [ -x "/usr/bin/osso-product-info" ]; then
+ if [ -x "/usr/bin/osso-product-info" ]; then
HW=`osso-product-info -qOSSO_PRODUCT_HARDWARE`
- AUDIO_PATH=`dbus-send --system --dest=org.bluez --print-reply /org/bluez org.bluez.Manager.FindService string:audio 2> /dev/null|tail -n 1|awk '{ print $2; }'|sed -e 's/"//g'`
+ else
+ HW="unknown"
+ fi
- # Disable automatic audio service startup on RX-48 HW
- if [ "$AUDIO_PATH" ] && [ "$HW" = "RX-48" ]; then
- sed -i -e 's/^Autostart=true/Autostart=false/' /etc/bluetooth/audio.service
- dbus-send --dest=org.bluez --system --print-reply $AUDIO_PATH org.bluez.Service.Stop 2> /dev/null
+ if [ "$HW" = "RX-48" ]; then
+ if [ -f "/etc/bluetooth/audio.service" ]; then
+ AUDIO_PATH=`(dbus-send --system --dest=org.bluez --print-reply /org/bluez org.bluez.Manager.FindService string:audio 2> /dev/null || true) |tail -n 1|awk '{ print $2; }'|sed -e 's/"//g'`
+
+ if [ "$AUDIO_PATH" ]; then
+ sed -i -e 's/^Autostart=true/Autostart=false/' /etc/bluetooth/audio.service
+ dbus-send --dest=org.bluez --print-reply --system --print-reply $AUDIO_PATH org.bluez.Service.Stop > /dev/null || true
+ fi
fi
- if [ "$HW" = "RX-48" ]; then
- dbus-send --dest=org.bluez --system /org/bluez/hci0 org.bluez.Adapter.SetMode string:off 2> /dev/null
- fi
+ dbus-send --dest=org.bluez --print-reply --system /org/bluez/hci0 org.bluez.Adapter.SetMode string:off > /dev/null || true
fi
else
echo -n "Starting $DESC:"
Modified: projects/connectivity/bluez-utils-debian/trunk/changelog
===================================================================
--- projects/connectivity/bluez-utils-debian/trunk/changelog 2008-02-14 07:54:51 UTC (rev 15182)
+++ projects/connectivity/bluez-utils-debian/trunk/changelog 2008-02-18 08:31:41 UTC (rev 15183)
@@ -1,3 +1,9 @@
+bluez-utils (3.25-0osso4) unstable; urgency=low
+
+ * Improve init script dbus-send commands and logic. Fixes: NB#80148
+
+ -- Johan Hedberg <johan.hedberg at nokia.com> Thu, 7 Feb 2008 12:28:05 +0000
+
bluez-utils (3.25-0osso3) unstable; urgency=low
* Call SetMode("off") during first boot on RX-48 HW. Fixes: NB#80148
- Previous message: [maemo-commits] r15182 - projects/haf/tags/hail
- Next message: [maemo-commits] r15184 - projects/connectivity/bluez-utils-debian/trunk
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
