From 451a27ac65608be2b2492b23adf051bdf65b1b49 Mon Sep 17 00:00:00 2001 From: Robert Osfield Date: Thu, 17 Mar 2005 14:40:30 +0000 Subject: [PATCH] Added guard to texture image to avoid seg fault when dealing with incomplete databases. --- applications/osgconv/osgconv.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/applications/osgconv/osgconv.cpp b/applications/osgconv/osgconv.cpp index 16c0cef3b..7de1cc7d5 100644 --- a/applications/osgconv/osgconv.cpp +++ b/applications/osgconv/osgconv.cpp @@ -231,7 +231,7 @@ public: for (unsigned int im=0;imgetNumImages();++im) { osg::Image* image = texture->getImage(im); - if (image->isImageTranslucent()) hasTranslucentTexture = true; + if (image && image->isImageTranslucent()) hasTranslucentTexture = true; } } }