From 8b981ab507bf7e940c9ed86f466c585f9258ffeb Mon Sep 17 00:00:00 2001 From: scrawl Date: Sun, 7 Feb 2016 05:53:42 -0800 Subject: [PATCH] Crash fix --- components/resource/scenemanager.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/components/resource/scenemanager.cpp b/components/resource/scenemanager.cpp index 4ed14241a..c2be3960f 100644 --- a/components/resource/scenemanager.cpp +++ b/components/resource/scenemanager.cpp @@ -200,7 +200,8 @@ namespace Resource for(unsigned int unit=0;unitgetTextureAttribute(unit, osg::StateAttribute::TEXTURE); - apply(texture); + if (texture) + apply(texture); } }