From mboxrd@z Thu Jan 1 00:00:00 1970 From: Carsten Dominik Subject: Re: Patch to fix bug where remember template dies w/ non-filename buffer name Date: Wed, 4 Nov 2009 14:10:43 +0100 Message-ID: <11BE733E-E199-4E7F-888D-05A734B2393A@gmail.com> References: <87ljincc3r.fsf@dustycloud.org> Mime-Version: 1.0 (Apple Message framework v936) Content-Type: text/plain; charset=US-ASCII; format=flowed; delsp=yes Content-Transfer-Encoding: 7bit Return-path: Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1N5jwq-0006HC-Dh for emacs-orgmode@gnu.org; Wed, 04 Nov 2009 12:47:08 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1N5jwl-0006CS-6Q for emacs-orgmode@gnu.org; Wed, 04 Nov 2009 12:47:07 -0500 Received: from [199.232.76.173] (port=48192 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1N5jwk-0006CE-TR for emacs-orgmode@gnu.org; Wed, 04 Nov 2009 12:47:03 -0500 Received: from mail-ew0-f228.google.com ([209.85.219.228]:42413) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1N5jwk-0008CW-ET for emacs-orgmode@gnu.org; Wed, 04 Nov 2009 12:47:02 -0500 Received: by ewy28 with SMTP id 28so236526ewy.42 for ; Wed, 04 Nov 2009 09:47:01 -0800 (PST) In-Reply-To: <87ljincc3r.fsf@dustycloud.org> 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: Christopher Allan Webber Cc: emacs-orgmode@gnu.org Applied, thanks. - Carsten On Nov 4, 2009, at 2:28 AM, Christopher Allan Webber wrote: > Hi, > > So I ran into an annoying bug where if you have an orgmode remember > template like: > > ("Test" ?e "* foo \n %^{Bar}p" "~/org/test.org" "Test") > > Currently, if either test.org is not open, or test.org is open but the > buffer is named something else (say, test.org<2>), orgmode will die > when > asking for the property (in this case, Bar). > > The issue was that in the org-remember-apply-template function, it > would > attempt to get the buffer like so: > > (get-buffer (file-name-nondirectory file)) > > in other words, it would try to get the buffer with the name of > "test.org"... no matter what that buffer was, if exists, or if it was > even called that. > > I've attached a patch that fixes the problem. > > Thanks, > - Christopher Allan Webber > > _______________________________________________ > Emacs-orgmode mailing list > Remember: use `Reply All' to send replies to the list. > Emacs-orgmode@gnu.org > http://lists.gnu.org/mailman/listinfo/emacs-orgmode - Carsten