From 6858e123497aee69dedce5d22fcacec99c7043b4 Mon Sep 17 00:00:00 2001 From: Colin Watson Date: Sat, 10 Jul 2004 01:03:04 +0000 Subject: Fix bashisms in maintainer scripts (thanks, David Weinehall; partial fix for #258517). --- debian/changelog | 2 ++ debian/config | 4 ++-- debian/postinst | 4 ++-- debian/preinst | 6 +++--- 4 files changed, 9 insertions(+), 7 deletions(-) (limited to 'debian') diff --git a/debian/changelog b/debian/changelog index d11a8a472..2c6564368 100644 --- a/debian/changelog +++ b/debian/changelog @@ -5,6 +5,8 @@ openssh (1:3.8.1p1-5) UNRELEASED; urgency=low * Remove Suggests: dnsutils, as it was only needed for make-ssh-known-hosts (#93265), which has been replaced by ssh-keyscan. * Disable shadow password support in openssh-server-udeb. + * Fix bashisms in maintainer scripts (thanks, David Weinehall; partial fix + for #258517). -- Colin Watson Wed, 2 Jun 2004 14:26:18 -0300 diff --git a/debian/config b/debian/config index ea737a081..b5cff528c 100644 --- a/debian/config +++ b/debian/config @@ -3,7 +3,7 @@ action=$1 version=$2 -if [ -d /etc/ssh-nonfree -a ! -d /etc/ssh ]; then +if [ -d /etc/ssh-nonfree ] && [ ! -d /etc/ssh ]; then version=1.2.27 cp -a /etc/ssh-nonfree /etc/ssh fi @@ -30,7 +30,7 @@ else db_fset ssh/use_old_init_script seen true fi -if [ -z "$version" -a ! -e /etc/ssh/sshd_config ] +if [ -z "$version" ] && [ ! -e /etc/ssh/sshd_config ] then db_input medium ssh/protocol2_only || true fi diff --git a/debian/postinst b/debian/postinst index b641769ba..ac5e1c555 100644 --- a/debian/postinst +++ b/debian/postinst @@ -28,9 +28,9 @@ check_idea_key() { create_key() { - local msg="$1" + msg="$1" shift - local file="$1" + file="$1" shift if [ ! -f "$file" ] ; then diff --git a/debian/preinst b/debian/preinst index 320d4df2a..e22d0aa5d 100644 --- a/debian/preinst +++ b/debian/preinst @@ -3,11 +3,11 @@ action=$1 version=$2 -if [ -d /etc/ssh-nonfree -a ! -d /etc/ssh ]; then +if [ -d /etc/ssh-nonfree ] && [ ! -d /etc/ssh ]; then version=1.2.27 fi -if [ "$action" = upgrade -o "$action" = install ] +if [ "$action" = upgrade ] || [ "$action" = install ] then # check if debconf is missing if ! test -f /usr/share/debconf/confmodule @@ -39,7 +39,7 @@ EOF # work around for missing debconf db_get() { : ; } RET=true - if [ -d /etc/ssh-nonfree -a ! -d /etc/ssh ]; then + if [ -d /etc/ssh-nonfree ] && [ ! -d /etc/ssh ]; then cp -a /etc/ssh-nonfree /etc/ssh fi else -- cgit v1.2.3