URL:
<http://gna.org/bugs/?13708>
Summary: [Patch] Fix memory leak in sea barbarian creation
Project: Freeciv
Submitted by: cazfi
Submitted on: Wednesday 06/17/2009 at 01:44
Category: None
Severity: 3 - Normal
Priority: 1 - Later
Status: None
Assigned to: None
Originator Email:
Open/Closed: Open
Discussion Lock: Any
Release:
Operating System: None
_______________________________________________________
Details:
Creation of barbarian boat causes call to ai_data_get() after
ai_data_phase_done() is called for the turn. ai_data_get() has side-effect of
sometimes calling ai_data_phase_done() and ai_data_phase_init(). There is
memory leak when there is no ai_data_phase_done() between two
ai_data_phase_init() calls.
Attached patch fixes this memory leak by wrapping sea barbarian creation
between separate ai_data_phase_init() and ai_data_phase_done() calls. We
can't extend turn's main ai_data_phase_init() and ai_data_phase_done()
there.
_______________________________________________________
File Attachments:
-------------------------------------------------------
Date: Wednesday 06/17/2009 at 01:44 Name: CreateBarbDataPhase.diff Size:
591B By: cazfi
<http://gna.org/bugs/download.php?file_id=5985>
_______________________________________________________
Reply to this item at:
<http://gna.org/bugs/?13708>
_______________________________________________
Message sent via/by Gna!
http://gna.org/
_______________________________________________
Freeciv-dev mailing list
[email protected]
https://mail.gna.org/listinfo/freeciv-dev