[osg-users] Frequent crash in StateSet::removeParent

Cysneros, Nelson SPAWAR nelson.cysneros at navy.mil
Thu Oct 25 12:52:24 PDT 2007




Just a thought...

"The crash is caused because _parents.end() returns an iterator whose
container pointer is NULL."

Iterator end() returns interator positioned immediately after the last
item.  So if you want the the last item, you should be using something
like end()-1.

At least that's what it says in my cpp book.  I don't know if OSG is
different.



-----Original Message-----
From: osg-users-bounces at lists.openscenegraph.org
[mailto:osg-users-bounces at lists.openscenegraph.org] On Behalf Of
beelzebob999-osg at yahoo.com
Sent: Thursday, October 25, 2007 12:11 PM
To: OpenSceneGraph Users
Subject: [osg-users] Frequent crash in StateSet::removeParent


Hi... We are running OSG 2.0.0 on visual studio 2005, and we frequently
run into a crash in StateSet::removeParent. This is hit when we are
deleting nodes in the OSG thread (outside of calls to update and frame).
Is this a known issue? I am stumped on this one. I was just wondering if
it could be related to checked-iterator wierdness in VS2005, but that's
just a guess at this point. (The crash is caused because _parents.end()
returns an iterator whose container pointer is NULL.)
_______________________________________________
osg-users mailing list
osg-users at lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.or
g



More information about the osg-users mailing list