From: Corinna Vinschen Date: Tue, 10 Dec 2002 16:36:36 +0000 (+0000) Subject: * net.cc (free_protoent_ptr): Add missing free() for base structure. X-Git-Tag: newlib-1_11_0~58 X-Git-Url: https://sourceware.org/git/?a=commitdiff_plain;h=231a60c73a7c365f7a49e68fce114965f257f790;p=newlib-cygwin.git * net.cc (free_protoent_ptr): Add missing free() for base structure. (free_servent_pt): Ditto. (free_hostent_pt): Ditto. --- diff --git a/winsup/cygwin/ChangeLog b/winsup/cygwin/ChangeLog index 55427805c..51d79af9b 100644 --- a/winsup/cygwin/ChangeLog +++ b/winsup/cygwin/ChangeLog @@ -1,3 +1,9 @@ +2002-12-10 Corinna Vinschen + + * net.cc (free_protoent_ptr): Add missing free() for base structure. + (free_servent_pt): Ditto. + (free_hostent_pt): Ditto. + 2002-12-10 Craig McGeachie * netdb.cc (parse_alias_list, parse_services_line) diff --git a/winsup/cygwin/net.cc b/winsup/cygwin/net.cc index a02d45fa4..06b9a5acb 100644 --- a/winsup/cygwin/net.cc +++ b/winsup/cygwin/net.cc @@ -437,6 +437,7 @@ free_protoent_ptr (struct protoent *&p) if (p->p_name) free (p->p_name); free_char_list (p->p_aliases); + free ((void *) p); p = NULL; } } @@ -784,6 +785,7 @@ free_servent_ptr (struct servent *&p) if (p->s_proto) free (p->s_proto); free_char_list (p->s_aliases); + free ((void *) p); p = NULL; } } @@ -915,6 +917,7 @@ free_hostent_ptr (struct hostent *&p) free ((void *) p->h_name); free_char_list (p->h_aliases); free_addr_list (p->h_addr_list); + free ((void *) p); p = NULL; } }