From 04ca25eb1af9b3ea3eb94ceb851e0eda2a08b535 Mon Sep 17 00:00:00 2001 From: Ulrich Sibiller Date: Fri, 12 Feb 2021 22:50:47 +0100 Subject: Clipboard.c: fix some comments, add FIXME --- nx-X11/programs/Xserver/hw/nxagent/Clipboard.c | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) (limited to 'nx-X11') diff --git a/nx-X11/programs/Xserver/hw/nxagent/Clipboard.c b/nx-X11/programs/Xserver/hw/nxagent/Clipboard.c index ed46f3d6a..4c0c6d320 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Clipboard.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Clipboard.c @@ -1521,7 +1521,6 @@ static void transferSelectionFromXServer(int index, int resource) True: processed False: not processed, resource is not ours */ - Bool nxagentCollectPropertyEventFromXServer(int resource) { XlibAtom atomReturnType; @@ -2378,6 +2377,10 @@ int nxagentConvertSelection(ClientPtr client, WindowPtr pWin, Atom selection, * consider the conversion failed and tell our client about that. * The new request that lead us here is then processed. */ + #ifdef TEST + fprintf(stderr, "%s: lastClients[%d].windowPtr [0x%lx].\n", __func__, index, (unsigned long)lastClients[index].windowPtr); + #endif + if (lastClients[index].windowPtr != NULL) { #ifdef TEST @@ -2693,6 +2696,13 @@ int nxagentConvertSelection(ClientPtr client, WindowPtr pWin, Atom selection, XDeleteProperty(nxagentDisplay, serverWindow, remProperty); + /* + * FIXME: ICCCM states: "Clients should not use CurrentTime for the + * time argument of a ConvertSelection request. Instead, they should + * use the timestamp of the event that caused the request to be + * made." + */ + UpdateCurrentTime(); XConvertSelection(nxagentDisplay, remSelection, remTarget, remProperty, -- cgit v1.2.3