[Freeciv-tickets] [freeciv] #44879: end_turn() debug statistics cumulative, not per player

アーカイブの一覧に戻る
OSDN Ticket System norep****@osdn*****
Mon Jun 20 21:40:24 JST 2022


#44879: end_turn() debug statistics cumulative, not per player

  Open Date: 2022-06-20 15:40
Last Update: 2022-06-20 15:40

URL for this Ticket:
    https://osdn.net//projects/freeciv/ticket/44879
RSS feed for this Ticket:
    https://osdn.net/ticket/ticket_rss.php?group_id=12505&tid=44879

---------------------------------------------------------------------

Last Changes/Comment on this Ticket:
2022-06-20 15:40 Updated by: cazfi
 * New Ticket "end_turn() debug statistics cumulative, not per player" created


---------------------------------------------------------------------
Ticket Status:

      Reporter: cazfi
         Owner: (None)
          Type: Bugs
        Status: Open
      Priority: 5 - Medium
     MileStone: (None)
     Component: Server
      Severity: 5 - Medium
    Resolution: None
---------------------------------------------------------------------

Ticket details:

First of all the code in question causes compiler warning (with some compilers) when FREECIV_DEBUG is not defined - set of variables are only used in log_debug(), which expands to nothing without FREECIV_DEBUG, so otherwise those variables are "set but unused". This should be cleared also for optimization reasons, so that we don't calculate those unused stats.
Even if the log_debug() would show the stats, calculated ones are not per-player as one would assume from the player name and other player-specific ones. Those stats are zeroed only before iterating the players, not for each player, so they accumulate over players iterated.


-- 
Ticket information of Freeciv project
Freeciv Project is hosted on OSDN

Project URL: https://osdn.net/projects/freeciv/
OSDN: https://osdn.net

URL for this Ticket:
    https://osdn.net/projects/freeciv/ticket/44879
RSS feed for this Ticket:
    https://osdn.net/ticket/ticket_rss.php?group_id=12505&tid=44879



More information about the Freeciv-tickets mailing list
アーカイブの一覧に戻る