diff options
author | Bertrand Marc <beberking@gmail.com> | 2012-09-29 15:44:22 +0200 |
---|---|---|
committer | Bertrand Marc <beberking@gmail.com> | 2012-09-29 15:44:22 +0200 |
commit | 484a9cc0b45db2a3e38644a35bfa8c5d5636d157 (patch) | |
tree | fde429bc0f826e29c35dcd2f08b97fc647e06fb9 | |
parent | c1ca2887668538d7c0c9cd63c3d69428219ef4b2 (diff) |
gnunet-server.postinst: check the existence of a binary before changing its permissions (Closes: #688484).
-rw-r--r-- | debian/gnunet-server.postinst | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/debian/gnunet-server.postinst b/debian/gnunet-server.postinst index 76fb9a8..18e0252 100644 --- a/debian/gnunet-server.postinst +++ b/debian/gnunet-server.postinst @@ -86,18 +86,20 @@ case "${1}" in /usr/bin/gnunet-helper-vpn do # only do something when no setting exists - if ! dpkg-statoverride --list $file >/dev/null 2>&1 + if ! dpkg-statoverride --list $file >/dev/null 2>&1 && [ -e $file ] then chown root:${_GROUPNAME} $file chmod 4754 $file fi done - if ! dpkg-statoverride --list /usr/bin/gnunet-helper-dns >/dev/null 2>&1 + if ! dpkg-statoverride --list /usr/bin/gnunet-helper-dns >/dev/null 2>&1 \ + && [ -e /usr/bin/gnunet-helper-dns ] then chown root:${GNUNETDNS_GROUP} /usr/bin/gnunet-helper-dns chmod 4754 /usr/bin/gnunet-helper-dns fi - if ! dpkg-statoverride --list /usr/bin/gnunet-service-dns >/dev/null 2>&1 + if ! dpkg-statoverride --list /usr/bin/gnunet-service-dns >/dev/null 2>&1 \ + && [ -e /usr/bin/gnunet-service-dns ] then chown ${_USERNAME}:${GNUNETDNS_GROUP} /usr/bin/gnunet-service-dns chmod 2754 /usr/bin/gnunet-service-dns |