PATCH: segfault in VRML2 plugin
The attached patch fixes a segfault in the VRML2 plugin which is caused by Shape entities with empty vertex lists.
This commit is contained in:
parent
e2d4118470
commit
47e2aab7de
|
@ -476,6 +476,15 @@ SGNODE* WRL2SHAPE::TranslateToSG( SGNODE* aParent )
|
|||
|
||||
SGNODE* pShape = shNode.GetRawPtr();
|
||||
SGNODE* pGeom = geometry->TranslateToSG( pShape );
|
||||
|
||||
if( NULL == pGeom )
|
||||
{
|
||||
// this can happen if a VRML file contains
|
||||
// empty point or index sets
|
||||
shNode.Destroy();
|
||||
return NULL;
|
||||
}
|
||||
|
||||
SGNODE* pApp = NULL;
|
||||
|
||||
if( NULL != appearance )
|
||||
|
|
Loading…
Reference in New Issue