[PATCH] dix: Add null pointer check to prevent crash.
Rami Ylimaki
ext-rami.ylimaki at nokia.com
Thu Aug 6 03:35:39 PDT 2009
Signed-off-by: Rami Ylimaki <ext-rami.ylimaki at nokia.com>
---
dix/events.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/dix/events.c b/dix/events.c
index ec6aff7..448683f 100644
--- a/dix/events.c
+++ b/dix/events.c
@@ -5421,7 +5421,7 @@ DeleteWindowFromAnyEvents(WindowPtr pWin, Bool freeResources)
/* If the focus window is a root window (ie. has no parent) then don't
delete the focus from it. */
- if ((pWin == focus->win) && (pWin->parent != NullWindow))
+ if (focus && (pWin == focus->win) && (pWin->parent != NullWindow))
{
int focusEventMode = NotifyNormal;
--
1.6.0.4
More information about the xorg-devel
mailing list