template inline void DeleteSTLContainer(container& c) { for (container::iterator it = c.begin(); it!=c.end(); ++it) { delete *it; *it = NULL; } } template inline void DeleteSTLMap(map& m) { for (map::iterator it = m.begin(); it!=m.end(); ++it) { delete it->second; it->second = NULL; } }