ucx/list.c

changeset 22
76cdd8209f1f
parent 18
69636f81db31
child 23
ccc294fafb9b
     1.1 --- a/ucx/list.c	Sat Jan 14 13:07:18 2012 +0100
     1.2 +++ b/ucx/list.c	Sun Jan 15 14:12:34 2012 +0100
     1.3 @@ -110,8 +110,10 @@
     1.4  
     1.5  void ucx_list_foreach(UcxList *l, ucx_callback fnc, void* data) {
     1.6      UcxList *e = l;
     1.7 +    UcxList *n;
     1.8      while (e != NULL) {
     1.9 +        n = e->next;
    1.10          fnc(e, data);
    1.11 -        e = e->next;
    1.12 +        e = n;
    1.13      }
    1.14  }

mercurial