ares_free_hostent.3 (903B)
1 .\" 2 .\" Copyright 1998 by the Massachusetts Institute of Technology. 3 .\" SPDX-License-Identifier: MIT 4 .\" 5 .TH ARES_FREE_HOSTENT 3 "23 July 1998" 6 .SH NAME 7 ares_free_hostent \- Free host structure allocated by ares functions 8 .SH SYNOPSIS 9 .nf 10 #include <ares.h> 11 12 void ares_free_hostent(struct hostent *\fIhost\fP) 13 .fi 14 .SH DESCRIPTION 15 The 16 .I ares_free_hostent 17 function frees a 18 .B struct hostent 19 allocated by one of the functions \fIares_parse_a_reply(3)\fP, 20 \fIares_parse_aaaa_reply(3)\fP, or \fIares_parse_ptr_reply(3)\fP. 21 .SH NOTES 22 It is not necessary (and is not correct) to free the host structure passed to 23 the callback functions for \fIares_gethostbyname(3)\fP or 24 \fIares_gethostbyaddr(3)\fP. c-ares will automatically free such host 25 structures when the callback returns. 26 .SH SEE ALSO 27 .BR ares_parse_a_reply (3), 28 .BR ares_parse_aaaa_reply (3), 29 .BR ares_parse_ptr_reply (3), 30 .BR ares_parse_ns_reply (3)