aboutsummaryrefslogtreecommitdiff
path: root/nx-X11/programs/Xserver/hw/nxagent/Window.c
diff options
context:
space:
mode:
Diffstat (limited to 'nx-X11/programs/Xserver/hw/nxagent/Window.c')
-rw-r--r--nx-X11/programs/Xserver/hw/nxagent/Window.c15
1 files changed, 6 insertions, 9 deletions
diff --git a/nx-X11/programs/Xserver/hw/nxagent/Window.c b/nx-X11/programs/Xserver/hw/nxagent/Window.c
index 2fa6bc136..1cad4ca03 100644
--- a/nx-X11/programs/Xserver/hw/nxagent/Window.c
+++ b/nx-X11/programs/Xserver/hw/nxagent/Window.c
@@ -1454,9 +1454,8 @@ void nxagentConfigureWindow(WindowPtr pWin, unsigned int mask)
{
Window root_return;
Window parent_return;
- Window *children_return;
+ Window *children_return = NULL;
unsigned int nchildren_return;
- Window *pw;
Status result;
result = XQueryTree(nxagentDisplay, DefaultRootWindow(nxagentDisplay),
@@ -1464,8 +1463,6 @@ void nxagentConfigureWindow(WindowPtr pWin, unsigned int mask)
if (result)
{
- pw = children_return;
-
fprintf(stderr, "nxagentConfigureWindow: Children of the root: ");
while(nchildren_return > 0)
{
@@ -1476,16 +1473,16 @@ void nxagentConfigureWindow(WindowPtr pWin, unsigned int mask)
}
}
fprintf(stderr, "\n");
-
- if (children_return)
- {
- XFree(children_return);
- }
}
else
{
fprintf(stderr, "nxagentConfigureWindow: Failed QueryTree request.\n ");
}
+
+ if (children_return)
+ {
+ XFree(children_return);
+ }
}
#endif
}