Skip to content

Handle ICCCM TIMESTAMP selection target#167

Open
tricktron wants to merge 1 commit intoastrand:masterfrom
tricktron:fix/icccm-timestamp-target
Open

Handle ICCCM TIMESTAMP selection target#167
tricktron wants to merge 1 commit intoastrand:masterfrom
tricktron:fix/icccm-timestamp-target

Conversation

@tricktron
Copy link
Copy Markdown

Summary

Fixes #90
Fixes #92
Fixes #163

xclip was silently failing clipboard transfers for X11 consumers (VMware vmtoolsd, Citrix ICA, rdesktop) that send TIMESTAMP target requests. This adds proper ICCCM TIMESTAMP support: real server timestamp acquisition via PropertyNotify and correct TIMESTAMP target responses.

Testing

  • xclip -o -t TARGETS includes TIMESTAMP when xclip owns a selection
  • xclip -o -t TIMESTAMP returns a positive integer, not raw clipboard data
  • Manually verified e2e on VMware Workstation Windows Host with Linux Guest by copy-pasting from Linux Guest -> Windows Host via vmtoolsd.

Respond to TIMESTAMP target requests with the real selection ownership
timestamp as XA_INTEGER, and advertise TIMESTAMP in the TARGETS list.

Acquire a real X server timestamp via zero-length property append and
PropertyNotify instead of using CurrentTime in XSetSelectionOwner,
fixing the ICCCM §2.1 violation noted in the existing FIXME comment.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

1 participant