along with this program; if not, write to the Free Software
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
- $Id: list.c,v 1.1.2.9 2001/02/25 15:34:50 guus Exp $
+ $Id: list.c,v 1.1.2.10 2002/03/27 15:01:16 guus Exp $
*/
#include "config.h"
else
list->tail = node;
+ list->count++;
+
return node;
}
else
list->head = node;
+ list->count++;
+
return node;
}
node->next->prev = node->prev;
else
list->tail = node->prev;
+
+ list->count--;
}
void list_delete_node(list_t *list, list_node_t *node)
along with this program; if not, write to the Free Software
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
- $Id: list.h,v 1.1.2.4 2001/01/07 17:08:50 guus Exp $
+ $Id: list.h,v 1.1.2.5 2002/03/27 15:01:16 guus Exp $
*/
#ifndef __TINC_LIST_H__
{
list_node_t *head;
list_node_t *tail;
+ int count;
/* Callbacks */