#45724: strvec_iterate() evaluating parameter multiple times, does repeated funcrtion calls Open Date: 2022-09-26 01:15 Last Update: 2022-09-26 01:15 URL for this Ticket: https://osdn.net//projects/freeciv/ticket/45724 RSS feed for this Ticket: https://osdn.net/ticket/ticket_rss.php?group_id=12505&tid=45724 --------------------------------------------------------------------- Last Changes/Comment on this Ticket: 2022-09-26 01:15 Updated by: cazfi * New Ticket "strvec_iterate() evaluating parameter multiple times, does repeated funcrtion calls" created --------------------------------------------------------------------- Ticket Status: Reporter: cazfi Owner: (None) Type: Bugs Status: Open Priority: 5 - Medium MileStone: (None) Component: General Severity: 5 - Medium Resolution: None --------------------------------------------------------------------- Ticket details: strvec_iterate() evaluates psv twice for each iteration, and does strvec_size() call on every iteration. Latter does partially protect against cases where someone shrinks the vector inside the iteration, but doesn't make it legal - iterator does would not follow backward such removals. -- 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/45724 RSS feed for this Ticket: https://osdn.net/ticket/ticket_rss.php?group_id=12505&tid=45724