[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: res_nsearch memory leaks



4 feb 2007 kl. 21.37 skrev Michael B Allen:

> Hi,
>
> I've been doing some testing with valgrind. It looks like the  
> res_nsearch
> API is leaking memory on my system. From doing a little Googling this
> is apparently because some OSs do not supply the required res_ndestroy
> function? Does anyone have further info?

When I look at theis the last time I thougth it happened on platforms
with res_ndestroy too ?

> Also, it seems the below is inconsistent. If res_ndestroy is called in
> the error condition should it not be called outside the do/while?

Yes, try 1.57 of lib/roken/resolve.c

----------------------------
revision 1.57
date: 2007/01/12 16:03:14;  author: lha;  state: Exp;  lines: +12 -8
Try harder to call res_ndestroy().
----------------------------

Love