Made checks in _get_common_ancestor a bit stricter to avoid XQueryTree

XErrors.
This commit is contained in:
Marcus Meissner 2001-04-30 18:16:51 +00:00 committed by Alexandre Julliard
parent 87e4dbfda8
commit eb0ab7681c
1 changed files with 3 additions and 3 deletions

View File

@ -514,13 +514,13 @@ static Window __get_common_ancestor( Window A, Window B,
Window root, *childrenB;
unsigned totalB;
do
while( A != B && A && B )
{
TSXQueryTree( display, A, &root, &A, children, total );
TSXQueryTree( display, B, &root, &B, &childrenB, &totalB );
if( childrenB ) TSXFree( childrenB );
if( *children ) TSXFree( *children ), *children = NULL;
} while( A != B && A && B );
}
if( A && B )
{