From Bryan Thrall, "The OpenFlight plugin doesn't handle unrecognized options or extra

whitespace in all cases, causing it to crash."
This commit is contained in:
Robert Osfield
2009-07-01 15:39:48 +00:00
parent 4dfa7485c1
commit 21f735d653

View File

@@ -163,6 +163,12 @@ ExportOptions::parseOptionsString()
setStripTextureFilePath( true );
continue;
}
// Protect against unrecognized options without values
if ( pos == str.npos )
{
osg::notify( osg::WARN ) << "fltexp: Bogus OptionString: " << token << std::endl;
continue;
}
// Not a Boolean/toggle. Must have a value.
// Get the value of the token, which could be double-quoted.