diff options
author | Mike Gabriel <mike.gabriel@das-netzwerkteam.de> | 2021-02-03 14:46:20 +0100 |
---|---|---|
committer | Mike Gabriel <mike.gabriel@das-netzwerkteam.de> | 2021-02-03 14:46:20 +0100 |
commit | 770f468cd56cdd4c82bf4973a3505a3e8e4f01b4 (patch) | |
tree | ecdf41f1034fd1a851265d903be367875846fb1e /nx-X11/programs/Xserver/hw/nxagent/Window.c | |
parent | e5746df802eff5c50e46ef5ee96b3f0e34a00003 (diff) | |
parent | cbd9875e5ca3169d5aaa995e73ec1f67f29ca743 (diff) | |
download | nx-libs-770f468cd56cdd4c82bf4973a3505a3e8e4f01b4.tar.gz nx-libs-770f468cd56cdd4c82bf4973a3505a3e8e4f01b4.tar.bz2 nx-libs-770f468cd56cdd4c82bf4973a3505a3e8e4f01b4.zip |
Merge branch 'uli42-pr/windowfixes' into 3.6.x
Attributes GH PR #994: https://github.com/ArcticaProject/nx-libs/pull/994
Diffstat (limited to 'nx-X11/programs/Xserver/hw/nxagent/Window.c')
-rw-r--r-- | nx-X11/programs/Xserver/hw/nxagent/Window.c | 27 |
1 files changed, 15 insertions, 12 deletions
diff --git a/nx-X11/programs/Xserver/hw/nxagent/Window.c b/nx-X11/programs/Xserver/hw/nxagent/Window.c index d95f8f3ed..5f12fd48a 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Window.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Window.c @@ -80,8 +80,6 @@ int nxagentWindowPrivateIndex; */ int nxagentVisibility = VisibilityUnobscured; -unsigned long nxagentVisibilityTimeout = 0; -Bool nxagentVisibilityStop = False; ConfiguredWindowStruct *nxagentConfiguredWindowList; StaticResizedWindowStruct *nxagentStaticResizedWindowList; @@ -3089,10 +3087,15 @@ static void nxagentReconnectWindow(void * param0, XID param1, void * data_buffer #endif /* FIXME: use XAllocSizeHints() */ + /* FIXME: all this copying is only done because the first + element of the XSizeHints struct is a long which is of + different size on 32bit vs. 64bit platforms. We should + rewrite this to better readable and probably more robust + code */ #ifdef _XSERVER64 data64 = (unsigned char *) malloc(sizeof(XSizeHints) + 4); - if (data64) - { + if (data64) + { for (int i = 0; i < 4; i++) { *(data64 + i) = *(data + i); @@ -3106,18 +3109,18 @@ static void nxagentReconnectWindow(void * param0, XID param1, void * data_buffer } XSizeHints *props = (XSizeHints *) data64; - #else - XSizeHints *props = (XSizeHints *) data; - #endif /* _XSERVER64 */ - hints = *props; - } - else - { + } + else + { #ifdef WARNING fprintf(stderr, "%s: Failed to alloc memory for XSizeHints\n", __func__); #endif - } + } + #else + XSizeHints *props = (XSizeHints *) data; + hints = *props; + #endif /* _XSERVER64 */ } else { |