summaryrefslogtreecommitdiffstats
path: root/plugins/check_http.c
diff options
context:
space:
mode:
authorKarl DeBisschop <kdebisschop@users.sourceforge.net>2003-04-23 04:58:38 (GMT)
committerKarl DeBisschop <kdebisschop@users.sourceforge.net>2003-04-23 04:58:38 (GMT)
commit6f0de2fb3a3c346cc98624c73d6dfd2858407b39 (patch)
treecab345591e745a99f5df5fd7d9051bc5de850758 /plugins/check_http.c
parent6b891545ced74ddb7e419fe1d13c0118cc13c316 (diff)
downloadmonitoring-plugins-6f0de2fb3a3c346cc98624c73d6dfd2858407b39.tar.gz
update to RFC1123 hostname specs
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/branches/release-1.3.0@498 f882894a-f735-0410-b71e-b25c423dba1c
Diffstat (limited to 'plugins/check_http.c')
-rw-r--r--plugins/check_http.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/plugins/check_http.c b/plugins/check_http.c
index 856acde..d13050a 100644
--- a/plugins/check_http.c
+++ b/plugins/check_http.c
@@ -187,7 +187,7 @@ struct timeval tv;
187#define URI_PATH "%[/a-zA-Z0-9._-=@,]" 187#define URI_PATH "%[/a-zA-Z0-9._-=@,]"
188 188
189enum { 189enum {
190 MAX_IPV4_HOSTLENGTH = 64, 190 MAX_IPV4_HOSTLENGTH = 255,
191 HTTP_PORT = 80, 191 HTTP_PORT = 80,
192 HTTPS_PORT = 443 192 HTTPS_PORT = 443
193}; 193};
@@ -734,7 +734,7 @@ check_http (void)
734 asprintf (&orig_url, "%s", server_url); 734 asprintf (&orig_url, "%s", server_url);
735 pos = header; 735 pos = header;
736 while (pos) { 736 while (pos) {
737 server_address = realloc (server_address, MAX_IPV4_HOSTLENGTH); 737 server_address = realloc (server_address, MAX_IPV4_HOSTLENGTH + 1);
738 if (server_address == NULL) 738 if (server_address == NULL)
739 terminate (STATE_UNKNOWN, 739 terminate (STATE_UNKNOWN,
740 "HTTP UNKNOWN: could not allocate server_address"); 740 "HTTP UNKNOWN: could not allocate server_address");