From dc883b0577d475246d7c0f0c86795a327c6b97fa Mon Sep 17 00:00:00 2001 From: Robert Osfield Date: Tue, 28 May 2002 15:17:45 +0000 Subject: [PATCH] Fixed bug in the Use mechansim in Registry.cpp, sumbitted by Macro Jez. --- src/osgDB/Registry.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/osgDB/Registry.cpp b/src/osgDB/Registry.cpp index 0606fa182..21993acbe 100644 --- a/src/osgDB/Registry.cpp +++ b/src/osgDB/Registry.cpp @@ -308,8 +308,11 @@ osg::Object* Registry::readObjectOfType(const osg::Object& compObj,Input& fr) if (fr[1].isString()) { Object* obj = fr.getObjectForUniqueID(fr[1].getStr()); - if (compObj.isSameKindAs(obj)) fr+=2; - return obj; + if (compObj.isSameKindAs(obj)) + { + fr+=2; + return obj; + } } else return NULL;