summaryrefslogtreecommitdiff
path: root/net-analyzer/cacti-spine/files/cacti-spine-0.8.8d-ping.patch
blob: 55dc8754c8db2a6cdba916faf4809affaeccb49b (plain)
1
2
3
4
5
6
7
8
9
10
11
--- a/ping.c
+++ b/ping.c
@@ -913,7 +913,7 @@
 	struct hostent result;
 
 	buf = malloc(len*sizeof(char));
-	memset(buf, 0, sizeof(buf));
+	memset(buf, 0, len*sizeof(char));
 
 	while (1) {
 		hostinfo = gethostbyname_r(hostname, &result, buf, len, &h_errno);