From 3c091969d57b6c18e8ede68acd92c11f19fbbad0 Mon Sep 17 00:00:00 2001 From: Raman Gupta Date: Wed, 15 Jul 2020 01:12:34 -0400 Subject: [PATCH] Force output file spec --- scan | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/scan b/scan index 94438db..391388e 100755 --- a/scan +++ b/scan @@ -131,6 +131,11 @@ if [ $USEARRAY = 0 -a -f "$OUTPUT" -a ! $APPEND = 1 ]; then exit 1 fi +if [ "$OUTPUT" = "" ]; then + echo >&2 "Output file must be specified. Aborting." + exit 1 +fi + if [ $USEARRAY = 1 -a ! $APPEND = 1 ]; then for o in "${OUTPUT[@]}"; do if [ -f "$o" ]; then