diff options
author | stanton <stanton> | 1998-09-30 23:58:16 (GMT) |
---|---|---|
committer | stanton <stanton> | 1998-09-30 23:58:16 (GMT) |
commit | deef9702e64f57f7a43eff7ecdb99fcbc594bc08 (patch) | |
tree | 562ecd5464ea2586b7306342d1a8866a1499b802 | |
parent | 2a91498d67de29934dee878b07b8967d817966fa (diff) | |
download | tcl-deef9702e64f57f7a43eff7ecdb99fcbc594bc08.zip tcl-deef9702e64f57f7a43eff7ecdb99fcbc594bc08.tar.gz tcl-deef9702e64f57f7a43eff7ecdb99fcbc594bc08.tar.bz2 |
merged tcl8.0.4 changes into 8.1 branch to fix Windows memory allocation
-rw-r--r-- | win/tclWinPort.h | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/win/tclWinPort.h b/win/tclWinPort.h index 18b4996..78ff4ac 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.1.2.2 1998/09/24 23:59:53 stanton Exp $ + * RCS: @(#) $Id: tclWinPort.h,v 1.1.2.3 1998/09/30 23:58:16 stanton Exp $ */ #ifndef _TCLWINPORT @@ -365,11 +365,12 @@ typedef float *TCHAR; * 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 following declarations belong in tclInt.h, but depend on platform |