1
0
mirror of https://git.savannah.gnu.org/git/emacs/org-mode.git synced 2025-01-07 15:22:06 +00:00

org-clock: fix runtime error in org-clock-in

* org-clock.el (org-clock-in): Under certain configurations of org,
Emacs doom, evil-org-mode and my custom settings, org-clock-in aborts
with an an error because indent-line-to is called with -2.

TINYCHANGE
This commit is contained in:
Jean-Marie Gaillourdet 2020-12-13 12:50:52 +01:00 committed by Kyle Meyer
parent 75ccb9719f
commit ee4ffa5672

View File

@ -1369,7 +1369,7 @@ the default behavior."
(end-of-line 0)
(org-in-item-p)))
(beginning-of-line 1)
(indent-line-to (- (current-indentation) 2)))
(indent-line-to (max 0 (- (current-indentation) 2))))
(insert org-clock-string " ")
(setq org-clock-effort (org-entry-get (point) org-effort-property))
(setq org-clock-total-time (org-clock-sum-current-item