diff options
author | Juanma Barranquero <lekktu@gmail.com> | 2008-02-27 16:39:09 +0000 |
---|---|---|
committer | Juanma Barranquero <lekktu@gmail.com> | 2008-02-27 16:39:09 +0000 |
commit | a797f3dc57d0e203cd35291ef193c69380771183 (patch) | |
tree | bd3c1bee11d6187abae2fd55c11ff13a2f3f6f10 /lisp/uniquify.el | |
parent | 9cdd0429a3d66391f1e060980772d5577669300e (diff) | |
download | emacs-a797f3dc57d0e203cd35291ef193c69380771183.tar.gz |
(uniquify-buffer-base-name): If the base name is an empty
string, return nil to allow the caller to default to the
buffer name. Reported by Martin Fischer <parozusa@web.de>.
Diffstat (limited to 'lisp/uniquify.el')
-rw-r--r-- | lisp/uniquify.el | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/lisp/uniquify.el b/lisp/uniquify.el index 802f18c3753..c316a47fbf8 100644 --- a/lisp/uniquify.el +++ b/lisp/uniquify.el @@ -194,9 +194,11 @@ It actually holds the list of `uniquify-item's corresponding to the conflict.") ;; Used in desktop.el to save the non-uniquified buffer name (defun uniquify-buffer-base-name () "Return the base name of the current buffer. -Return nil if the buffer is not managed by uniquify." +Return nil if the buffer is not managed by uniquify, +or if the base name is empty." (and uniquify-managed - (uniquify-item-base (car uniquify-managed)))) + (let ((base (uniquify-item-base (car uniquify-managed)))) + (if (string= base "") nil base)))) ;;; Main entry point. |