Fix some issues reported by deronj:

- Hopefully fix a crash in compCheckRedirect on unrealizing windows.
- Remove an extern that doesn't point at anything.
This commit is contained in:
Eric Anholt 2004-08-12 07:57:03 +00:00
parent 1a073786e0
commit 789cf3ed84
2 changed files with 4 additions and 3 deletions

View File

@ -75,8 +75,6 @@ typedef struct _CompSubwindows {
CompClientWindowPtr clients;
} CompSubwindowsRec, *CompSubwindowsPtr;
extern int CompPixmapPrivateIndex;
#define NUM_COMP_ALTERNATE_VISUALS 2
typedef struct _CompScreen {

View File

@ -103,7 +103,10 @@ Bool
compCheckRedirect (WindowPtr pWin)
{
CompWindowPtr cw = GetCompWindow (pWin);
Bool should = pWin->viewable && (cw != NULL);
Bool should;
should = pWin->realized && (pWin->drawable.class != InputOnly) &&
(cw != NULL);
if (should != pWin->redirectDraw)
{