diff dmd/codegen/Util.d @ 5:63623152e82a

Fixed memory corruption bug which was introduced when attempting to restore GC functionality
author dkoroskin <>
date Tue, 08 Dec 2009 21:39:17 +0300
parents d706d958e4e8
children fd4acc376c45
line wrap: on
line diff
--- a/dmd/codegen/Util.d	Mon Oct 26 16:28:19 2009 +0300
+++ b/dmd/codegen/Util.d	Tue Dec 08 21:39:17 2009 +0300
@@ -54,6 +54,7 @@
 
 import std.string;
 import core.stdc.string;
+import core.stdc.stdlib;
 
 import core.memory;
 
@@ -999,7 +1000,7 @@
 					es.Eoper = OPER.OPstring;
 
 					// Match MEM_PH_FREE for OPstring in ztc\el.c
-					es.EV.ss.Vstring = cast(char*)GC.malloc(len);	///
+					es.EV.ss.Vstring = cast(char*)malloc(len);	/// !
 					memcpy(es.EV.ss.Vstring, &e.EV, len);
 
 					es.EV.ss.Vstrlen = len;