Fix bug in org-remember.el
commit2ab3ed4c2fa003dac88149d97634db7ca24a5da8
authorCarsten Dominik <carsten.dominik@gmail.com>
Tue, 3 Nov 2009 05:44:10 +0000 (3 06:44 +0100)
committerCarsten Dominik <carsten.dominik@gmail.com>
Tue, 3 Nov 2009 05:44:10 +0000 (3 06:44 +0100)
treeb53e5455a858f7f674a7c1d8fa83aa64be620d1a
parent4523ae580b37c522bf0bf300449bfc5f524035ec
Fix bug in org-remember.el

Adam Spiers writes:

> The code for handling %^{PROP}p in org-remember templates seems to
> have a bug:
>
>       ((equal char "p")
>              (edebug)
>        (let*
>    ((prop (org-substring-no-properties prompt))
>     (pall (concat prop "_ALL"))
>     (allowed
>      (with-current-buffer
>  (get-buffer (file-name-nondirectory file))
>
> Here get-buffer can return nil, in which case `org-remember' fails
> with the error:
>
>  Wrong type argument: stringp, nil
>
> It seems to be assuming that the non-directory part of the filename
> corresponds to the buffer name, but this is not guaranteed.  Perhaps I
> noticed it because I am using uniquify.el ?
lisp/ChangeLog
lisp/org-remember.el