[Commits] [wesnoth/wesnoth] 927b8a: Fixed crash caused by failing to remove an event h...
GitHub
noreply at github.com
Sun Aug 14 08:47:43 UTC 2016
Branch: refs/heads/master
Home: https://github.com/wesnoth/wesnoth
Commit: 927b8aa7d53453a6533b92d87a3e8af776ba8bda
https://github.com/wesnoth/wesnoth/commit/927b8aa7d53453a6533b92d87a3e8af776ba8bda
Author: Jyrki Vesterinen <sandgtx at gmail.com>
Date: 2016-08-14 (Sun, 14 Aug 2016)
Changed paths:
M src/events.cpp
Log Message:
-----------
Fixed crash caused by failing to remove an event handler
If code attempted to remove an event handler from an event context whose
all handlers were in the staging area (especially if that context was
freshly created and events::pump() hadn't been called since creating it),
the handler wasn't removed. This resulted in the handler remaining in the
context, but believing that it wasn't there. If the handler was later
destroyed, the event system still retained a pointer to it and attempted to
call handle_event() on it. Depending on the compiler, it could cause a
"pure virtual function call" error message.
More information about the Commits
mailing list