From 16aa743d884d4da37199a0ee7fbc4b601a4cfc02 Mon Sep 17 00:00:00 2001 From: Jason Downs Date: Sat, 20 Jun 1998 01:49:04 +0000 Subject: Handle case where rc.conf exists but has no named_chroot. --- usr.sbin/named/ndc/ndc.sh | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'usr.sbin') diff --git a/usr.sbin/named/ndc/ndc.sh b/usr.sbin/named/ndc/ndc.sh index 7d736677f0f..4fcea9296a8 100644 --- a/usr.sbin/named/ndc/ndc.sh +++ b/usr.sbin/named/ndc/ndc.sh @@ -1,5 +1,5 @@ #!/bin/sh -# $OpenBSD: ndc.sh,v 1.9 1998/06/03 17:15:59 millert Exp $ +# $OpenBSD: ndc.sh,v 1.10 1998/06/20 01:49:03 downsj Exp $ USAGE='echo \ "usage: $0 \ @@ -11,6 +11,10 @@ PATH=%DESTSBIN%:/bin:/usr/bin:/usr/ucb:$PATH if [ -r /etc/rc.conf ]; then CHROOTDIR=`. /etc/rc.conf ; echo "$named_chroot"` + # In case rc.conf exists but does not specify $named_chroot. + if [ "X${CHROOTDIR}" == "X" ]; then + CHROOTDIR=/var/named + fi else CHROOTDIR=%CHROOTDIR% fi -- cgit v1.2.3