diff options
author | Paul Eggert <eggert@cs.ucla.edu> | 2016-02-03 13:21:10 -0800 |
---|---|---|
committer | Paul Eggert <eggert@cs.ucla.edu> | 2016-02-03 13:26:52 -0800 |
commit | 6b0ab7f5806844dc158b60a0c0c0fcc5fe5b6678 (patch) | |
tree | 4851f964b99fc73f18ed4a6dc17e4f90ab20e1ae | |
parent | 60d712bba7ef0f3a80daa1757de70856a7af9a67 (diff) |
Mention context when resume from emergency escape
That way, if the user has been doing something else for a while,
they are reminded of the situation when restarting Emacs,
and are more likely to understand the two questions.
* doc/emacs/trouble.texi (Emergency Escape): Document this.
* src/keyboard.c (handle_interrupt): Implement this.
-rw-r--r-- | doc/emacs/trouble.texi | 9 | ||||
-rw-r--r-- | src/keyboard.c | 3 |
2 files changed, 9 insertions, 3 deletions
diff --git a/doc/emacs/trouble.texi b/doc/emacs/trouble.texi index 3268063376..bd347b076d 100644 --- a/doc/emacs/trouble.texi +++ b/doc/emacs/trouble.texi @@ -417,19 +417,22 @@ first @kbd{C-g} properly, then the second one will get you back to the shell. When you resume Emacs after a suspension caused by emergency escape, -it asks two questions before going back to what it had been doing: +it reports the resumption and asks a question or two before going back +to what it had been doing: @example +Emacs is resuming after an emergency escape. Auto-save? (y or n) Abort (and dump core)? (y or n) @end example @noindent -Answer each one with @kbd{y} or @kbd{n} followed by @key{RET}. +Answer each question with @kbd{y} or @kbd{n} followed by @key{RET}. Saying @kbd{y} to @samp{Auto-save?} causes immediate auto-saving of all modified buffers in which auto-saving is enabled. Saying @kbd{n} -skips this. +skips this. This question is omitted if Emacs is in a state where +auto-saving cannot be done safely. Saying @kbd{y} to @samp{Abort (and dump core)?} causes Emacs to crash, dumping core. This is to enable a wizard to figure out why diff --git a/src/keyboard.c b/src/keyboard.c index 64d7b139ed..7e95ad7ad1 100644 --- a/src/keyboard.c +++ b/src/keyboard.c @@ -10295,6 +10295,9 @@ handle_interrupt (bool in_signal_handler) is used. Note that [Enter] is not echoed by dos. */ cursor_to (SELECTED_FRAME (), 0, 0); #endif + + write_stdout ("Emacs is resuming after an emergency escape.\n"); + /* It doesn't work to autosave while GC is in progress; the code used for auto-saving doesn't cope with the mark bit. */ if (!gc_in_progress) |