Fix indentation and use naIsNil to determine if _globals is nil
This commit is contained in:
parent
796acb9092
commit
0368e9a003
2 changed files with 5 additions and 5 deletions
|
@ -127,9 +127,9 @@ class ReplaceStaticTextureVisitor:
|
|||
simgear::EffectGeode* eg = dynamic_cast<simgear::EffectGeode*>(&node);
|
||||
if( !eg )
|
||||
return;
|
||||
simgear::Effect* eff = eg->getEffect();
|
||||
if (!eff)
|
||||
return;
|
||||
simgear::Effect* eff = eg->getEffect();
|
||||
if (!eff)
|
||||
return;
|
||||
osg::StateSet* ss = eff->getDefaultStateSet();
|
||||
if( !ss )
|
||||
return;
|
||||
|
|
|
@ -1165,8 +1165,8 @@ bool FGNasalSys::createModule(const char* moduleName, const char* fileName,
|
|||
naRef locals;
|
||||
naRef modname = naNewString(ctx);
|
||||
naStr_fromdata(modname, (char*)moduleName, strlen(moduleName));
|
||||
if (!((_globals).ref).ptr.obj)
|
||||
return false;
|
||||
if (naIsNil(_globals))
|
||||
return false;
|
||||
if (!naHash_get(_globals, modname, &locals))
|
||||
locals = naNewHash(ctx);
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue