[cig-commits] r4156 - in long/3D/Gale/trunk/src/StGermain: .
Base/Foundation/src
walter at geodynamics.org
walter at geodynamics.org
Tue Aug 1 01:54:05 PDT 2006
Author: walter
Date: 2006-08-01 01:54:04 -0700 (Tue, 01 Aug 2006)
New Revision: 4156
Modified:
long/3D/Gale/trunk/src/StGermain/
long/3D/Gale/trunk/src/StGermain/Base/Foundation/src/shortcuts.h
Log:
r2617 at earth: boo | 2006-08-01 01:50:43 -0700
r2596 at earth (orig r3719): LukeHodkinson | 2006-07-26 22:15:56 -0700
Fixed a nasty memory leak occurring with 2D
arrays.
Property changes on: long/3D/Gale/trunk/src/StGermain
___________________________________________________________________
Name: svk:merge
- 1ef209d2-b310-0410-a72d-e20c9eb0015c:/cig:2616
afb6c753-b9d0-0310-b4e7-dbd8d91cdd35:/trunk/StGermain:3718
+ 1ef209d2-b310-0410-a72d-e20c9eb0015c:/cig:2617
afb6c753-b9d0-0310-b4e7-dbd8d91cdd35:/trunk/StGermain:3719
Modified: long/3D/Gale/trunk/src/StGermain/Base/Foundation/src/shortcuts.h
===================================================================
--- long/3D/Gale/trunk/src/StGermain/Base/Foundation/src/shortcuts.h 2006-08-01 08:54:01 UTC (rev 4155)
+++ long/3D/Gale/trunk/src/StGermain/Base/Foundation/src/shortcuts.h 2006-08-01 08:54:04 UTC (rev 4156)
@@ -63,6 +63,7 @@
Memory_Free( (ptr)[block_i] ); \
} \
} \
+ Memory_Free( ptr ); \
} \
} while( 0 )
@@ -85,6 +86,7 @@
Memory_Free( (ptr)[block_i] ); \
} \
} \
+ Memory_Free( ptr ); \
(ptr) = NULL; \
} \
} while( 0 )
@@ -112,5 +114,11 @@
own = NULL; \
} \
} while( 0 )
+
+#define FreeObject( obj ) \
+ if( obj ) Stg_Class_Delete( obj )
+
+#define KillObject( obj ) \
+ if( obj ) (Stg_Class_Delete( obj ), (obj) = NULL)
#endif /* __Base_Foundation_shortcuts_h__ */
More information about the cig-commits
mailing list