aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTassilo Horn2008-04-14 11:02:31 +0000
committerTassilo Horn2008-04-14 11:02:31 +0000
commit3c03f2cef091f5fc2664248fb16074d2d95dde0f (patch)
treeb7e6e8e6c0651871b3f4dc7b88fe9a15baae46d9
parentdd7d19d7ce68900957eae8d93de0e144ca52dc88 (diff)
downloademacs-3c03f2cef091f5fc2664248fb16074d2d95dde0f.tar.gz
emacs-3c03f2cef091f5fc2664248fb16074d2d95dde0f.zip
(doc-view-start-process): Don't set
default-directory to "~/" if the current value is valid. This broke PS files that run other files in the same directory.
-rw-r--r--lisp/ChangeLog6
-rw-r--r--lisp/doc-view.el10
2 files changed, 12 insertions, 4 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index c9348ba7924..bd495063f65 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,9 @@
12008-04-14 Tassilo Horn <tassilo@member.fsf.org>
2
3 * doc-view.el (doc-view-start-process): Don't set
4 default-directory to "~/" if the current value is valid. This
5 broke PS files that run other files in the same directory.
6
12008-04-14 Dan Nicolaescu <dann@ics.uci.edu> 72008-04-14 Dan Nicolaescu <dann@ics.uci.edu>
2 8
3 * vc.el (vc-status-kill-query): New function. 9 * vc.el (vc-status-kill-query): New function.
diff --git a/lisp/doc-view.el b/lisp/doc-view.el
index dec372614b6..942e3521d27 100644
--- a/lisp/doc-view.el
+++ b/lisp/doc-view.el
@@ -559,9 +559,11 @@ Should be invoked when the cached images aren't up-to-date."
559 (funcall (process-get proc 'callback)))))) 559 (funcall (process-get proc 'callback))))))
560 560
561(defun doc-view-start-process (name program args callback) 561(defun doc-view-start-process (name program args callback)
562 ;; Make sure the process is started in an existing directory, 562 ;; Make sure the process is started in an existing directory, (rather than
563 ;; (rather than some file-name-handler-managed dir, for example). 563 ;; some file-name-handler-managed dir, for example).
564 (let* ((default-directory (expand-file-name "~/")) 564 (let* ((default-directory (if (file-readable-p default-directory)
565 default-directory
566 (expand-file-name "~/")))
565 (proc (apply 'start-process name doc-view-conversion-buffer 567 (proc (apply 'start-process name doc-view-conversion-buffer
566 program args))) 568 program args)))
567 (push proc doc-view-current-converter-processes) 569 (push proc doc-view-current-converter-processes)
@@ -585,7 +587,7 @@ Should be invoked when the cached images aren't up-to-date."
585 (list (format "-r%d" (round doc-view-resolution)) 587 (list (format "-r%d" (round doc-view-resolution))
586 (concat "-sOutputFile=" png) 588 (concat "-sOutputFile=" png)
587 pdf-ps)) 589 pdf-ps))
588 (lambda () 590 (lambda ()
589 (when doc-view-current-timer 591 (when doc-view-current-timer
590 (cancel-timer doc-view-current-timer) 592 (cancel-timer doc-view-current-timer)
591 (setq doc-view-current-timer nil)) 593 (setq doc-view-current-timer nil))