From 842cc0e68511fa2654b34cd19e58762f46c61257 Mon Sep 17 00:00:00 2001 From: Andreas Schwab Date: Fri, 30 Oct 1998 11:02:42 +0000 Subject: [PATCH] (sh-canonicalize-shell): Fix regexp. (sh-set-shell): Likewise. --- lisp/progmodes/sh-script.el | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lisp/progmodes/sh-script.el b/lisp/progmodes/sh-script.el index 53e9d6ab151..ded6d4b8eab 100644 --- a/lisp/progmodes/sh-script.el +++ b/lisp/progmodes/sh-script.el @@ -195,7 +195,7 @@ the car and cdr are the same symbol.") (defun sh-canonicalize-shell (shell) "Convert a shell name SHELL to the one we should handle it as." - (if (string-match "\.exe\\'" shell) + (if (string-match "\\.exe\\'" shell) (setq shell (substring shell 0 (match-beginning 0)))) (or (symbolp shell) (setq shell (intern shell))) @@ -840,7 +840,7 @@ Calls the value of `sh-set-shell-hook' if set." (lambda (x) (eq (cdr x) 'sh-mode))) (eq executable-query 'function) t)) - (if (string-match "\.exe\\'" shell) + (if (string-match "\\.exe\\'" shell) (setq shell (substring shell 0 (match-beginning 0)))) (setq sh-shell (intern (file-name-nondirectory shell)) sh-shell (or (cdr (assq sh-shell sh-alias-alist)) -- 2.39.2