diff options
| author | Paul Eggert | 2011-04-04 01:09:01 -0700 |
|---|---|---|
| committer | Paul Eggert | 2011-04-04 01:09:01 -0700 |
| commit | aba7731a6c29e0e21f731f7adef34a070d67d9f3 (patch) | |
| tree | cac7022e0d507d5ba82af22ee30ed9696a8b4571 /src/process.c | |
| parent | fdfc4bf34ecc9d0d7ee2241e246191a5f928a33a (diff) | |
| download | emacs-aba7731a6c29e0e21f731f7adef34a070d67d9f3.tar.gz emacs-aba7731a6c29e0e21f731f7adef34a070d67d9f3.zip | |
* process.c (list_processes_1, create_pty, read_process_output):
(exec_sentinel): Remove vars that were set but not used.
Diffstat (limited to 'src/process.c')
| -rw-r--r-- | src/process.c | 24 |
1 files changed, 11 insertions, 13 deletions
diff --git a/src/process.c b/src/process.c index 1abfbd3f2a4..080eedabc92 100644 --- a/src/process.c +++ b/src/process.c | |||
| @@ -1344,11 +1344,7 @@ list_processes_1 (Lisp_Object query_only) | |||
| 1344 | symbol = XCAR (p->status); | 1344 | symbol = XCAR (p->status); |
| 1345 | 1345 | ||
| 1346 | if (EQ (symbol, Qsignal)) | 1346 | if (EQ (symbol, Qsignal)) |
| 1347 | { | 1347 | Fprinc (symbol, Qnil); |
| 1348 | Lisp_Object tem; | ||
| 1349 | tem = Fcar (Fcdr (p->status)); | ||
| 1350 | Fprinc (symbol, Qnil); | ||
| 1351 | } | ||
| 1352 | else if (NETCONN1_P (p) || SERIALCONN1_P (p)) | 1348 | else if (NETCONN1_P (p) || SERIALCONN1_P (p)) |
| 1353 | { | 1349 | { |
| 1354 | if (EQ (symbol, Qexit)) | 1350 | if (EQ (symbol, Qexit)) |
| @@ -2152,7 +2148,6 @@ create_pty (Lisp_Object process) | |||
| 2152 | int inchannel, outchannel; | 2148 | int inchannel, outchannel; |
| 2153 | 2149 | ||
| 2154 | /* Use volatile to protect variables from being clobbered by longjmp. */ | 2150 | /* Use volatile to protect variables from being clobbered by longjmp. */ |
| 2155 | volatile int forkin, forkout; | ||
| 2156 | volatile int pty_flag = 0; | 2151 | volatile int pty_flag = 0; |
| 2157 | 2152 | ||
| 2158 | inchannel = outchannel = -1; | 2153 | inchannel = outchannel = -1; |
| @@ -2169,11 +2164,11 @@ create_pty (Lisp_Object process) | |||
| 2169 | #ifdef O_NOCTTY | 2164 | #ifdef O_NOCTTY |
| 2170 | /* Don't let this terminal become our controlling terminal | 2165 | /* Don't let this terminal become our controlling terminal |
| 2171 | (in case we don't have one). */ | 2166 | (in case we don't have one). */ |
| 2172 | forkout = forkin = emacs_open (pty_name, O_RDWR | O_NOCTTY, 0); | 2167 | volatile int forkout = emacs_open (pty_name, O_RDWR | O_NOCTTY, 0); |
| 2173 | #else | 2168 | #else |
| 2174 | forkout = forkin = emacs_open (pty_name, O_RDWR, 0); | 2169 | volatile int forkout = emacs_open (pty_name, O_RDWR, 0); |
| 2175 | #endif | 2170 | #endif |
| 2176 | if (forkin < 0) | 2171 | if (forkout < 0) |
| 2177 | report_file_error ("Opening pty", Qnil); | 2172 | report_file_error ("Opening pty", Qnil); |
| 2178 | #if defined (DONT_REOPEN_PTY) | 2173 | #if defined (DONT_REOPEN_PTY) |
| 2179 | /* In the case that vfork is defined as fork, the parent process | 2174 | /* In the case that vfork is defined as fork, the parent process |
| @@ -2181,8 +2176,6 @@ create_pty (Lisp_Object process) | |||
| 2181 | tty options setup. So we setup tty before forking. */ | 2176 | tty options setup. So we setup tty before forking. */ |
| 2182 | child_setup_tty (forkout); | 2177 | child_setup_tty (forkout); |
| 2183 | #endif /* DONT_REOPEN_PTY */ | 2178 | #endif /* DONT_REOPEN_PTY */ |
| 2184 | #else | ||
| 2185 | forkin = forkout = -1; | ||
| 2186 | #endif /* not USG, or USG_SUBTTY_WORKS */ | 2179 | #endif /* not USG, or USG_SUBTTY_WORKS */ |
| 2187 | pty_flag = 1; | 2180 | pty_flag = 1; |
| 2188 | } | 2181 | } |
| @@ -5249,15 +5242,17 @@ read_process_output (Lisp_Object proc, register int channel) | |||
| 5249 | outstream = p->filter; | 5242 | outstream = p->filter; |
| 5250 | if (!NILP (outstream)) | 5243 | if (!NILP (outstream)) |
| 5251 | { | 5244 | { |
| 5252 | Lisp_Object obuffer, okeymap; | ||
| 5253 | Lisp_Object text; | 5245 | Lisp_Object text; |
| 5254 | int outer_running_asynch_code = running_asynch_code; | 5246 | int outer_running_asynch_code = running_asynch_code; |
| 5255 | int waiting = waiting_for_user_input_p; | 5247 | int waiting = waiting_for_user_input_p; |
| 5256 | 5248 | ||
| 5257 | /* No need to gcpro these, because all we do with them later | 5249 | /* No need to gcpro these, because all we do with them later |
| 5258 | is test them for EQness, and none of them should be a string. */ | 5250 | is test them for EQness, and none of them should be a string. */ |
| 5251 | #if 0 | ||
| 5252 | Lisp_Object obuffer, okeymap; | ||
| 5259 | XSETBUFFER (obuffer, current_buffer); | 5253 | XSETBUFFER (obuffer, current_buffer); |
| 5260 | okeymap = BVAR (current_buffer, keymap); | 5254 | okeymap = BVAR (current_buffer, keymap); |
| 5255 | #endif | ||
| 5261 | 5256 | ||
| 5262 | /* We inhibit quit here instead of just catching it so that | 5257 | /* We inhibit quit here instead of just catching it so that |
| 5263 | hitting ^G when a filter happens to be running won't screw | 5258 | hitting ^G when a filter happens to be running won't screw |
| @@ -6540,7 +6535,7 @@ exec_sentinel_error_handler (Lisp_Object error_val) | |||
| 6540 | static void | 6535 | static void |
| 6541 | exec_sentinel (Lisp_Object proc, Lisp_Object reason) | 6536 | exec_sentinel (Lisp_Object proc, Lisp_Object reason) |
| 6542 | { | 6537 | { |
| 6543 | Lisp_Object sentinel, obuffer, odeactivate, okeymap; | 6538 | Lisp_Object sentinel, odeactivate; |
| 6544 | register struct Lisp_Process *p = XPROCESS (proc); | 6539 | register struct Lisp_Process *p = XPROCESS (proc); |
| 6545 | int count = SPECPDL_INDEX (); | 6540 | int count = SPECPDL_INDEX (); |
| 6546 | int outer_running_asynch_code = running_asynch_code; | 6541 | int outer_running_asynch_code = running_asynch_code; |
| @@ -6552,8 +6547,11 @@ exec_sentinel (Lisp_Object proc, Lisp_Object reason) | |||
| 6552 | /* No need to gcpro these, because all we do with them later | 6547 | /* No need to gcpro these, because all we do with them later |
| 6553 | is test them for EQness, and none of them should be a string. */ | 6548 | is test them for EQness, and none of them should be a string. */ |
| 6554 | odeactivate = Vdeactivate_mark; | 6549 | odeactivate = Vdeactivate_mark; |
| 6550 | #if 0 | ||
| 6551 | Lisp_Object obuffer, okeymap; | ||
| 6555 | XSETBUFFER (obuffer, current_buffer); | 6552 | XSETBUFFER (obuffer, current_buffer); |
| 6556 | okeymap = BVAR (current_buffer, keymap); | 6553 | okeymap = BVAR (current_buffer, keymap); |
| 6554 | #endif | ||
| 6557 | 6555 | ||
| 6558 | /* There's no good reason to let sentinels change the current | 6556 | /* There's no good reason to let sentinels change the current |
| 6559 | buffer, and many callers of accept-process-output, sit-for, and | 6557 | buffer, and many callers of accept-process-output, sit-for, and |