diff options
| author | Peter Hutterer <peter@cs.unisa.edu.au> | 2007-11-09 11:29:18 +1030 |
|---|---|---|
| committer | Peter Hutterer <peter@cs.unisa.edu.au> | 2007-11-09 14:31:41 +1030 |
| commit | cb75f09146a3c17b1a67b636bbf7229c65c83b35 (patch) | |
| tree | dff91f016ebacabeda8ac891fdb8e798503a5cf2 | |
| parent | 59b304d8a24fecd094296feb217823f0c73d6f82 (diff) | |
dix: calloc root window's Generic Event mask, stops segfaults.
| -rw-r--r-- | dix/window.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/dix/window.c b/dix/window.c index 23acbd63b..51891a88e 100644 --- a/dix/window.c +++ b/dix/window.c @@ -455,7 +455,12 @@ CreateRootWindow(ScreenPtr pScreen) #ifdef XINPUT pWin->optional->inputMasks = NULL; pWin->optional->deviceCursors = NULL; - pWin->optional->geMasks = NULL; + pWin->optional->geMasks = (GenericClientMasksPtr)xcalloc(1, sizeof(GenericClientMasksRec)); + if (!pWin->optional->geMasks) + { + xfree(pWin->optional); + return FALSE; + } #endif pWin->optional->access.perm = NULL; |
