diff options
author | Ulrich Sibiller <uli42@gmx.de> | 2019-05-03 19:18:20 +0200 |
---|---|---|
committer | Mike Gabriel <mike.gabriel@das-netzwerkteam.de> | 2019-11-02 11:30:36 +0100 |
commit | c02ab70efa7b9927b8459495a5ee11f50b17667c (patch) | |
tree | a7b09614d89313454f6359e642c5699a4bee681d | |
parent | 718a58fb15e61e9aea117035527ca3c882ec054d (diff) | |
download | nx-libs-c02ab70efa7b9927b8459495a5ee11f50b17667c.tar.gz nx-libs-c02ab70efa7b9927b8459495a5ee11f50b17667c.tar.bz2 nx-libs-c02ab70efa7b9927b8459495a5ee11f50b17667c.zip |
NXdispatch.c: Simplify InitSelections()
by calling upstream version from dispatch.c
-rw-r--r-- | nx-X11/programs/Xserver/dix/dispatch.c | 8 | ||||
-rw-r--r-- | nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c | 8 |
2 files changed, 7 insertions, 9 deletions
diff --git a/nx-X11/programs/Xserver/dix/dispatch.c b/nx-X11/programs/Xserver/dix/dispatch.c index f80cec0dd..0d4a80e2c 100644 --- a/nx-X11/programs/Xserver/dix/dispatch.c +++ b/nx-X11/programs/Xserver/dix/dispatch.c @@ -213,16 +213,18 @@ UpdateCurrentTimeIf() currentTime = systime; } -#ifndef NXAGENT_SERVER void -InitSelections() +#ifdef NXAGENT_SERVER +xorg_InitSelections(void) +#else +InitSelections(void) +#endif { if (CurrentSelections) free(CurrentSelections); CurrentSelections = (Selection *)NULL; NumCurrentSelections = 0; } -#endif /* NXAGENT_SERVER */ #undef SMART_DEBUG diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c b/nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c index 4a9ae73ae..9e365f372 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c @@ -203,12 +203,9 @@ extern int nxagentMaxSelections; extern int nxOpenFont(ClientPtr, XID, Mask, unsigned, char*); void -InitSelections() +InitSelections(void) { - if (CurrentSelections) - free(CurrentSelections); - CurrentSelections = (Selection *)NULL; - NumCurrentSelections = 0; + xorg_InitSelections(); #ifdef NXAGENT_CLIPBOARD { @@ -232,7 +229,6 @@ InitSelections() CurrentSelections[nxagentClipboardSelection].client = NullClient; } #endif - } #define MAJOROP ((xReq *)client->requestBuffer)->reqType |