From f810a45dc16ab5af0c9e16be4b307ae5bd0f0e75 Mon Sep 17 00:00:00 2001 From: keni Date: Tue, 15 May 2018 16:30:28 -0400 Subject: [PATCH] fix H7138: sys/unix/setup.sh fails with no arguments Sanity check was in the wrong place. --- sys/unix/setup.sh | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/sys/unix/setup.sh b/sys/unix/setup.sh index 5c210264c..043bf90d4 100755 --- a/sys/unix/setup.sh +++ b/sys/unix/setup.sh @@ -23,14 +23,14 @@ x) hints=/dev/null ;; *) hints=$prefix/$1 hfile=$1 + # sanity check + if [ ! -f "$hints" ]; then + echo "Cannot find hints file $hfile" + exit 1 + fi ;; esac -if [ ! -f "$hints" ]; then - echo "Cannot find hints file $hfile" - exit 1 -fi - /bin/sh ./mkmkfile.sh Makefile.top TOP ../../Makefile $hints $hfile /bin/sh ./mkmkfile.sh Makefile.dat DAT ../../dat/Makefile $hints $hfile /bin/sh ./mkmkfile.sh Makefile.doc DOC ../../doc/Makefile $hints $hfile