]> git.eshelyaron.com Git - emacs.git/commitdiff
* lisp/misearch.el (multi-isearch-push-state): Use proper closures
authorStefan Monnier <monnier@iro.umontreal.ca>
Tue, 18 May 2021 23:03:06 +0000 (19:03 -0400)
committerStefan Monnier <monnier@iro.umontreal.ca>
Tue, 18 May 2021 23:03:06 +0000 (19:03 -0400)
lisp/misearch.el

index 338880f25f25092f1e900d4a912129ab72c1bbb7..7f3e981bb0e92c30e062046025520f46935ccfaa 100644 (file)
@@ -202,8 +202,9 @@ the initial buffer."
   "Save a function restoring the state of multiple buffers search.
 Save the current buffer to the additional state parameter in the
 search status stack."
-  `(lambda (cmd)
-     (multi-isearch-pop-state cmd ,(current-buffer))))
+  (let ((buf (current-buffer)))
+    (lambda (cmd)
+      (multi-isearch-pop-state cmd buf))))
 
 (defun multi-isearch-pop-state (_cmd buffer)
   "Restore the multiple buffers search state in BUFFER.