org-archive: Fix point after archiving to sibling

* lisp/org-archive.el (org-archive-to-archive-sibling): Move point in
  a consistent way upon archiving to a sibling.

Reported-by: Allen Li <vianchielfaura@gmail.com>
<http://lists.gnu.org/r/emacs-orgmode/2017-12/msg00158.html>
This commit is contained in:
Nicolas Goaziou 2017-12-11 23:19:40 +01:00
parent b467877437
commit 0dde39ccd3
1 changed files with 1 additions and 1 deletions

View File

@ -429,7 +429,7 @@ Archiving time is retained in the ARCHIVE_TIME node property."
(looking-at org-outline-regexp)
(setq leader (match-string 0)
level (funcall outline-level))
(setq pos (point))
(setq pos (point-marker))
(condition-case nil
(outline-up-heading 1 t)
(error (setq e (point-max)) (goto-char (point-min))))