diff options
| -rw-r--r-- | THANKS.in | 2 | ||||
| -rw-r--r-- | plugins/check_tcp.c | 2 | ||||
| -rw-r--r-- | plugins/t/check_imap.t | 4 |
3 files changed, 6 insertions, 2 deletions
| @@ -169,3 +169,5 @@ Chester Hosey | |||
| 169 | Pascal Larisch | 169 | Pascal Larisch |
| 170 | David Sullivan | 170 | David Sullivan |
| 171 | Bob Ingraham | 171 | Bob Ingraham |
| 172 | Hans Engelen | ||
| 173 | Rick Frey | ||
diff --git a/plugins/check_tcp.c b/plugins/check_tcp.c index cb7a869d..08ec8565 100644 --- a/plugins/check_tcp.c +++ b/plugins/check_tcp.c | |||
| @@ -311,7 +311,7 @@ main (int argc, char **argv) | |||
| 311 | 311 | ||
| 312 | /* did we get the response we hoped? */ | 312 | /* did we get the response we hoped? */ |
| 313 | if(match == -2 && result != STATE_CRITICAL) | 313 | if(match == -2 && result != STATE_CRITICAL) |
| 314 | result = STATE_WARNING; | 314 | result = expect_mismatch_state; |
| 315 | 315 | ||
| 316 | /* reset the alarm */ | 316 | /* reset the alarm */ |
| 317 | alarm (0); | 317 | alarm (0); |
diff --git a/plugins/t/check_imap.t b/plugins/t/check_imap.t index f86faa4c..32b4136a 100644 --- a/plugins/t/check_imap.t +++ b/plugins/t/check_imap.t | |||
| @@ -10,7 +10,7 @@ use Test; | |||
| 10 | use NPTest; | 10 | use NPTest; |
| 11 | 11 | ||
| 12 | use vars qw($tests); | 12 | use vars qw($tests); |
| 13 | BEGIN {$tests = 5; plan tests => $tests} | 13 | BEGIN {$tests = 7; plan tests => $tests} |
| 14 | 14 | ||
| 15 | my $host_tcp_smtp = getTestParameter( "host_tcp_smtp", "NP_HOST_TCP_SMTP", "mailhost", | 15 | my $host_tcp_smtp = getTestParameter( "host_tcp_smtp", "NP_HOST_TCP_SMTP", "mailhost", |
| 16 | "A host providing an STMP Service (a mail server)"); | 16 | "A host providing an STMP Service (a mail server)"); |
| @@ -33,6 +33,8 @@ $t += checkCmd( "./check_imap -H $host_tcp_imap -p 143 -w 9 -c 9 -t 10 -e '* | |||
| 33 | $t += checkCmd( "./check_imap $host_tcp_imap -p 143 -wt 9 -ct 9 -to 10 -e '* OK'", 0, undef, %exceptions ); | 33 | $t += checkCmd( "./check_imap $host_tcp_imap -p 143 -wt 9 -ct 9 -to 10 -e '* OK'", 0, undef, %exceptions ); |
| 34 | $t += checkCmd( "./check_imap $host_nonresponsive", 2 ); | 34 | $t += checkCmd( "./check_imap $host_nonresponsive", 2 ); |
| 35 | $t += checkCmd( "./check_imap $hostname_invalid", 2 ); | 35 | $t += checkCmd( "./check_imap $hostname_invalid", 2 ); |
| 36 | $t += checkCmd( "./check_imap -H $host_tcp_imap -e unlikely_string", 1); | ||
| 37 | $t += checkCmd( "./check_imap -H $host_tcp_imap -e unlikely_string -M crit", 2); | ||
| 36 | 38 | ||
| 37 | 39 | ||
| 38 | exit(0) if defined($Test::Harness::VERSION); | 40 | exit(0) if defined($Test::Harness::VERSION); |
