[commit] r1767 - trunk/GME/Meta

GMESRC Repository Notifications gme-commit at list.isis.vanderbilt.edu
Wed Jan 4 14:35:14 CST 2012


Author: ksmyth
Date: Wed Jan  4 14:35:14 2012
New Revision: 1767

Log:
Fix broken assumptions under GC environs

Modified:
   trunk/GME/Meta/MgaMetaProject.cpp

Modified: trunk/GME/Meta/MgaMetaProject.cpp
==============================================================================
--- trunk/GME/Meta/MgaMetaProject.cpp	Wed Jan  4 14:35:02 2012	(r1766)
+++ trunk/GME/Meta/MgaMetaProject.cpp	Wed Jan  4 14:35:14 2012	(r1767)
@@ -387,6 +387,9 @@
 void CMgaMetaProject::UnregisterMetaBase(metaref_type metaref, IMgaMetaBase *obj)
 {
 	ASSERT( obj != NULL );
+	// Under GC, we may be here via ~CMgaMetaBase after Close clear()s the map
+	if (metaobj_lookup.size() == 0)
+		return;
 	ASSERT( metaobj_lookup.find(metaref) != metaobj_lookup.end() );
 	ASSERT( metaobj_lookup[metaref] == obj );
 


More information about the gme-commit mailing list