From fb84fd11a88352e0185271085c338d62a664b803 Mon Sep 17 00:00:00 2001 From: Stefan Wahren Date: Sat, 3 Aug 2013 15:51:34 +0200 Subject: [PATCH] Add additional check if directory is empty or hex file doesn't exists --- test/generate-xml.sh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/test/generate-xml.sh b/test/generate-xml.sh index e82b8b8..a0ee783 100755 --- a/test/generate-xml.sh +++ b/test/generate-xml.sh @@ -33,6 +33,10 @@ if [ ! -d "$directory" ]; then fi for hexfile in "$directory"/*.hex; do + if [ ! -f "$hexfile" ]; then + continue + fi + filename=`basename $hexfile .hex` # Parse hex file and write XML in file