diff options
| author | Paul Eggert | 2018-06-07 18:53:27 -0700 |
|---|---|---|
| committer | Paul Eggert | 2018-06-07 19:11:49 -0700 |
| commit | a0aa1d4ecc123d652285ef10ea62ed55c6c118d6 (patch) | |
| tree | c56177683a5a552e17eb8ce7ed27256507361b60 /src/window.c | |
| parent | a0641286f6e58f4dca4221caa6dd559bfacea699 (diff) | |
| download | emacs-a0aa1d4ecc123d652285ef10ea62ed55c6c118d6.tar.gz emacs-a0aa1d4ecc123d652285ef10ea62ed55c6c118d6.zip | |
New function record_unwind_protect_excursion
This simplifies callers a bit, and will simplify future changes.
* src/eval.c (record_unwind_protect_excursion): New function.
* src/buffer.c (Fkill_buffer):
* src/bytecode.c (exec_byte_code):
* src/editfns.c (Fsave_excursion, Freplace_buffer_contents):
* src/lread.c (readevalloop, Feval_buffer):
* src/window.c (scroll_command):
Use it.
Diffstat (limited to 'src/window.c')
| -rw-r--r-- | src/window.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/window.c b/src/window.c index f654d87e14a..2c6ff01ea43 100644 --- a/src/window.c +++ b/src/window.c | |||
| @@ -5656,7 +5656,7 @@ scroll_command (Lisp_Object window, Lisp_Object n, int direction) | |||
| 5656 | the moment. But don't screw up if window_scroll gets an error. */ | 5656 | the moment. But don't screw up if window_scroll gets an error. */ |
| 5657 | if (XBUFFER (w->contents) != current_buffer) | 5657 | if (XBUFFER (w->contents) != current_buffer) |
| 5658 | { | 5658 | { |
| 5659 | record_unwind_protect (save_excursion_restore, save_excursion_save ()); | 5659 | record_unwind_protect_excursion (); |
| 5660 | Fset_buffer (w->contents); | 5660 | Fset_buffer (w->contents); |
| 5661 | } | 5661 | } |
| 5662 | 5662 | ||