Code

substituted $ID$ through $Revision$ in print_revision call
[nagiosplug.git] / plugins-scripts / check_ircd.pl
index e4c4bd02686f53ec34d3fb619af0c30a3eca7e73..7a90a96b5184163568b847798b0854661f8835d5 100755 (executable)
 #                              with perl -wT and 'use strict'
 #
 # test using check_ircd.pl (irc-2.mit.edu|irc.erols.com|irc.core.com)
+# 2002/05/02    SG             Fixed for Embedded Perl
 #
-# ------------------------------------------------------------------[ Begin ]--
-
-BEGIN {
-       if ($0 =~ m/^(.*?)[\/\\]([^\/\\]+)$/) {
-               $runtimedir = $1;
-               $PROGNAME = $2;
-       }
-}
 
 # ----------------------------------------------------------------[ Require ]--
 
@@ -59,7 +52,7 @@ use strict;
 use Getopt::Long;
 use vars qw($opt_V $opt_h $opt_t $opt_p $opt_H $opt_w $opt_c $verbose);
 use vars qw($PROGNAME);
-use lib $main::runtimedir;
+use lib utils.pm;
 use utils qw($TIMEOUT %ERRORS &print_revision &support &usage);
 
 # ----------------------------------------------------[ Function Prototypes ]--
@@ -77,6 +70,7 @@ $ENV{BASH_ENV} = "";
 
 # -----------------------------------------------------------------[ Global ]--
 
+$PROGNAME = "check_ircd";
 my $NICK="ircd$$";
 my $USER_INFO="monitor localhost localhost : ";