diff options
author | Sven Nierlein <sven@nierlein.org> | 2013-08-15 08:57:11 (GMT) |
---|---|---|
committer | Sven Nierlein <sven@nierlein.org> | 2013-08-15 08:57:11 (GMT) |
commit | 5815864e6cda7c247b62d1c9e84349e5a678040f (patch) | |
tree | 8ba0727180cd7aaeb11d5817e5083cf267cdb383 | |
parent | b6f0e755fda5d95ccc7312fd4c99e1e707210d6c (diff) | |
parent | 14225eb4641af25f3317e4ee3d8af7007b55bf42 (diff) | |
download | monitoring-plugins-5815864e6cda7c247b62d1c9e84349e5a678040f.tar.gz |
Merge pull request #52 from g0hl1n/sf_3571331_check_http_-_removed_semicolon_delimiter_in_-k
Fixed SF.net bug #3571331, check_http converts semicolon to newline in -k
-rw-r--r-- | plugins/check_http.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/plugins/check_http.c b/plugins/check_http.c index 9231a55..110875d 100644 --- a/plugins/check_http.c +++ b/plugins/check_http.c | |||
@@ -43,7 +43,6 @@ const char *email = "nagiosplug-devel@lists.sourceforge.net"; | |||
43 | #include "base64.h" | 43 | #include "base64.h" |
44 | #include <ctype.h> | 44 | #include <ctype.h> |
45 | 45 | ||
46 | #define INPUT_DELIMITER ";" | ||
47 | #define STICKY_NONE 0 | 46 | #define STICKY_NONE 0 |
48 | #define STICKY_HOST 1 | 47 | #define STICKY_HOST 1 |
49 | #define STICKY_PORT 2 | 48 | #define STICKY_PORT 2 |
@@ -854,8 +853,7 @@ check_http (void) | |||
854 | /* optionally send any other header tag */ | 853 | /* optionally send any other header tag */ |
855 | if (http_opt_headers_count) { | 854 | if (http_opt_headers_count) { |
856 | for (i = 0; i < http_opt_headers_count ; i++) { | 855 | for (i = 0; i < http_opt_headers_count ; i++) { |
857 | for ((pos = strtok(http_opt_headers[i], INPUT_DELIMITER)); pos; (pos = strtok(NULL, INPUT_DELIMITER))) | 856 | xasprintf (&buf, "%s%s\r\n", buf, http_opt_headers[i]); |
858 | xasprintf (&buf, "%s%s\r\n", buf, pos); | ||
859 | } | 857 | } |
860 | /* This cannot be free'd here because a redirection will then try to access this and segfault */ | 858 | /* This cannot be free'd here because a redirection will then try to access this and segfault */ |
861 | /* Covered in a testcase in tests/check_http.t */ | 859 | /* Covered in a testcase in tests/check_http.t */ |