summaryrefslogtreecommitdiffstats
path: root/plugins/t
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/t')
0 files changed, 0 insertions, 0 deletions
diff --git a/plugins/check_tcp.c b/plugins/check_tcp.c
index 979dfad..fd2fe66 100644
--- a/plugins/check_tcp.c
+++ b/plugins/check_tcp.c
@@ -322,8 +322,10 @@ main (int argc, char **argv)
322 while ((i = my_recv ()) > 0) { 322 while ((i = my_recv ()) > 0) {
323 buffer[i] = '\0'; 323 buffer[i] = '\0';
324 asprintf (&status, "%s%s", status, buffer); 324 asprintf (&status, "%s%s", status, buffer);
325 if (buffer[i-2] == '\r' && buffer[i-1] == '\n') 325 if (buffer[i-1] == '\n') {
326 break; 326 if (buffer[i-2] == '\r' || i < MAXBUF-1)
327 break;
328 }
327 if (maxbytes>0 && strlen(status) >= (unsigned)maxbytes) 329 if (maxbytes>0 && strlen(status) >= (unsigned)maxbytes)
328 break; 330 break;
329 } 331 }