URL: <http://gna.org/bugs/?25290>
Summary: Game crashes when exiting the loadingscreen îna unusual way Project: Battle for Wesnoth Submitted by: gfgtdf Submitted on: So 13 Nov 2016 01:13:10 UTC Category: Bug Severity: 4 - Important Priority: 5 - Normal Item Group: User Interface Status: None Privacy: Public Assigned to: None Originator Email: Open/Closed: Open Discussion Lock: Any Release: 1.13 Operating System: all _______________________________________________________ Details: I thought there was already a bugreport for this one but i couldn't find one. This was observed my multiple persons: when a the loadingscreen is exited by an exception (which for example when you close wesnoth during loadingscreen, but also if it closed becasue of a gui exception like 'dialog didn't fit on screen') the game sometimes crashes. What happens in this case is that the gui::tloadscreen object is destroed but the worker thread didn't finish yet and the mainthread just detaches the workingthread which obviously can cause crashes. There are at least 2 known approaches to fix this issue: 1) when exting during a loadingscreen by an exception we just call exit(), this should be rather easy to implement. 2) We try to exit the worker thread. Since just killing it coudl result in corrupt objects/memory, we'd need to add 'safe exit points' to the worker code e.g. calls to somethin like 'tloadscreen::maybe_throw_exit_thread_exception()'. Another problem with 2) is that it is afaik currently not possible to add 'quit callbacks' in gui2 dialogs (to overwrite the defautl bahviour of throwing CVideo::quit()) _______________________________________________________ Reply to this item at: <http://gna.org/bugs/?25290> _______________________________________________ Nachricht gesendet von/durch Gna! http://gna.org/ _______________________________________________ Wesnoth-bugs mailing list Wesnoth-bugs@gna.org https://mail.gna.org/listinfo/wesnoth-bugs