From 1df1b7777047bf71e574b675fc47b67ba41c122e Mon Sep 17 00:00:00 2001 From: Julien (jvoisin) Voisin Date: Wed, 24 Feb 2016 17:39:50 +0100 Subject: Add even moar sanity check --- php-malware-finder/phpmalwarefinder | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/php-malware-finder/phpmalwarefinder b/php-malware-finder/phpmalwarefinder index 215c8ef..8edb079 100755 --- a/php-malware-finder/phpmalwarefinder +++ b/php-malware-finder/phpmalwarefinder @@ -19,14 +19,19 @@ fi if [ ! -f "$CONFIG_PATH" ] then CONFIG_PATH='./malwares.yara' + if [ ! -f "$CONFIG_PATH" ] + then + echo "Unable to find `malware.yara` in $CONFIG_PATH, and in the current directory." + exit 0 + fi fi -if [ -f "${IONICE_BIN}" ] +if [ -x "${IONICE_BIN}" ] then NICE=${IONICE_BIN} NICE_OPTS="-c 3" else - if [ -f "${NICE_BIN}" ] + if [ -x "${NICE_BIN}" ] then NICE=${NICE_BIN} NICE_OPTS="-n 20" -- cgit v1.3