[contrib/cygwin/ssh-host-config]

Grammar changes on SYSCONFDIR LOCALSTATEDIR messages.
Check more thoroughly that it's possible to create the /var/empty directory.
Patch by vinschen AT redhat.com
This commit is contained in:
Tim Rice 2008-02-23 14:47:37 -08:00
parent 54e3773ccb
commit 401a27a307

View File

@ -131,7 +131,7 @@ fi
if [ -e "${SYSCONFDIR}" -a ! -d "${SYSCONFDIR}" ] if [ -e "${SYSCONFDIR}" -a ! -d "${SYSCONFDIR}" ]
then then
echo echo
echo "${SYSCONFDIR} is existant but not a directory." echo "${SYSCONFDIR} exists but is not a directory."
echo "Cannot create global configuration files." echo "Cannot create global configuration files."
echo echo
exit 1 exit 1
@ -156,7 +156,7 @@ fi
if [ -e ${LOCALSTATEDIR}/log -a ! -d ${LOCALSTATEDIR}/log ] if [ -e ${LOCALSTATEDIR}/log -a ! -d ${LOCALSTATEDIR}/log ]
then then
echo echo
echo "${LOCALSTATEDIR}/log is existant but not a directory." echo "${LOCALSTATEDIR}/log exists but is not a directory."
echo "Cannot create ssh host configuration." echo "Cannot create ssh host configuration."
echo echo
exit 1 exit 1
@ -181,11 +181,23 @@ then
fi fi
# Create /var/empty file used as chroot jail for privilege separation # Create /var/empty file used as chroot jail for privilege separation
if [ -f ${LOCALSTATEDIR}/empty ] if [ -e ${LOCALSTATEDIR}/empty -a ! -d ${LOCALSTATEDIR}/empty ]
then then
echo "Creating ${LOCALSTATEDIR}/empty failed!" echo
else echo "${LOCALSTATEDIR}/empty exists but is not a directory."
mkdir -p ${LOCALSTATEDIR}/empty echo "Cannot create ssh host configuration."
echo
exit 1
if [ ! -e ${LOCALSTATEDIR}/empty ]
then
if ! mkdir -p ${LOCALSTATEDIR}/empty
then
echo
echo "Creating ${LOCALSTATEDIR}/empty directory failed."
echo "Cannot create ssh host configuration."
echo
exit 1
fi
if [ ${_nt} -gt 0 ] if [ ${_nt} -gt 0 ]
then then
chmod 755 ${LOCALSTATEDIR}/empty chmod 755 ${LOCALSTATEDIR}/empty