Complete.Org: Mailing Lists: Archives: freeciv-dev: November 2003:
[Freeciv-Dev] (PR#6816) Re: Re: (PR#6819) server crashes when loaded tri
Home

[Freeciv-Dev] (PR#6816) Re: Re: (PR#6819) server crashes when loaded tri

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: ggracian@xxxxxxx
Subject: [Freeciv-Dev] (PR#6816) Re: Re: (PR#6819) server crashes when loaded trireme is lost
From: "Per I. Mathisen" <per@xxxxxxxxxxx>
Date: Mon, 10 Nov 2003 13:44:49 -0800
Reply-to: rt@xxxxxxxxxxx

<URL: http://rt.freeciv.org/Ticket/Display.html?id=6816 >

On Mon, 10 Nov 2003, Raimar Falke wrote:
> but Jason doesn't know why "wipe_unit is inherently safe". I have
> searched the changes of unittools.c and genlist.c but none indicated
> that something was changed in them that will make removing in an item
> in a list safe while you iterate over it.
>
> So Per, Jason can you shed more light on this?

Use unit_list_iterate_safe for places where you iterate units while you
pull the rug underneat your own unit list by deleting units at random in
the list (wipe_unit can do this due to cargo).

  - Per




[Prev in Thread] Current Thread [Next in Thread]