From f99408f25415ba7f05cb59a3367e5482883c76fe Mon Sep 17 00:00:00 2001 From: Robert Osfield Date: Wed, 6 Jul 2016 20:34:41 +0100 Subject: [PATCH] Fixed possible memory leak --- src/osgPlugins/osgjs/WriteVisitor | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/osgPlugins/osgjs/WriteVisitor b/src/osgPlugins/osgjs/WriteVisitor index a129fcbff..7f92ca5b7 100644 --- a/src/osgPlugins/osgjs/WriteVisitor +++ b/src/osgPlugins/osgjs/WriteVisitor @@ -598,7 +598,7 @@ public: osg::ref_ptr json = new JSONNode; osg::Vec3 min(0,0,0), max(0,0,0); - JSONObject *bboxData = new JSONObject; + osg::ref_ptr bboxData = new JSONObject; bool hasBoundindBox = ( node.getUserValue("AABBonBone_min", min) && node.getUserValue("AABBonBone_max", max) ); if (hasBoundindBox) {