Commit eb0ab768 authored by Marcus Meissner's avatar Marcus Meissner Committed by Alexandre Julliard

Made checks in _get_common_ancestor a bit stricter to avoid XQueryTree

XErrors.
parent 87e4dbfd
......@@ -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 )
{
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment