mirror of
https://github.com/freebsd/freebsd-src.git
synced 2024-11-27 13:32:45 +00:00
14b15f6ce4
Don't leak addrinfo if ai->ai_addrlen <= minsiz test fails. If the ai->ai_addrlen <= minsiz test fails, then freeaddrinfo() does not get called to free the memory just allocated by getaddrinfo(). Fix by moving ai->ai_addrlen <= minsiz to a separate nested if block, and keep freeaddrinfo() in the outer block so that freeaddrinfo() will be called whenever getaddrinfo() succeeds. Reported by: Coverity CID: 1273652 Reviewed by: ume Differential Revision: https://reviews.freebsd.org/D6756 |
||
---|---|---|
.. | ||
h_errno.c | ||
herror.c | ||
Makefile.inc | ||
mtctxres.c | ||
res_comp.c | ||
res_data.c | ||
res_debug.c | ||
res_debug.h | ||
res_findzonecut.c | ||
res_init.c | ||
res_mkquery.c | ||
res_mkupdate.c | ||
res_private.h | ||
res_query.c | ||
res_send.c | ||
res_state.c | ||
res_update.c | ||
Symbol.map |