Complete.Org:
Mailing Lists:
Archives:
freeciv-dev:
September 2004: [Freeciv-Dev] (PR#10113) genlist_unlink_all bug |
![]() |
[Freeciv-Dev] (PR#10113) genlist_unlink_all bug[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
<URL: http://rt.freeciv.org/Ticket/Display.html?id=10113 > Apparently nobody uses genlist_unlink_all. There's a bug because of a missing NULL check. jason ? settler_recursion_crash Index: utility/genlist.c =================================================================== RCS file: /home/freeciv/CVS/freeciv/utility/genlist.c,v retrieving revision 1.15 diff -u -r1.15 genlist.c --- utility/genlist.c 14 Sep 2004 21:10:44 -0000 1.15 +++ utility/genlist.c 14 Sep 2004 22:53:51 -0000 @@ -100,7 +100,7 @@ plink = plink->next; } - if(plink->dataptr==punlink) { + if (plink && plink == punlink) { if(pgenlist->head_link==plink) pgenlist->head_link=plink->next; else
|