bugBattle for Wesnoth - Bugs: bug #21158, "gamemap" class doesn't...

Show feedback again

bug #21158: "gamemap" class doesn't handle empty files

Submitted by:  Andrius Silinskas <thunderstruck>
Submitted on:  Sun Sep 22 17:05:24 2013  
Category: BugSeverity: 2 - Minor
Priority: 5 - NormalItem Group:  None of the others
Status: NonePrivacy: Public
Assigned to: NoneOpen/Closed: Open
Release: 1.11.6+Operating System: All

Add a New Comment (Rich MarkupRich Markup):

You are not logged in

Please log in, so followups can be emailed to you.


Sat Mar 15 19:40:51 2014, comment #2:

>This seems to be introduced by rev 52641/d75e320e5aa4b801cb9d0f4ef6722e1d4f37635a

I don't think so. It should already have happened before that; the default I added (allow_invalid = true) just matches the previous behavior. I was working on the [replace_map] and [terrain_mask] callstacks only when fixing https://gna.org/bugs/?19018 and didn't consider the "mp create game" callstack, perhaps an invalid map should be disallowed as well or never be allowed. Then gamemap::read would likely throw the incorrect_map_format_error after catching a t_translation::error.

Anonymissimus <anonymissimus>
Project Member
Thu Mar 6 19:02:06 2014, comment #1:

This seems to be introduced by rev 52641/d75e320e5aa4b801cb9d0f4ef6722e1d4f37635a

Mark de Wever <mordante>
Project Member
Sun Sep 22 17:05:24 2013, original submission:

The gamemap class which is located in map.?pp should handle empty files by throwing "incorrect_map_format_error".

Currently, it still creates a gamemap object and thus "Create Game" window is not able to display a proper error message as with usual map formatting errors.

Andrius Silinskas <thunderstruck>
Project Member


(Note: upload size limit is set to 1024 kB, after insertion of the required escape characters.)

Attach File(s):

No files currently attached


Depends on the following items: None found

Items that depend on this one: None found


Carbon-Copy List
  • -unavailable- added by anonymissimus (Posted a comment)
  • -unavailable- added by mordante (Posted a comment)
  • -unavailable- added by thunderstruck (Submitted the item)

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.


    Error: not logged in



    Follow 2 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Sat Mar 15 19:42:32 2014anonymissimusAssigned toanonymissimus=>None
    Thu Mar 6 19:02:06 2014mordanteAssigned toNone=>anonymissimus
    Show feedback again

    Back to the top

    Powered by Savane 3.1-cleanup