[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Orgmode] Bug: org-capture - org-vm store link requires buffer file
From: |
Bastien |
Subject: |
Re: [Orgmode] Bug: org-capture - org-vm store link requires buffer file not always present [7.4] |
Date: |
Wed, 09 Feb 2011 17:19:08 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (gnu/linux) |
Hi Arik,
Arik Mitschang <address@hidden> writes:
> In VM if you have created a virtual folder, the buffer is not associated
> with any file. However, during org-capture a function called
> org-vm-store-link requires that the buffer (the vm folder in this case)
> be associated with a file causing a type-mismatch error. I can fix the
> problem with the following patch:
This looks fine to me, but I'm not using VM.
Can some VM user double-check this?
> ----------------------------------
> diff -U3 /usr/local/share/emacs/23.2/site-lisp/org-vm.el
> /var/folders/Qm/Qm3iuPk7E18cewjBO5PgL5AVPiY/-Tmp-/buffer-content-66395kXL
> --- /usr/local/share/emacs/23.2/site-lisp/org-vm.el 2010-12-11
> 00:16:33.000000000 +1100
> +++ /var/folders/Qm/Qm3iuPk7E18cewjBO5PgL5AVPiY/-Tmp-/buffer-content-66395kXL
> 2011-02-09 14:27:35.000000000 +1100
> @@ -54,8 +54,12 @@
> ;; Implementation
> (defun org-vm-store-link ()
> "Store a link to a VM folder or message."
> - (when (or (eq major-mode 'vm-summary-mode)
> + (when (and (or (eq major-mode 'vm-summary-mode)
> (eq major-mode 'vm-presentation-mode))
> + (save-excursion (vm-select-folder-buffer)
> + (eq (type-of
> buffer-file-name)
> + 'string)))
(Better use (stringp buffer-file-name) instead of type-of.)
--
Bastien