[Freeciv-tickets] [freeciv] #47809: load_action_range_max() passing NULL as string

Back to archive index
OSDN Ticket System norep****@osdn*****
Mon Sep 18 10:54:41 JST 2023


#47809: load_action_range_max() passing NULL as string

  Open Date: 2023-04-08 18:35
Last Update: 2023-09-18 04:54

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

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

Last Changes/Comment on this Ticket:
2023-09-18 04:54 Updated by: cazfi

Comment:

The function is actually only called when there's var name, but this should still be refactored to avoid the duplicate call.

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

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

Ticket details:

load_action_range_max() handles all actions, including those for which action_max_range_ruleset_var_name() returns NULL. Yet it does 'secfile_entry_lookup(file, "actions.%s", action_max_range_ruleset_var_name(act));'
Haven't checked the other handling of other similar ruleset entries for actions. It's possible that this is a common bug-pattern.

-- 
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/47809
RSS feed for this Ticket:
    https://osdn.net/ticket/ticket_rss.php?group_id=12505&tid=47809



More information about the Freeciv-tickets mailing list
Back to archive index