Added handling of return value
This commit is contained in:
parent
5c25a3a0ea
commit
3999a16a1a
@ -797,7 +797,14 @@ bool Model::readOBJ(std::istream& fin, const osgDB::ReaderWriter::Options* optio
|
||||
{
|
||||
int smoothingGroup=0;
|
||||
if (strncmp(line+2,"off",3)==0) smoothingGroup = 0;
|
||||
else sscanf(line+2,"%d",&smoothingGroup);
|
||||
else
|
||||
{
|
||||
int result = sscanf(line+2,"%d",&smoothingGroup);
|
||||
if (result!=1)
|
||||
{
|
||||
OSG_NOTICE <<"*** error reading smoothing group ***"<<std::endl;
|
||||
}
|
||||
}
|
||||
|
||||
if (currentElementState.smoothingGroup != smoothingGroup)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user