Fix UpdateOnceCallback crash (bug 1554/1556/1568)

(cherry picked from commit dc1816bb08)
This commit is contained in:
Rebecca N. Palmer
2015-01-18 21:29:19 +00:00
parent 2d00653f6e
commit 2931f3380f

View File

@@ -28,6 +28,9 @@ using namespace osg;
void UpdateOnceCallback::operator()(Node* node, NodeVisitor* nv)
{
ref_ptr<UpdateOnceCallback> prevent_premature_deletion=this;
// workaround for crash bug in OSG 3.2.1
// https://bugs.debian.org/765855
doUpdate(node, nv);
node->removeUpdateCallback(this);
// The callback could be deleted now.