I have a std::map<std::string, myStruct>
. It's safe to return address of a myStruct
entry ?
I am sure that my entry will not be removed, but other entries can be added.
Type::iterator it = m_map.find(key);
if (it != m_map.end())
{
return &(it->second);
}