aboutsummaryrefslogtreecommitdiffstats
path: root/main/pingu/0001-pingu_burst-memleak-fix.patch
blob: a4bb616f0046b1356894e2fc33c8942f3a6687ae (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
From 8b66a8da87f0ff9d0932a4eb030c96c31f123e93 Mon Sep 17 00:00:00 2001
From: Natanael Copa <ncopa@alpinelinux.org>
Date: Wed, 14 Mar 2012 14:31:29 +0100
Subject: [PATCH 1/2] pingu_burst: memleak fix

we need to run freeaddrinfo() after getaddrinfo()
---
 pingu_burst.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/pingu_burst.c b/pingu_burst.c
index cdb5306..3505c94 100644
--- a/pingu_burst.c
+++ b/pingu_burst.c
@@ -50,6 +50,7 @@ void ping_burst_start(struct ev_loop *loop, struct pingu_host *host)
 		log_debug("%s: failed to send first ping to %s", host->label, buf);
 		host->burst.active = 0;
 	}
+	freeaddrinfo(ai);
 }
 
 void pingu_burst_timeout_cb(struct ev_loop *loop, struct ev_timer *w,
-- 
1.7.7.1