Observers savegame contains no minimap.

Bug #1228811 reported by Teppo Mäenpää
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
widelands
Fix Released
Medium
Unassigned

Bug Description

I faced a similar segv ( null pointer dereference at mapview.h:66) twice, once with widelands over gdb and the over valgrind.
Traces attached. Unfortunately I do cannot look at this now, maybe somebody wants?

The game was a 3-party LAN play, with server (the one who crashes) as observer.

Tags: crash

Related branches

Revision history for this message
Teppo Mäenpää (kxq) wrote :
SirVer (sirver)
Changed in widelands:
status: New → Fix Committed
milestone: none → build18-rc1
importance: Undecided → High
importance: High → Medium
status: Fix Committed → Triaged
summary: - segmentation fault in trunk/6776
+ Observers savegame contains no minimap.
Revision history for this message
SirVer (sirver) wrote :

Great that you where running in gdb! My respect for this awareness.

The problem was that there is no interactive player for writing a minimap with. I think I fixed the coredume issue in r6779. This is not a really proper fix, as there should be a minimap written for an observer too, but my fix is minimal invasive according to the feature freeze rules. I target for b19 for a proper fix.

Could you check if the coredump is indeed fixed?

Changed in widelands:
milestone: build18-rc1 → build19-rc1
Revision history for this message
Teppo Mäenpää (kxq) wrote :

No, It does not crash anymore. Thanks for the quick fix. I guess that we would have found this one during the tournament.

Normally I don't run over gdb. For the purpose of LAN play, I had to power up my desktop computer that can do it, and chose to benefit from the opportunity.

There might still be something ugly in saving (Map_Port_Spaces_Data_Packet::Write, see attachment). No crashes, though.

Revision history for this message
SirVer (sirver) wrote :

> No, It does not crash anymore. Thanks for the quick fix. I guess that we would have found this one during the tournament.

not sure about that. I think most people play in OpenGL mode these days anyway.

> There might still be something ugly in saving (Map_Port_Spaces_Data_Packet::Write, see attachment). No crashes, though.

There was some code there that copied a set and then conditionally deleted from it in a BOOST_FOREACH. I am not sure if this is valid - I did not find any documentation about it. But it feels funky to delete an element while iterating over a container. Instead I changed the code to not copy the set and delete, but instead starting with an empty set and inserting the values we really want to have.

This fix is slightly more invasive that I would have liked it to be, but seems still save enough.

Revision history for this message
_aD (ad-simplypeachy) wrote :

Tagging as workaround as per comment 2.

tags: added: workaround
Revision history for this message
SirVer (sirver) wrote :

Setting to incomplete for bug sweeping.

Changed in widelands:
status: Triaged → Incomplete
GunChleoc (gunchleoc)
Changed in widelands:
status: Incomplete → In Progress
assignee: nobody → GunChleoc (gunchleoc)
GunChleoc (gunchleoc)
Changed in widelands:
status: In Progress → Fix Committed
assignee: GunChleoc (gunchleoc) → nobody
GunChleoc (gunchleoc)
tags: added: crash
removed: workaround
GunChleoc (gunchleoc)
Changed in widelands:
status: Fix Committed → Fix Released
Revision history for this message
GunChleoc (gunchleoc) wrote :

Fixed in build19-rc1.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.