From: James Turner Date: Fri, 6 Dec 2013 18:14:48 +0000 (+0000) Subject: Canvas: clear elements in shutdown() X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=3ec9c7ae6edf37a81a78dd435772f8788d72a692;p=simgear.git Canvas: clear elements in shutdown() - without this change, elements aren't un-ref-ed and hence destroyed until the actual dtor runs, which is too late (other systems may be destroyed already) --- diff --git a/simgear/props/PropertyBasedMgr.cxx b/simgear/props/PropertyBasedMgr.cxx index 621d11db..4091da9f 100644 --- a/simgear/props/PropertyBasedMgr.cxx +++ b/simgear/props/PropertyBasedMgr.cxx @@ -37,6 +37,7 @@ namespace simgear void PropertyBasedMgr::shutdown() { _props->removeChangeListener(this); + _elements.clear(); } //----------------------------------------------------------------------------