summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorstanton <stanton>1998-09-30 23:57:18 (GMT)
committerstanton <stanton>1998-09-30 23:57:18 (GMT)
commit795fdacd5fc221eaf22ac51006fcf78064f51906 (patch)
tree3a192e58a55b2be4df770a8a3ce76ccd80f56633
parent06843a45602adb59486c6609bb3a2235cdb2b78a (diff)
downloadtcl-795fdacd5fc221eaf22ac51006fcf78064f51906.zip
tcl-795fdacd5fc221eaf22ac51006fcf78064f51906.tar.gz
tcl-795fdacd5fc221eaf22ac51006fcf78064f51906.tar.bz2
merged tcl8.0.4 changes to fix Windows memory allocation
-rw-r--r--win/tclWinPort.h13
1 files changed, 7 insertions, 6 deletions
diff --git a/win/tclWinPort.h b/win/tclWinPort.h
index c1659fc..faca7e7 100644
--- a/win/tclWinPort.h
+++ b/win/tclWinPort.h
@@ -10,7 +10,7 @@
* See the file "license.terms" for information on usage and redistribution
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tclWinPort.h,v 1.5 1998/09/14 18:40:20 stanton Exp $
+ * RCS: @(#) $Id: tclWinPort.h,v 1.6 1998/09/30 23:57:18 stanton Exp $
*/
#ifndef _TCLWINPORT
@@ -62,11 +62,12 @@
* use by tclAlloc.c.
*/
-#define TclpSysAlloc(size, isBin) ((void*)GlobalAlloc(GMEM_FIXED, \
- (DWORD)size))
-#define TclpSysFree(ptr) (GlobalFree((HGLOBAL)ptr))
-#define TclpSysRealloc(ptr, size) ((void*)GlobalReAlloc((HGLOBAL)ptr, \
- (DWORD)size, 0))
+#define TclpSysAlloc(size, isBin) ((void*)HeapAlloc(GetProcessHeap(), \
+ (DWORD)0, (DWORD)size))
+#define TclpSysFree(ptr) (HeapFree(GetProcessHeap(), \
+ (DWORD)0, (HGLOBAL)ptr))
+#define TclpSysRealloc(ptr, size) ((void*)HeapReAlloc(GetProcessHeap(), \
+ (DWORD)0, (LPVOID)ptr, (DWORD)size))
/*
* The default platform eol translation on Windows is TCL_TRANSLATE_CRLF: