From 2d56beeda61a7ed6551d889119040310c5658695 Mon Sep 17 00:00:00 2001 From: Chong Yidong Date: Mon, 25 Sep 2006 15:20:44 +0000 Subject: [PATCH] * os.texi (Timers): Mention with-local-quit. --- lispref/ChangeLog | 4 ++++ lispref/os.texi | 7 ++++++- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/lispref/ChangeLog b/lispref/ChangeLog index 2740462384c..fe0d430f873 100644 --- a/lispref/ChangeLog +++ b/lispref/ChangeLog @@ -1,3 +1,7 @@ +2006-09-25 Chong Yidong + + * os.texi (Timers): Mention with-local-quit. + 2006-09-24 Richard Stallman * searching.texi (Searching and Matching): Mention property search. diff --git a/lispref/os.texi b/lispref/os.texi index 6c2d660709e..65cb0b906af 100644 --- a/lispref/os.texi +++ b/lispref/os.texi @@ -1386,7 +1386,12 @@ function, because quitting out of many timer functions can leave things in an inconsistent state. This is normally unproblematical because most timer functions don't do a lot of work. Indeed, for a timer to call a function that takes substantial time to run is likely -to be annoying. +to be annoying. If a timer function needs to allow quitting, it +should use @code{with-local-quit} (@pxref{Quitting}). For example, if +a timer function calls @code{accept-process-output} to receive output +from an external process, that call should be wrapped inside +@code{with-local-quit}, to ensure that @kbd{C-g} works if the external +process hangs. It is usually a bad idea for timer functions to alter buffer contents. When they do, they usually should call @code{undo-boundary} -- 2.39.2