diff options
| -rw-r--r-- | lisp/textmodes/makeinfo.el | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/lisp/textmodes/makeinfo.el b/lisp/textmodes/makeinfo.el index 9370ee80894..b4857e0d143 100644 --- a/lisp/textmodes/makeinfo.el +++ b/lisp/textmodes/makeinfo.el | |||
| @@ -193,10 +193,14 @@ command to gain use of `next-error'." | |||
| 193 | (if (and makeinfo-temp-file (file-exists-p makeinfo-temp-file)) | 193 | (if (and makeinfo-temp-file (file-exists-p makeinfo-temp-file)) |
| 194 | (delete-file makeinfo-temp-file)) | 194 | (delete-file makeinfo-temp-file)) |
| 195 | ;; Always use the version on disk. | 195 | ;; Always use the version on disk. |
| 196 | (if (get-file-buffer makeinfo-output-file-name) | 196 | (let ((buffer (get-file-buffer makeinfo-output-file-name))) |
| 197 | (progn (set-buffer makeinfo-output-file-name) | 197 | (if buffer |
| 198 | (revert-buffer t t)) | 198 | (with-current-buffer buffer |
| 199 | (find-file makeinfo-output-file-name)) | 199 | (revert-buffer t t)) |
| 200 | (setq buffer (find-file-noselect makeinfo-output-file-name))) | ||
| 201 | (if (window-dedicated-p (selected-window)) | ||
| 202 | (switch-to-buffer-other-window buffer) | ||
| 203 | (switch-to-buffer buffer))) | ||
| 200 | (goto-char (point-min))) | 204 | (goto-char (point-min))) |
| 201 | 205 | ||
| 202 | (defun makeinfo-buffer () | 206 | (defun makeinfo-buffer () |