summaryrefslogtreecommitdiff
path: root/debian/dbus.postinst
diff options
context:
space:
mode:
authorLoic Minier <lool@dooz.org>2008-02-18 16:10:11 +0000
committerLoic Minier <lool@dooz.org>2008-02-18 16:10:11 +0000
commit75fe415843ad6ce187bf2c61b9fdf94f6bd54b40 (patch)
tree132217aca4296c1a5ac4704f6310eec66bee7a04 /debian/dbus.postinst
parent4f2b8479f5b02c04ce3153c27c3fda8cfdbbfeb8 (diff)
downloaddbus-75fe415843ad6ce187bf2c61b9fdf94f6bd54b40.tar.gz
Simplify dbus.postinst.
git-svn-id: svn+ssh://svn.debian.org/svn/pkg-utopia/packages/unstable/dbus@2083 ceb527fc-18e6-0310-9fe2-813c157c29e7
Diffstat (limited to 'debian/dbus.postinst')
-rw-r--r--debian/dbus.postinst38
1 files changed, 14 insertions, 24 deletions
diff --git a/debian/dbus.postinst b/debian/dbus.postinst
index 095e64fb..5368bbf0 100644
--- a/debian/dbus.postinst
+++ b/debian/dbus.postinst
@@ -8,30 +8,20 @@ MESSAGEUSER=messagebus
MESSAGEHOME=/var/run/dbus
LAUNCHER=/usr/lib/dbus-1.0/dbus-daemon-launch-helper
-case "$1" in
- configure)
- adduser --system \
- --home "$MESSAGEHOME" \
- --no-create-home \
- --disabled-password \
- --group "$MESSAGEUSER"
-
- chown "$MESSAGEUSER":"$MESSAGEUSER" "$MESSAGEHOME"
-
- if ! dpkg-statoverride --list "$LAUNCHER" > /dev/null 2>&1; then
- chown root:"$MESSAGEUSER" "$LAUNCHER"
- chmod 4754 "$LAUNCHER"
- fi
- ;;
-
- abort-upgrade|abort-remove|abort-deconfigure)
- ;;
-
- *)
- echo "postinst called with unknown argument \`$1'" >&2
- exit 1
- ;;
-esac
+if [ "$1" = configure ]; then
+ adduser --system \
+ --home "$MESSAGEHOME" \
+ --no-create-home \
+ --disabled-password \
+ --group "$MESSAGEUSER"
+
+ chown "$MESSAGEUSER":"$MESSAGEUSER" "$MESSAGEHOME"
+
+ if ! dpkg-statoverride --list "$LAUNCHER" >/dev/null 2>&1; then
+ chown root:"$MESSAGEUSER" "$LAUNCHER"
+ chmod 4754 "$LAUNCHER"
+ fi
+fi
# fix rc symlink priorities for upgrades from older versions
if [ "$1" = configure ] && dpkg --compare-versions "$2" lt-nl 1.1.4-1; then