Hi,
I'm not shure: is the blue version is correct/secure as the red one?
Thank you in advance!Code:pthread_mutex_lock(&mEntityTypeMapMutex);
std::map<int, std::string>::const_iterator resultCiter = EntityTypeMap.find(entity_se_id);
pthread_mutex_unlock(&mEntityTypeMapMutex);
if(resultCiter == mEntityTypeMap.end())
{
pthread_mutex_unlock(&mEntityTypeMapMutex);
}
else
{
pthread_mutex_unlock(&mEntityTypeMapMutex);
}