URL:
  <http://gna.org/bugs/?17700>

                 Summary: auto_arrange_workers() memory leak
                 Project: Freeciv
            Submitted by: cazfi
            Submitted on: Fri 11 Feb 2011 02:12:42 AM EET
                Category: general
                Severity: 3 - Normal
                Priority: 5 - Normal
                  Status: Ready For Test
             Assigned to: None
        Originator Email: 
             Open/Closed: Open
                 Release: 
         Discussion Lock: Any
        Operating System: None
         Planned Release: 2.3.0, 2.4.0

    _______________________________________________________

Details:

Valgrind says:

==29695== 3,654 (3,120 direct, 534 indirect) bytes in 26 blocks are
definitely lost in loss record 1,059 of 1,077
==29695==    at 0x4C244E8: malloc (vg_replace_malloc.c:236)
==29695==    by 0x5B23F9: fc_real_malloc (in
/usr/freeciv/S2_3/src.valgrind/build/server/freeciv-server)
==29695==    by 0x5B2508: fc_real_calloc (in
/usr/freeciv/S2_3/src.valgrind/build/server/freeciv-server)
==29695==    by 0x5D07E2: cm_result_new (in
/usr/freeciv/S2_3/src.valgrind/build/server/freeciv-server)
==29695==    by 0x46DCC1: auto_arrange_workers (in
/usr/freeciv/S2_3/src.valgrind/build/server/freeciv-server)
==29695==    by 0x46C9D7: city_map_update_tile_direct (in
/usr/freeciv/S2_3/src.valgrind/build/server/freeciv-server)
==29695==    by 0x46CBDA: city_map_update_all (in
/usr/freeciv/S2_3/src.valgrind/build/server/freeciv-server)
==29695==    by 0x46DD15: auto_arrange_workers (in
/usr/freeciv/S2_3/src.valgrind/build/server/freeciv-server)
==29695==    by 0x46641B: city_thaw_workers (in
/usr/freeciv/S2_3/src.valgrind/build/server/freeciv-server)
==29695==    by 0x468B70: transfer_city (in
/usr/freeciv/S2_3/src.valgrind/build/server/freeciv-server)
==29695==    by 0x46A887: unit_enter_city (in
/usr/freeciv/S2_3/src.valgrind/build/server/freeciv-server)
==29695==    by 0x4274E2: unit_move_consequences (in
/usr/freeciv/S2_3/src.valgrind/build/server/freeciv-server)
==29695==    by 0x42820A: move_unit (in
/usr/freeciv/S2_3/src.valgrind/build/server/freeciv-server)
==29695==    by 0x4C89D6: unit_move_handling (in
/usr/freeciv/S2_3/src.valgrind/build/server/freeciv-server)
==29695==    by 0x42E4FC: ai_unit_attack (in
/usr/freeciv/S2_3/src.valgrind/build/server/freeciv-server)
==29695==    by 0x42E5BA: ai_unit_move_or_attack (in
/usr/freeciv/S2_3/src.valgrind/build/server/freeciv-server)
==29695==    by 0x4429A1: adv_unit_execute_path (in
/usr/freeciv/S2_3/src.valgrind/build/server/freeciv-server)
==29695==    by 0x4CC0E7: ai_military_rampage (in
/usr/freeciv/S2_3/src.valgrind/build/server/freeciv-server)
==29695==    by 0x4CF978: ai_military_attack (in
/usr/freeciv/S2_3/src.valgrind/build/server/freeciv-server)
==29695==    by 0x4D10E0: ai_manage_military (in
/usr/freeciv/S2_3/src.valgrind/build/server/freeciv-server)


I believe attached patch to fix this.



    _______________________________________________________

File Attachments:


-------------------------------------------------------
Date: Fri 11 Feb 2011 02:12:42 AM EET  Name: AAWLeakFix.diff  Size: 826B  
By: cazfi

<http://gna.org/bugs/download.php?file_id=12385>

    _______________________________________________________

Reply to this item at:

  <http://gna.org/bugs/?17700>

_______________________________________________
  Message sent via/by Gna!
  http://gna.org/


_______________________________________________
Freeciv-dev mailing list
Freeciv-dev@gna.org
https://mail.gna.org/listinfo/freeciv-dev

Reply via email to