From: "Juanma Barranquero" <lekktu@gmail.com>
To: "Martin Fischer" <parozusa@web.de>
Cc: emacs-pretest-bug@gnu.org
Subject: Re: 22.1.90; desktop-save throws (error "No buffer named <uniquified buffername>")
Date: Fri, 8 Feb 2008 17:59:24 +0100 [thread overview]
Message-ID: <f7ccd24b0802080859q3ec1f508oae67e51fe6a7031c@mail.gmail.com> (raw)
In-Reply-To: <qkir12kqs0.fsf@nospam.net>
On Feb 6, 2008 5:12 PM, Martin Fischer <parozusa@web.de> wrote:
> Debugger entered--Lisp error: (error "No buffer named ludwig")
> desktop-save-buffer-p(nil "ludwig" dired-mode nil 185 (nil nil) t ("c:/otto/ludwig/") nil)
> apply(desktop-save-buffer-p (nil "ludwig" dired-mode nil 185 (nil nil) t ("c:/otto/ludwig/") nil))
> desktop-save("~/")
> call-interactively(desktop-save)
> execute-extended-command(nil)
> call-interactively(execute-extended-command)
Plese try the following patch. Is a bit of hackish, but doing it
cleanly would need more changes to desktop.el and perhaps changing the
desktop file version, which is a no-no during the pretest.
Juanma
Index: lisp/desktop.el
===================================================================
RCS file: /cvsroot/emacs/emacs/lisp/desktop.el,v
retrieving revision 1.108.2.6
diff -u -2 -r1.108.2.6 desktop.el
--- lisp/desktop.el 7 Jan 2008 02:44:57 -0000 1.108.2.6
+++ lisp/desktop.el 8 Feb 2008 16:46:43 -0000
@@ -654,9 +654,10 @@
(set-buffer buffer)
(list
+ ;; base name of the buffer; replaces the buffer name if managed by uniquify
+ (and (bound-and-true-p uniquify-managed)
+ (uniquify-item-base (car uniquify-managed)))
;; basic information
(desktop-file-name (buffer-file-name) desktop-dirname)
- (if (bound-and-true-p uniquify-managed)
- (uniquify-item-base (car uniquify-managed))
- (buffer-name))
+ (buffer-name)
major-mode
;; minor modes
@@ -887,5 +888,5 @@
(insert "\n;; Buffer section -- buffers listed in same order as in
buffer list:\n")
(dolist (l (mapcar 'desktop-buffer-info (buffer-list)))
- (when (apply 'desktop-save-buffer-p l)
+ (when (apply 'desktop-save-buffer-p (cdr l))
(insert "("
(if (or (not (integerp eager))
@@ -897,4 +898,6 @@
" "
desktop-file-version)
+ (let ((base (pop l)))
+ (when base (setcar (nthcdr 1 l) base)))
(dolist (e l)
(insert "\n " (desktop-value-to-string e)))
next prev parent reply other threads:[~2008-02-08 16:59 UTC|newest]
Thread overview: 29+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-02-06 16:12 22.1.90; desktop-save throws (error "No buffer named <uniquified buffername>") Martin Fischer
2008-02-07 0:23 ` Juanma Barranquero
2008-02-08 16:59 ` Juanma Barranquero [this message]
2008-02-08 18:30 ` Stefan Monnier
2008-02-08 19:00 ` Juanma Barranquero
2008-02-08 21:17 ` Stefan Monnier
2008-02-12 0:44 ` Juanma Barranquero
2008-02-12 3:39 ` Stefan Monnier
2008-02-12 4:15 ` Juanma Barranquero
2008-02-27 12:43 ` Martin Fischer
2008-02-27 12:48 ` Juanma Barranquero
2008-02-27 16:28 ` Juanma Barranquero
2008-02-27 21:18 ` Stefan Monnier
2008-02-27 22:17 ` Juanma Barranquero
2008-02-27 22:37 ` Stefan Monnier
2008-02-27 23:00 ` Juanma Barranquero
2008-02-28 1:54 ` Stefan Monnier
2008-02-28 9:14 ` Juanma Barranquero
2008-02-28 17:09 ` Stefan Monnier
2008-02-28 13:27 ` Martin Fischer
2008-02-28 16:29 ` Juanma Barranquero
2008-02-29 10:07 ` Martin Fischer
2008-02-29 10:49 ` Juanma Barranquero
2008-02-29 13:17 ` Martin Fischer
2008-02-29 14:24 ` Juanma Barranquero
2008-02-29 14:48 ` Jason Rumney
2008-02-29 15:03 ` Juanma Barranquero
2008-02-29 15:16 ` Lennart Borgman (gmail)
2008-02-29 15:19 ` Juanma Barranquero
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=f7ccd24b0802080859q3ec1f508oae67e51fe6a7031c@mail.gmail.com \
--to=lekktu@gmail.com \
--cc=emacs-pretest-bug@gnu.org \
--cc=parozusa@web.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.