]> git.eshelyaron.com Git - emacs.git/commitdiff
(lookup-words): Cope with case where ARGS is empty.
authorRichard M. Stallman <rms@gnu.org>
Mon, 15 Aug 2005 01:37:41 +0000 (01:37 +0000)
committerRichard M. Stallman <rms@gnu.org>
Mon, 15 Aug 2005 01:37:41 +0000 (01:37 +0000)
lisp/textmodes/ispell.el

index 5afdf63ff2ab3975f3f9e3c10345f32ce3d5a3a1..173d5eb66b27dbad4e7fd295df9fa186cee92f64 100644 (file)
@@ -2150,9 +2150,13 @@ Optional second argument contains the dictionary to use; the default is
            (while (search-backward "*" nil t) (insert "."))
            (setq word (buffer-string))
            (erase-buffer))
-         (setq status (if lookup-dict
-                          (call-process prog nil t nil args word lookup-dict)
-                        (call-process prog nil t nil args word)))
+         (setq status (apply 'call-process prog nil t nil
+                             (nconc (if (and args (> (length args) 0))
+                                        (list args)
+                                      (if look-p nil
+                                        (list "-e")))
+                                    (list word)
+                                    (if lookup-dict (list lookup-dict)))))
          ;; grep returns status 1 and no output when word not found, which
          ;; is a perfectly normal thing.
          (if (stringp status)