From 06cd24698e0b04b9d1f3292af4517f33c5f3767b Mon Sep 17 00:00:00 2001 From: Po Lu Date: Fri, 1 Jul 2022 16:32:37 +0800 Subject: [PATCH] Expand file names read from XDS functions * lisp/x-dnd.el (x-dnd-handle-xds-drop): Expand file names before use. Some GUI dialogs read un-expanded file names. --- lisp/x-dnd.el | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/lisp/x-dnd.el b/lisp/x-dnd.el index efd774f4e94..d78f926ee7a 100644 --- a/lisp/x-dnd.el +++ b/lisp/x-dnd.el @@ -1369,8 +1369,9 @@ VERSION is the version of the XDND protocol understood by SOURCE." desired-name (or file-name-coding-system default-file-name-coding-system))) - (setq save-to (funcall x-dnd-direct-save-function - t desired-name)) + (setq save-to (expand-file-name + (funcall x-dnd-direct-save-function + t desired-name))) (when save-to (with-selected-window window (let ((uri (format "file://%s%s" (system-name) save-to))) -- 2.39.5