diff options
author | hobbs <hobbs> | 2002-04-12 07:31:20 (GMT) |
---|---|---|
committer | hobbs <hobbs> | 2002-04-12 07:31:20 (GMT) |
commit | 8059f11608e8cef03fb9e8c72ecba88471abf6b7 (patch) | |
tree | 9790a04692671822bebe733b277db8e8c862dab5 | |
parent | 8797c85dfecd39008c4be5c314d7acabd6fa5ad7 (diff) | |
download | tk-8059f11608e8cef03fb9e8c72ecba88471abf6b7.zip tk-8059f11608e8cef03fb9e8c72ecba88471abf6b7.tar.gz tk-8059f11608e8cef03fb9e8c72ecba88471abf6b7.tar.bz2 |
* mac/tkMacXStubs.c (TkpOpenDisplay): memset the initial display
structures to 0.
-rw-r--r-- | mac/tkMacXStubs.c | 4 |
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; } |