From 58e93c21b1c1b06613a8f06fe794f57f439b4eb2 Mon Sep 17 00:00:00 2001 From: Colin Watson Date: Thu, 18 Oct 2007 13:42:08 +0000 Subject: * Discard error output from dpkg-query in preinsts, in case the ssh metapackage is not installed. --- debian/changelog | 2 ++ debian/openssh-client.preinst | 2 +- debian/openssh-server.preinst | 2 +- 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/debian/changelog b/debian/changelog index b75c994d3..dfbb49f05 100644 --- a/debian/changelog +++ b/debian/changelog @@ -5,6 +5,8 @@ openssh (1:4.6p1-6) UNRELEASED; urgency=low versions of debconf. * Install authorized_keys(5) as a symlink to sshd(8) (thanks, Tomas Pospisek; closes: #441817). + * Discard error output from dpkg-query in preinsts, in case the ssh + metapackage is not installed. * debconf template translations: - Add Slovak (thanks, Ivan Masár; closes: #441690). diff --git a/debian/openssh-client.preinst b/debian/openssh-client.preinst index fd55a53bd..0b29c051d 100644 --- a/debian/openssh-client.preinst +++ b/debian/openssh-client.preinst @@ -37,7 +37,7 @@ prepare_transfer_conffile () { case $action in install|upgrade) if dpkg --compare-versions "$version" lt 0; then - CONFFILES="$(dpkg-query -W -f '${Conffiles}\n' ssh | sed 's/^ *//')" + CONFFILES="$(dpkg-query -W -f '${Conffiles}\n' ssh 2>/dev/null | sed 's/^ *//')" prepare_transfer_conffile /etc/ssh/moduli "$ETC_SSH_MODULI" 0644 prepare_transfer_conffile /etc/ssh/ssh_config "$ETC_SSH_SSH_CONFIG" 0644 fi diff --git a/debian/openssh-server.preinst b/debian/openssh-server.preinst index 866cf8b1a..87871bdaa 100644 --- a/debian/openssh-server.preinst +++ b/debian/openssh-server.preinst @@ -112,7 +112,7 @@ EOF fi if dpkg --compare-versions "$version" lt 0; then - CONFFILES="$(dpkg-query -W -f '${Conffiles}\n' ssh | sed 's/^ *//')" + CONFFILES="$(dpkg-query -W -f '${Conffiles}\n' ssh 2>/dev/null | sed 's/^ *//')" prepare_transfer_conffile /etc/default/ssh "$ETC_DEFAULT_SSH" 0644 prepare_transfer_conffile /etc/init.d/ssh "$ETC_INIT_D_SSH" 0755 prepare_transfer_conffile /etc/pam.d/ssh "$ETC_PAM_D_SSH" 0644 -- cgit v1.2.3