summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorhobbs <hobbs@noemail.net>2002-04-12 07:31:20 (GMT)
committerhobbs <hobbs@noemail.net>2002-04-12 07:31:20 (GMT)
commit9ac90e83a3942f12e5fa80659c9dc7bea9c9e2e5 (patch)
tree9790a04692671822bebe733b277db8e8c862dab5
parent4b3a8f98d0a00e34326b5cb00ebf3aa1afbc2238 (diff)
downloadtk-9ac90e83a3942f12e5fa80659c9dc7bea9c9e2e5.zip
tk-9ac90e83a3942f12e5fa80659c9dc7bea9c9e2e5.tar.gz
tk-9ac90e83a3942f12e5fa80659c9dc7bea9c9e2e5.tar.bz2
* mac/tkMacXStubs.c (TkpOpenDisplay): memset the initial display
structures to 0. FossilOrigin-Name: 7fa863499821db8885df5c2187d69382bcccd803
-rw-r--r--mac/tkMacXStubs.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/mac/tkMacXStubs.c b/mac/tkMacXStubs.c
index 26fe5ec..2e6b90a 100644
--- a/mac/tkMacXStubs.c
+++ b/mac/tkMacXStubs.c
@@ -11,7 +11,7 @@
* See the file "license.terms" for information on usage and redistribution
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tkMacXStubs.c,v 1.12 2002/04/05 08:37:52 hobbs Exp $
+ * RCS: @(#) $Id: tkMacXStubs.c,v 1.13 2002/04/12 07:31:20 hobbs Exp $
*/
#include "tkInt.h"
@@ -106,6 +106,7 @@ TkpOpenDisplay(
graphicsDevice = GetMainDevice();
display = (Display *) ckalloc(sizeof(Display));
+ memset(display, 0, sizeof(Display));
display->resource_alloc = MacXIdAlloc;
screen = (Screen *) ckalloc(sizeof(Screen) * 2);
display->default_screen = 0;
@@ -138,6 +139,7 @@ TkpOpenDisplay(
screen->root_visual->map_entries = 2 ^ 8;
gMacDisplay = (TkDisplay *) ckalloc(sizeof(TkDisplay));
+ memset(gMacDisplay, 0, sizeof(TkDisplay));
gMacDisplay->display = display;
return gMacDisplay;
}