From df506794db4ab026a4525772de92b8bd33ef6271 Mon Sep 17 00:00:00 2001 From: Bastien Date: Tue, 21 Feb 2017 15:41:15 +0100 Subject: [PATCH] org-capture: Fix commit 7d7c38 --- lisp/org-capture.el | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lisp/org-capture.el b/lisp/org-capture.el index 71aff0dea..4466d2310 100644 --- a/lisp/org-capture.el +++ b/lisp/org-capture.el @@ -830,7 +830,9 @@ for `entry'-type templates")) ;; empty lines) around entry, use a marker to refer to the ;; headline to be refiled. Place the marker in the base buffer, ;; as the current indirect one is going to be killed. - (set-marker pos (save-excursion (org-back-to-heading t)) base) + (set-marker pos (save-excursion + (and (org-back-to-heading t) (point))) + base) (org-capture-put :kill-buffer nil) (unwind-protect (progn