changeset 50054:a323f25ec045

(Man-getpage-in-background): Only change default-directory if necessary.
author Kai Großjohann <kgrossjo@eu.uu.net>
date Fri, 07 Mar 2003 21:04:54 +0000
parents b0e77003c980
children 9bef9ad3ccb4
files lisp/ChangeLog lisp/man.el
diffstat 2 files changed, 11 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/ChangeLog	Fri Mar 07 11:39:43 2003 +0000
+++ b/lisp/ChangeLog	Fri Mar 07 21:04:54 2003 +0000
@@ -1,3 +1,8 @@
+2003-03-07  Kai Gro,A_(Bjohann  <kai.grossjohann@uni-duisburg.de>
+
+	* man.el (Man-getpage-in-background): Only change
+	default-directory if necessary.
+
 2003-03-07  Andreas Schwab  <schwab@suse.de>
 
 	* info.el (Info-following-node-name): Skip trailing period.
--- a/lisp/man.el	Fri Mar 07 11:39:43 2003 +0000
+++ b/lisp/man.el	Fri Mar 07 21:04:54 2003 +0000
@@ -593,7 +593,12 @@
 	     (if default-enable-multibyte-characters
 		 locale-coding-system 'raw-text-unix))
 	    ;; Avoid possible error by using a directory that always exists.
-	    (default-directory "/"))
+	    (default-directory
+	      (if (and (file-directory-p default-directory)
+		       (not (find-file-name-handler default-directory
+						    'file-directory-p)))
+		  default-directory
+		"/")))
 	;; Prevent any attempt to use display terminal fanciness.
 	(setenv "TERM" "dumb")
 	;; In Debian Woody, at least, we get overlong lines under X