aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKenichi Handa2006-08-09 01:11:44 +0000
committerKenichi Handa2006-08-09 01:11:44 +0000
commitdccee2cb1589448168edd0223256789b88f7f56f (patch)
tree0190d3712d4d0725a578069c458863e7c2627f22
parentd8a869ea1f67990b9f3bc4449769ebde073321ce (diff)
downloademacs-dccee2cb1589448168edd0223256789b88f7f56f.tar.gz
emacs-dccee2cb1589448168edd0223256789b88f7f56f.zip
(latexenc-find-file-coding-system):
Fix for the case that the 2nd element of arg-list is a cons.
-rw-r--r--lisp/international/latexenc.el10
1 files changed, 8 insertions, 2 deletions
diff --git a/lisp/international/latexenc.el b/lisp/international/latexenc.el
index 25d56c1e928..58e8d6c88e8 100644
--- a/lisp/international/latexenc.el
+++ b/lisp/international/latexenc.el
@@ -138,8 +138,14 @@ coding system names is determined from `latex-inputenc-coding-alist'."
138 ((and (require 'code-pages nil t) (coding-system-p sym)) sym) 138 ((and (require 'code-pages nil t) (coding-system-p sym)) sym)
139 (t 'undecided))) 139 (t 'undecided)))
140 ;; else try to find it in the master/main file 140 ;; else try to find it in the master/main file
141 (let ((default-directory (file-name-directory (nth 1 arg-list))) 141
142 latexenc-main-file) 142 ;; Fixme: If the current file is in an archive (e.g. tar,
143 ;; zip), we should find the master file in that archive.
144 ;; But, that is not yet implemented. -- K.Handa
145 (let ((default-directory (if (stringp (nth 1 arg-list))
146 (file-name-directory (nth 1 arg-list))
147 default-directory))
148 latexenc-main-file)
143 ;; Is there a TeX-master or tex-main-file in the local variables 149 ;; Is there a TeX-master or tex-main-file in the local variables
144 ;; section? 150 ;; section?
145 (unless latexenc-dont-use-TeX-master-flag 151 (unless latexenc-dont-use-TeX-master-flag