aboutsummaryrefslogtreecommitdiffstats
path: root/src/process.c
diff options
context:
space:
mode:
authorChong Yidong2006-08-03 15:19:20 +0000
committerChong Yidong2006-08-03 15:19:20 +0000
commitd634a67054364f0a1d1ddad6791fe69186505fbe (patch)
treebe218f0bf2145b8e2f36cca2bfc1dc5e3e5e0b3a /src/process.c
parent7abcd3e393cead48a7ac8c76e6d85b40ca48effe (diff)
downloademacs-d634a67054364f0a1d1ddad6791fe69186505fbe.tar.gz
emacs-d634a67054364f0a1d1ddad6791fe69186505fbe.zip
* process.c: Revert last change.
Diffstat (limited to 'src/process.c')
-rw-r--r--src/process.c18
1 files changed, 6 insertions, 12 deletions
diff --git a/src/process.c b/src/process.c
index b24dee002c6..dc70ef37761 100644
--- a/src/process.c
+++ b/src/process.c
@@ -4158,14 +4158,6 @@ server_accept_connection (server, channel)
4158 when not inside wait_reading_process_output. */ 4158 when not inside wait_reading_process_output. */
4159static int waiting_for_user_input_p; 4159static int waiting_for_user_input_p;
4160 4160
4161static Lisp_Object
4162wait_reading_process_output_unwind (data)
4163 Lisp_Object data;
4164{
4165 waiting_for_user_input_p = XINT (data);
4166 return Qnil;
4167}
4168
4169/* This is here so breakpoints can be put on it. */ 4161/* This is here so breakpoints can be put on it. */
4170static void 4162static void
4171wait_reading_process_output_1 () 4163wait_reading_process_output_1 ()
@@ -4248,7 +4240,11 @@ wait_reading_process_output (time_limit, microsecs, read_kbd, do_display,
4248 EMACS_TIME timeout, end_time; 4240 EMACS_TIME timeout, end_time;
4249 int wait_channel = -1; 4241 int wait_channel = -1;
4250 int got_some_input = 0; 4242 int got_some_input = 0;
4251 int count = SPECPDL_INDEX (); 4243 /* We can't record_unwind_protect here because after the
4244 set_waiting_for_input call, C-g (interrupt_signal) would run
4245 throw_to_read_char instead of Fsignal, which means unbind_to
4246 doesn't get called. */
4247 int saved_waiting_for_user_input_p = waiting_for_user_input_p;
4252 4248
4253 FD_ZERO (&Available); 4249 FD_ZERO (&Available);
4254#ifdef NON_BLOCKING_CONNECT 4250#ifdef NON_BLOCKING_CONNECT
@@ -4259,8 +4255,6 @@ wait_reading_process_output (time_limit, microsecs, read_kbd, do_display,
4259 if (wait_proc != NULL) 4255 if (wait_proc != NULL)
4260 wait_channel = XINT (wait_proc->infd); 4256 wait_channel = XINT (wait_proc->infd);
4261 4257
4262 record_unwind_protect (wait_reading_process_output_unwind,
4263 make_number (waiting_for_user_input_p));
4264 waiting_for_user_input_p = read_kbd; 4258 waiting_for_user_input_p = read_kbd;
4265 4259
4266 /* Since we may need to wait several times, 4260 /* Since we may need to wait several times,
@@ -4887,7 +4881,7 @@ wait_reading_process_output (time_limit, microsecs, read_kbd, do_display,
4887 } /* end for each file descriptor */ 4881 } /* end for each file descriptor */
4888 } /* end while exit conditions not met */ 4882 } /* end while exit conditions not met */
4889 4883
4890 unbind_to (count, Qnil); 4884 waiting_for_user_input_p = saved_waiting_for_user_input_p;
4891 4885
4892 /* If calling from keyboard input, do not quit 4886 /* If calling from keyboard input, do not quit
4893 since we want to return C-g as an input character. 4887 since we want to return C-g as an input character.