Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- sub main {
- my $ipmon = shift;
- my (@args) = @_;
- my $socket;
- my ($rc, $output);
- my ($state, $msg);
- my %options;
- my ($function, $arg);
- {
- local @ARGV = @args;
- my $result = GetOptions(
- \%options,
- "host|H=s",
- "user=s",
- "password=s",
- "Port|P=i",
- "warning=s",
- "critical=s",
- "debug",
- );
- # remainder is the function and argument (if any)
- ($function, $arg) = @ARGV;
- }
Add Comment
Please, Sign In to add comment