From d4021fd9f9d64d7dd9880178065678cee779e4ec Mon Sep 17 00:00:00 2001 From: Gerd Moellmann Date: Tue, 8 Aug 2000 18:30:21 +0000 Subject: [PATCH] (ffap-read-file-or-url-internal): Handle case the DIR or STRING are nil. --- lisp/ffap.el | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lisp/ffap.el b/lisp/ffap.el index 37ce6679457..22fef574a6e 100644 --- a/lisp/ffap.el +++ b/lisp/ffap.el @@ -1216,6 +1216,10 @@ which may actually result in an url rather than a filename." (t t)))) (defun ffap-read-file-or-url-internal (string dir action) + (unless dir + (setq dir default-directory)) + (unless string + (setq string default-directory)) (if (ffap-url-p string) (ffap-read-url-internal string dir action) (read-file-name-internal string dir action))) -- 2.39.2