branch: scratch/hyperbole
commit fd3f79a9ee64a48eee3cd7601013e02da17a12ce
Author: Stefan Monnier <monn...@iro.umontreal.ca>
Commit: Stefan Monnier <monn...@iro.umontreal.ca>

    * hargs.el (hargs:set-string-to-complete): Don't mess with windows
---
 hargs.el | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/hargs.el b/hargs.el
index f0178a1225..4cee338726 100644
--- a/hargs.el
+++ b/hargs.el
@@ -276,8 +276,7 @@ Optional DEFAULT-PROMPT is used to describe default value."
 
 (defun hargs:set-string-to-complete ()
   "Store the current minibuffer contents into `hargs:string-to-complete'."
-  (save-window-excursion
-    (set-buffer (window-buffer (minibuffer-window)))
+  (with-current-buffer (window-buffer (minibuffer-window))
     (setq hargs:string-to-complete (minibuffer-contents-no-properties))
     (when (equal hargs:string-to-complete "")
       (setq hargs:string-to-complete nil))))

Reply via email to