From 73c2f8174d42b25324ba29b5128e34d3b1e8a09e Mon Sep 17 00:00:00 2001 From: Bram Matthys Date: Fri, 22 Oct 2010 13:08:05 +0000 Subject: [PATCH] (interim) fix, not worth mentioning --- unreal.in | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/unreal.in b/unreal.in index aff181630..0658742a6 100644 --- a/unreal.in +++ b/unreal.in @@ -29,12 +29,24 @@ if [ "$1" = "start" ] ; then fi elif [ "$1" = "stop" ] ; then echo "Stopping UnrealIRCd" + if [ ! -r $PID_FILE ] ; then + echo "ERROR: UnrealIRCd is not running" + exit 1 + fi kill -9 `cat $PID_FILE` elif [ "$1" = "rehash" ] ; then echo "Rehashing UnrealIRCd" + if [ ! -r $PID_FILE ] ; then + echo "ERROR: UnrealIRCd is not running" + exit 1 + fi kill -1 `cat $PID_FILE` elif [ "$1" = "restart" ] ; then echo "Restarting UnrealIRCd" + if [ ! -r $PID_FILE ] ; then + echo "ERROR: UnrealIRCd is not running" + exit 1 + fi kill -2 `cat $PID_FILE` elif [ "$1" = "mkpasswd" ] ; then @BINDIR@ -P $2 $3