Corrected call of shell advised function so that it takes the new buffer argument.

Pascal J. Bourguignon [2021-05-30 15:15]
Corrected call of shell advised function so that it takes the new buffer argument.
Filename
pjb-shell.el
diff --git a/pjb-shell.el b/pjb-shell.el
index 418df20..bf5e8a2 100644
--- a/pjb-shell.el
+++ b/pjb-shell.el
@@ -45,7 +45,9 @@
   "Create a new shell when none exist, or switch to the last created one."
   (interactive "P")
   (if buffer
-      ad-do-it
+      (progn
+        (ad-set-args 0 (list buffer))
+        ad-do-it)
       (let ((i 0))
         (while (get-buffer (shell-buffer-name i))
           (setq i (1+ i)))
ViewGit