if (bCheckLinear && !aLCM->CheckLinear())
return;
//
- SHPHandle hSHPHandle;
+ SHPHandle hSHPHandle = NULL;
if ( !aLCM.IsNull() && !aLCM->IsEmpty())
{
hSHPHandle = SHPCreate( aFileName.toAscii().data(), SHPT_POLYGON );
aNonExpList.append(aLCM->GetName() + "_" + QString::number(It.Index()));
}
}
- if (hSHPHandle->nRecords > 0)
+ if (hSHPHandle && hSHPHandle->nRecords > 0)
SHPClose( hSHPHandle );
else
{