aboutsummaryrefslogtreecommitdiff
path: root/system/nss-pam-ldapd/doinst.sh
diff options
context:
space:
mode:
authorChristopher Walker <kris240376@gmail.com>2013-04-23 20:48:16 -0400
committerNiels Horn <niels.horn@slackbuilds.org>2013-04-28 12:29:46 -0300
commit58e49dda851dc33d215b7a822493bd43f789b82f (patch)
treed6da577a7fcd36b4fd04ff83856a0880767b4635 /system/nss-pam-ldapd/doinst.sh
parent0a5abead0fcf0def1a230f4ae5ed323de1eac020 (diff)
system/nss-pam-ldapd: Updated for version 0.8.12.
Signed-off-by: dsomero <xgizzmo@slackbuilds.org>
Diffstat (limited to 'system/nss-pam-ldapd/doinst.sh')
-rw-r--r--system/nss-pam-ldapd/doinst.sh14
1 files changed, 13 insertions, 1 deletions
diff --git a/system/nss-pam-ldapd/doinst.sh b/system/nss-pam-ldapd/doinst.sh
index 8dc76499867f8..d483abce26a14 100644
--- a/system/nss-pam-ldapd/doinst.sh
+++ b/system/nss-pam-ldapd/doinst.sh
@@ -10,5 +10,17 @@ config() {
fi
# Otherwise, we leave the .new copy for the admin to consider...
}
+
+preserve_perms() {
+ NEW="$1"
+ OLD="$(dirname $NEW)/$(basename $NEW .new)"
+ if [ -e $OLD ]; then
+ cp -a $OLD ${NEW}.incoming
+ cat $NEW > ${NEW}.incoming
+ mv ${NEW}.incoming $NEW
+ fi
+ config $NEW
+}
+
config etc/nslcd.conf.new
-config etc/rc.d/rc.nss-pam-ldapd.new
+preserve_perms etc/rc.d/rc.nss-pam-ldapd.new