Commit 6c233cc0 authored by Gerd Moellmann's avatar Gerd Moellmann
Browse files

(executable-set-magic): If

executable-find returns a quoted file name, unquote it before
inserting it.
parent 1155d483
2001-08-07 Gerd Moellmann <gerd@gnu.org>
* progmodes/executable.el (executable-set-magic): If
executable-find returns a quoted file name, unquote it before
inserting it.
* image.el (image-type-regexps): For JPEG files, use a regexp
derived from the JPEG spec.
......
......@@ -210,13 +210,19 @@ executable."
(let* ((name (read-string "Name or file name of interpreter: "))
(arg (read-string (format "Argument for %s: " name))))
(list name arg (eq executable-query 'function) t)))
(setq interpreter (if (file-name-absolute-p interpreter)
interpreter
(or (executable-find interpreter)
(error "Interpreter %s not recognized" interpreter)))
argument (concat interpreter
(error "Interpreter %s not recognized"
interpreter))))
(setq argument (concat (if (string-match "\\`/:" interpreter)
(replace-match "" nil nil interpreter)
interpreter)
(and argument (string< "" argument) " ")
argument))
(or buffer-read-only
(if buffer-file-name
(string-match executable-magicless-file-regexp
......@@ -253,7 +259,7 @@ executable."
;;; (eq executable-insert t)
;;; (set-buffer-modified-p buffer-modified-p))
)))
interpreter)
interpreter)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment