aboutsummaryrefslogtreecommitdiffstats
path: root/src/process.c
diff options
context:
space:
mode:
authorDmitry Antipov2012-08-28 10:20:08 +0400
committerDmitry Antipov2012-08-28 10:20:08 +0400
commit66322887059e1f2711e07def5eff661281cee855 (patch)
treeedf1ef336402c53b08c69f2b0d92c2391a2549d5 /src/process.c
parenta3d794a153425b09a0185c660926c241d13e0f2c (diff)
downloademacs-66322887059e1f2711e07def5eff661281cee855.tar.gz
emacs-66322887059e1f2711e07def5eff661281cee855.zip
Always use set_buffer_if_live to restore original buffer at unwind.
* buffer.h (record_unwind_current_buffer): New function. * bytecode.c, dispnew.c, editfns.c, fileio.c, fns.c, insdel.c: * keyboard.c, keymap.c, minibuf.c, print.c, process.c, textprop.c: * undo.c, window.c: Adjust users. * buffer.c (set_buffer_if_live): Fix comment.
Diffstat (limited to 'src/process.c')
-rw-r--r--src/process.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/process.c b/src/process.c
index 64c70c49590..fbe56ebcb54 100644
--- a/src/process.c
+++ b/src/process.c
@@ -5196,7 +5196,7 @@ read_process_output (Lisp_Object proc, register int channel)
5196 /* There's no good reason to let process filters change the current 5196 /* There's no good reason to let process filters change the current
5197 buffer, and many callers of accept-process-output, sit-for, and 5197 buffer, and many callers of accept-process-output, sit-for, and
5198 friends don't expect current-buffer to be changed from under them. */ 5198 friends don't expect current-buffer to be changed from under them. */
5199 record_unwind_protect (set_buffer_if_live, Fcurrent_buffer ()); 5199 record_unwind_current_buffer ();
5200 5200
5201 /* Read and dispose of the process output. */ 5201 /* Read and dispose of the process output. */
5202 outstream = p->filter; 5202 outstream = p->filter;
@@ -6587,7 +6587,7 @@ exec_sentinel (Lisp_Object proc, Lisp_Object reason)
6587 /* There's no good reason to let sentinels change the current 6587 /* There's no good reason to let sentinels change the current
6588 buffer, and many callers of accept-process-output, sit-for, and 6588 buffer, and many callers of accept-process-output, sit-for, and
6589 friends don't expect current-buffer to be changed from under them. */ 6589 friends don't expect current-buffer to be changed from under them. */
6590 record_unwind_protect (set_buffer_if_live, Fcurrent_buffer ()); 6590 record_unwind_current_buffer ();
6591 6591
6592 sentinel = p->sentinel; 6592 sentinel = p->sentinel;
6593 if (NILP (sentinel)) 6593 if (NILP (sentinel))