1 /* $NetBSD: alist_free.c,v 1.2 2012/07/22 14:27:36 darrenr Exp $ */ 2 3 /* 4 * Copyright (C) 2012 by Darren Reed. 5 * 6 * See the IPFILTER.LICENCE file for details on licencing. 7 * 8 * Id: alist_free.c,v 1.1.1.2 2012/07/22 13:44:38 darrenr Exp $ 9 */ 10 #include "ipf.h" 11 12 void alist_free(hosts)13alist_free(hosts) 14 alist_t *hosts; 15 { 16 alist_t *a, *next; 17 18 for (a = hosts; a != NULL; a = next) { 19 next = a->al_next; 20 free(a); 21 } 22 } 23