mirror of
https://github.com/monitoring-plugins/monitoring-plugins.git
synced 2026-04-15 22:00:06 -04:00
Simply initializes n before it is used
When SSL is enabled, n is assigned the size of the server's second EHLO response (I think in bytes), which will usually be significantly higher than the command passed. As such, no commands are executed and no responses are checked, which - silently - defeats the desired checks and results in a success value.
This commit is contained in:
parent
5237395433
commit
8520c643dd
1 changed files with 1 additions and 0 deletions
|
|
@ -293,6 +293,7 @@ main (int argc, char **argv)
|
|||
printf("%s", buffer);
|
||||
}
|
||||
|
||||
n = 0;
|
||||
while (n < ncommands) {
|
||||
xasprintf (&cmd_str, "%s%s", commands[n], "\r\n");
|
||||
my_send(cmd_str, strlen(cmd_str));
|
||||
|
|
|
|||
Loading…
Reference in a new issue