aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAgustín Martín2009-01-05 17:45:53 +0000
committerAgustín Martín2009-01-05 17:45:53 +0000
commit0764ed3749c97bc7c18dab9dc63c6e395d348cb4 (patch)
treeac06f4df9e5d05fe8d812ce7b56bc5d80a169cde
parent638a245702c710dd80a2ea3b743b5afd10e1a740 (diff)
downloademacs-0764ed3749c97bc7c18dab9dc63c6e395d348cb4.tar.gz
emacs-0764ed3749c97bc7c18dab9dc63c6e395d348cb4.zip
textmodes/ispell.el (ispell-check-version): Use (with-temp-buffer)
-rw-r--r--lisp/ChangeLog6
-rw-r--r--lisp/textmodes/ispell.el14
2 files changed, 9 insertions, 11 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index 6bdc92cf23d..626d38963c9 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,6 +1,10 @@
12009-01-05 Agustín Martín <agustin.martin@hispalinux.es>
2
3 * textmodes/ispell.el (ispell-check-version): Use (with-temp-buffer)
4
12009-01-05 Richard M Stallman <rms@gnu.org> 52009-01-05 Richard M Stallman <rms@gnu.org>
2 6
3 * mail/sendmail.el (mail-bury): Treat pmail-mode like rmail-mode. 7 * mail/sendmail.el (mail-bury): Treat pmail-mode like rmail-mode.
4 8
52009-01-05 Martin Rudalics <rudalics@gmx.at> 92009-01-05 Martin Rudalics <rudalics@gmx.at>
6 10
diff --git a/lisp/textmodes/ispell.el b/lisp/textmodes/ispell.el
index 50aa643b585..23a75369b38 100644
--- a/lisp/textmodes/ispell.el
+++ b/lisp/textmodes/ispell.el
@@ -744,18 +744,14 @@ Otherwise returns the library directory name, if that is defined."
744 ;; all versions, since versions earlier than 3.0.09 didn't identify 744 ;; all versions, since versions earlier than 3.0.09 didn't identify
745 ;; themselves on startup. 745 ;; themselves on startup.
746 (interactive "p") 746 (interactive "p")
747 (let ((case-fold-search-val case-fold-search) 747 (let (;; avoid bugs when syntax of `.' changes in various default modes
748 ;; avoid bugs when syntax of `.' changes in various default modes
749 (default-major-mode 'fundamental-mode) 748 (default-major-mode 'fundamental-mode)
750 (default-directory (or (and (boundp 'temporary-file-directory) 749 (default-directory (or (and (boundp 'temporary-file-directory)
751 temporary-file-directory) 750 temporary-file-directory)
752 default-directory)) 751 default-directory))
753 result status ispell-program-version) 752 result status ispell-program-version)
754 (save-excursion 753
755 (let ((buf (get-buffer " *ispell-tmp*"))) 754 (with-temp-buffer
756 (if buf (kill-buffer buf)))
757 (set-buffer (get-buffer-create " *ispell-tmp*"))
758 (erase-buffer)
759 (setq status (ispell-call-process 755 (setq status (ispell-call-process
760 ispell-program-name nil t nil 756 ispell-program-name nil t nil
761 ;; aspell doesn't accept the -vv switch. 757 ;; aspell doesn't accept the -vv switch.
@@ -825,9 +821,7 @@ Otherwise returns the library directory name, if that is defined."
825 (setq ispell-really-aspell nil))) 821 (setq ispell-really-aspell nil)))
826 (ispell-really-hunspell 822 (ispell-really-hunspell
827 (or (ispell-check-minver hunspell8-minver ispell-really-hunspell) 823 (or (ispell-check-minver hunspell8-minver ispell-really-hunspell)
828 (setq ispell-really-hunspell nil))))) 824 (setq ispell-really-hunspell nil))))))
829
830 (kill-buffer (current-buffer)))
831 result)) 825 result))
832 826
833(defun ispell-call-process (&rest args) 827(defun ispell-call-process (&rest args)