From ec7bd3b1bee7125a998ace624d863a0d380908c9 Mon Sep 17 00:00:00 2001 From: Max Mikhanosha Date: Mon, 16 Apr 2012 18:52:39 -0400 Subject: [PATCH] Fix org-agenda-to-appt, which got broken by sticky agenda * lisp/org-agenda.el (org-agenda-new-marker): Check for NIL org-agenda-buffer (org-agenda-to-appt): Bind org-agenda-buffer to NIL --- lisp/org-agenda.el | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/lisp/org-agenda.el b/lisp/org-agenda.el index 46bb33e28..27f3c9f5d 100644 --- a/lisp/org-agenda.el +++ b/lisp/org-agenda.el @@ -3476,7 +3476,9 @@ Org-mode keeps a list of these markers and resets them when they are no longer in use." (let ((m (copy-marker (or pos (point))))) (setq org-agenda-last-marker-time (org-float-time)) - (with-current-buffer org-agenda-buffer + (if org-agenda-buffer + (with-current-buffer org-agenda-buffer + (push m org-agenda-markers)) (push m org-agenda-markers)) m)) @@ -8873,7 +8875,8 @@ details and examples." (today (org-date-to-gregorian (time-to-days (current-time)))) (org-agenda-restrict nil) - (files (org-agenda-files 'unrestricted)) entries file) + (files (org-agenda-files 'unrestricted)) entries file + (org-agenda-buffer nil)) ;; Get all entries which may contain an appt (org-prepare-agenda-buffers files) (while (setq file (pop files)) -- 2.11.4.GIT