Only apply last change to the clipboard

* lisp/select.el (gui--selection-value-internal): Only return
nil if we own the clipboard.
This commit is contained in:
Po Lu 2022-02-01 10:13:15 +08:00
parent 16174d796f
commit 99c637499e

View file

@ -173,6 +173,7 @@ decoded. If `gui-get-selection' signals an error, return nil."
(unless (and (memq window-system '(x haiku))
;; gui-backend-selection-p might be unreliable on other
;; window systems.
(eq type 'CLIPBOARD)
(gui-backend-selection-owner-p type))
(let ((request-type (if (memq window-system '(x pgtk))
(or x-select-request-type