From ee94596da357d00447799ac4280858ef5f9b5f5c Mon Sep 17 00:00:00 2001 From: Gerald Pfeifer Date: Fri, 3 Oct 2003 03:34:29 +0000 Subject: [PATCH] This is actually a /bin/sh script, /bin/bash is not needed. Check whether the two input files exists instead of assuming they do. --- programs/regapi/regSet.sh | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/programs/regapi/regSet.sh b/programs/regapi/regSet.sh index 89f7d1a2cbe..717357291e9 100755 --- a/programs/regapi/regSet.sh +++ b/programs/regapi/regSet.sh @@ -1,7 +1,7 @@ -#!/bin/bash +#!/bin/sh # This script is the receipe to generate the key that have to be created like -# if an applicaiton was installed by its installer. It processes using a +# if an application was installed by its installer. It processes using a # registry based on the picture of the registry before the application is # installed and the picture of the registry after the application is installed. # @@ -31,6 +31,9 @@ if [ $# -ne 2 ]; then exit 1 fi +if [ ! -f $1 ]; then echo "$1 does not exist."; exit 1; fi +if [ ! -f $2 ]; then echo "$2 does not exist."; exit 1; fi + echo "Assuming that $1 is the \"before\" file..." echo "Assuming that $2 is the \"after\" file..."