[osg-users] OpenSceneGraph-3.6.1 release candidate 3 tagged

Robert Osfield robert.osfield at gmail.com
Fri May 11 01:06:41 PDT 2018

Hi Alberto,

Thanks for the minimal crashing program.  The crash wasn't straight
forward to pinpoint the cause but eventually I traced it back to the
the ObjectCache taking a ref_ptr<Options> when search for entries in
the ObjectCache.  To avoid this I wrote a ObjectCache::find(..) method
that doesn't create a temporary ref_ptr<> to the Options being passed
in.  This fix is checked in the OpenSceneGaprh-3.6 branch and master.


As a general comment use of C++11's auto is something you should be
careful about using, easy to hide the face that you just have C
pointers and associated memory leaks.


On 10 May 2018 at 21:20, Alberto Luaces <aluaces at udc.es> wrote:
> Hi, I think this issue was commented somewhere else, but I couldn't find
> it again: there is something broken with the cloning of osgDB::Options.
> This minimal working example works fine with 3.4.x, but SIGSEVs with
> 3.6.1-rc3 and current master:
> #include <osgDB/ReadFile>
> int main(){
>     auto globalopts = new osgDB::Options;
>         globalopts->setObjectCacheHint(osgDB::Options::CACHE_NODES);
>     // any.obj is not needed to get the crash.
>     auto *node = osgDB::readNodeFile("any.obj", globalopts);
> }
> --
> Alberto
> _______________________________________________
> osg-users mailing list
> osg-users at lists.openscenegraph.org
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

More information about the osg-users mailing list