ispell.el: Fix ispell personal dictionary name expansion.
authorAgustín Martín <agustin.martin@hispalinux.es>
Mon, 3 Dec 2012 16:08:23 +0000 (17:08 +0100)
committerAgustín Martín <agustin.martin@hispalinux.es>
Mon, 3 Dec 2012 16:08:23 +0000 (17:08 +0100)
textmodes/ispell.el (ispell-init-process, ispell-start-process):
Make sure ispell personal dictionary name is expanded after initial
`default-directory' value (Bug#13019).

lisp/ChangeLog
lisp/textmodes/ispell.el

index 99038a4..89c1044 100644 (file)
@@ -1,3 +1,9 @@
+2012-12-03  Agustín Martín Domingo  <agustin.martin@hispalinux.es>
+
+       * textmodes/ispell.el (ispell-init-process)
+       (ispell-start-process): Make sure personal dictionary name is
+       expanded after initial `default-directory' value (Bug#13019).
+
 2012-12-03  Jay Belanger  <jay.p.belanger@gmail.com>
 
        * calc/calc-forms.el (math-date-to-iso-dt): Fix weekday number.
index f667525..81468fa 100644 (file)
@@ -2669,7 +2669,8 @@ Keeps argument list for future Ispell invocations for no async support."
            orig-args
            (if ispell-current-personal-dictionary ; Use specified pers dict.
                (list "-p"
-                     (expand-file-name ispell-current-personal-dictionary)))
+                     (expand-file-name ispell-current-personal-dictionary
+                                      current-ispell-directory)))
            ;; If we are using recent aspell or hunspell, make sure we use the
            ;; right encoding for communication. ispell or older aspell/hunspell
            ;; does not support this.
@@ -2706,6 +2707,9 @@ Keeps argument list for future Ispell invocations for no async support."
   (let* (;; Basename of dictionary used by the spell-checker
         (dict-bname (or (car (cdr (member "-d" (ispell-get-ispell-args))))
                         ispell-current-dictionary))
+        ;; The directory where process was started.
+        (current-ispell-directory default-directory)
+        ;; The default directory for the process.
         ;; Use "~/" as default-directory unless using Ispell with per-dir
         ;; personal dictionaries and not in a minibuffer under XEmacs
         (default-directory