From: Karl DeBisschop Date: Thu, 19 Dec 2002 19:29:57 +0000 (+0000) Subject: server expect not getting set, expect is +OK for POP X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=198b425de624e8d67b537fd559d2c6cbd40d12ee;p=nagiosplug.git server expect not getting set, expect is +OK for POP git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@232 f882894a-f735-0410-b71e-b25c423dba1c --- diff --git a/plugins/check_tcp.c b/plugins/check_tcp.c index 29a7ab5..cbe8595 100644 --- a/plugins/check_tcp.c +++ b/plugins/check_tcp.c @@ -142,7 +142,7 @@ main (int argc, char **argv) asprintf (&PROGNAME, "check_pop"); asprintf (&SERVICE, "POP"); SEND = NULL; - asprintf (&EXPECT, "110"); + asprintf (&EXPECT, "+OK"); asprintf (&QUIT, "QUIT\r\n"); PROTOCOL = TCP_PROTOCOL; PORT = 110; @@ -205,7 +205,7 @@ main (int argc, char **argv) /* use default expect if none listed in process_arguments() */ if (EXPECT && server_expect_count == 0) { - server_expect = malloc (1); + server_expect = malloc (++server_expect_count); server_expect[server_expect_count - 1] = EXPECT; }