From: DjSlash Date: Fri, 18 Mar 2011 15:02:29 +0000 (+0100) Subject: Fix for bug 116, in addition an improvement of the regex is made X-Git-Tag: v2.0.23~812 X-Git-Url: https://git.netwichtig.de/gitweb/?a=commitdiff_plain;h=0c23190956104cb62494e5b399bacd45ff2ca464;p=user%2Fhenk%2Fcode%2Finspircd.git Fix for bug 116, in addition an improvement of the regex is made --- diff --git a/make/template/inspircd b/make/template/inspircd index 1b9f25a86..d5e89040d 100644 --- a/make/template/inspircd +++ b/make/template/inspircd @@ -380,7 +380,7 @@ sub getpidfile sub getstatus { my $pid = getprocessid(); return 0 if $pid == 0; - return kill 0, $1; + return kill 0, $pid; } @@ -389,7 +389,7 @@ sub getprocessid { open PIDFILE, '<', $pidfile or return 0; while() { - /(\d+)/ and $pid = $1; + /^(\d+)$/ and $pid = $1; } close PIDFILE; return $pid;