configure: avoid direct usage of AS_TR_* macros
[platform/upstream/c-ares.git] / ares_free_hostent.c
index f07fd7c..349d379 100644 (file)
@@ -1,4 +1,3 @@
-/* $Id$ */
 
 /* Copyright 1998 by the Massachusetts Institute of Technology.
  *
@@ -29,6 +28,9 @@ void ares_free_hostent(struct hostent *host)
 {
   char **p;
 
+  if (!host)
+    return;
+
   free((char *)(host->h_name));
   for (p = host->h_aliases; *p; p++)
     free(*p);