summaryrefslogtreecommitdiff
path: root/lisp
diff options
context:
space:
mode:
Diffstat (limited to 'lisp')
-rw-r--r--lisp/uniquify.el3
1 files changed, 2 insertions, 1 deletions
diff --git a/lisp/uniquify.el b/lisp/uniquify.el
index 495d893baf0..3bf889f0996 100644
--- a/lisp/uniquify.el
+++ b/lisp/uniquify.el
@@ -147,7 +147,8 @@ pathname elements. Arguments cause only a subset of buffers to be renamed."
(while buffers
(let* ((buffer (car buffers))
(bfn (if (eq buffer newbuf)
- (expand-file-name newbuffile)
+ (and newbuffile
+ (expand-file-name newbuffile))
(uniquify-buffer-file-name buffer)))
(rawname (and bfn (file-name-nondirectory bfn)))
(deserving (and rawname