From mboxrd@z Thu Jan 1 00:00:00 1970 From: Adam Spiers Subject: bug with %^{Property}p in org-remember templates Date: Mon, 2 Nov 2009 14:58:57 +0000 Message-ID: <20091102145857.GE30665@atlantic.linksys.moosehall> Reply-To: Adam Spiers Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1N4yNA-0002KG-M1 for emacs-orgmode@gnu.org; Mon, 02 Nov 2009 09:59:08 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1N4yN6-0002IT-7p for emacs-orgmode@gnu.org; Mon, 02 Nov 2009 09:59:08 -0500 Received: from [199.232.76.173] (port=58835 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1N4yN6-0002IK-1y for emacs-orgmode@gnu.org; Mon, 02 Nov 2009 09:59:04 -0500 Received: from arctic.adamspiers.org ([212.13.194.176]:60865) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1N4yN5-00006N-MN for emacs-orgmode@gnu.org; Mon, 02 Nov 2009 09:59:03 -0500 Received: from localhost (dsl-217-155-199-114.zen.co.uk [217.155.199.114]) by arctic.adamspiers.org (Postfix) with ESMTP id 6A1DE2401B for ; Mon, 2 Nov 2009 14:59:02 +0000 (UTC) Content-Disposition: inline List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: org-mode mailing list 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 ?