Fix bugs #12447 and #12326 with infloop causes by idle timers, update docs.
commitdf9685f3961022245b9ab73b62023aa573862001
authorEli Zaretskii <eliz@gnu.org>
Sat, 22 Sep 2012 13:16:03 +0000 (22 16:16 +0300)
committerEli Zaretskii <eliz@gnu.org>
Sat, 22 Sep 2012 13:16:03 +0000 (22 16:16 +0300)
treedc572840dcc97dd6abe4a9cfe7e279525211a124
parent8e17c9ba1443c2f21c5801f0c4660ac08dccc837
Fix bugs #12447 and #12326 with infloop causes by idle timers, update docs.

 src/keyboard.c (timer_check_2): Move calculation of 'timers' and
 'idle_timers' from here ...
 (timer_check): ... to here.  Use Fcopy_sequence to copy the timer
 lists, to avoid infloops when the timer does something stupid,
 like reinvoke itself with the same or smaller time-out.

 lisp/emacs-lisp/timer.el (run-with-idle-timer)
 (timer-activate-when-idle): Warn against reinvoking an idle timer
 from within its own timer action.

 doc/lispref/os.texi (Idle Timers): Warn against reinvoking an idle timer
 from within its own timer action.
doc/lispref/ChangeLog
doc/lispref/os.texi
lisp/ChangeLog
lisp/emacs-lisp/timer.el
src/ChangeLog
src/keyboard.c