From 71099f82616f75bc8b93c3e9419cf1fb918ae308 Mon Sep 17 00:00:00 2001 From: yoichi Date: Thu, 26 Jan 2006 03:59:17 +0000 Subject: [PATCH] * wl-draft.el (wl-draft-save, wl-draft-buffer-change-number): Avoid error when the buffer name is already used. --- wl/ChangeLog | 5 +++++ wl/wl-draft.el | 4 ++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/wl/ChangeLog b/wl/ChangeLog index 7023bd4..fa38cf9 100644 --- a/wl/ChangeLog +++ b/wl/ChangeLog @@ -1,3 +1,8 @@ +2006-01-26 Yoichi NAKAYAMA + + * wl-draft.el (wl-draft-save, wl-draft-buffer-change-number): + Avoid error when the buffer name is already used. + 2006-01-23 Yoichi NAKAYAMA * wl-vars.el (wl-message-buffer-prefetch-folder-type-list): Follow diff --git a/wl/wl-draft.el b/wl/wl-draft.el index dbdfa3d..855346a 100644 --- a/wl/wl-draft.el +++ b/wl/wl-draft.el @@ -1452,7 +1452,7 @@ If KILL-WHEN-DONE is non-nil, current draft buffer is killed" (elmo-folder-check (wl-draft-get-folder)) (elmo-folder-commit (wl-draft-get-folder)) (setq wl-draft-buffer-message-number next-number) - (rename-buffer (format "%s/%d" wl-draft-folder next-number)) + (rename-buffer (format "%s/%d" wl-draft-folder next-number) t) (setq buffer-file-name (buffer-name)) (set-buffer-modified-p nil) (wl-draft-config-info-operation wl-draft-buffer-message-number 'save) @@ -2632,7 +2632,7 @@ been implemented yet. Partial support for SWITCH-FUNCTION now supported." (defun wl-draft-buffer-change-number (old-number new-number) (when (eq wl-draft-buffer-message-number old-number) (setq wl-draft-buffer-message-number new-number) - (rename-buffer (format "%s/%d" wl-draft-folder new-number)) + (rename-buffer (format "%s/%d" wl-draft-folder new-number) t) (setq buffer-file-name (buffer-name)) (set-buffer-modified-p nil))) -- 1.7.10.4