diff options
| author | Stefan Monnier | 2002-04-01 19:50:51 +0000 |
|---|---|---|
| committer | Stefan Monnier | 2002-04-01 19:50:51 +0000 |
| commit | bed9664a999fc92bec580282fbb9bba3663adbc3 (patch) | |
| tree | 09fc0cfa54aa0de85158d995a1a0feaed197a5da /src | |
| parent | 0fc8f792bac83d74d121d0421a055d77b2f9d264 (diff) | |
| download | emacs-bed9664a999fc92bec580282fbb9bba3663adbc3.tar.gz emacs-bed9664a999fc92bec580282fbb9bba3663adbc3.zip | |
(DATAGRAM_CONN_P, list_processes_1)
(Fprocess_datagram_address, Fset_process_datagram_address)
(Fset_network_process_options, server_accept_connection):
Fix some int/Lisp_Object confusions (thank you union types).
Diffstat (limited to 'src')
| -rw-r--r-- | src/ChangeLog | 24 | ||||
| -rw-r--r-- | src/process.c | 16 |
2 files changed, 23 insertions, 17 deletions
diff --git a/src/ChangeLog b/src/ChangeLog index 9d0633e00eb..d0ba5ae47c0 100644 --- a/src/ChangeLog +++ b/src/ChangeLog | |||
| @@ -1,16 +1,23 @@ | |||
| 1 | 2002-04-01 Stefan Monnier <monnier@cs.yale.edu> | ||
| 2 | |||
| 3 | * xterm.c (XTread_socket): Fix int/Lisp_Object confusion. | ||
| 4 | |||
| 5 | * process.c (DATAGRAM_CONN_P, list_processes_1) | ||
| 6 | (Fprocess_datagram_address, Fset_process_datagram_address) | ||
| 7 | (Fset_network_process_options, server_accept_connection): | ||
| 8 | Fix some int/Lisp_Object confusions (thank you union types). | ||
| 9 | |||
| 1 | 2002-04-01 Pavel Jan,Bm(Bk <Pavel@Janik.cz> | 10 | 2002-04-01 Pavel Jan,Bm(Bk <Pavel@Janik.cz> |
| 2 | 11 | ||
| 3 | * msdos.c: Rename x_autoselect_window_p to autoselect_window_p. | 12 | * msdos.c: Rename x_autoselect_window_p to autoselect_window_p. |
| 4 | 13 | ||
| 5 | * w32term.c: Likewise. | 14 | * w32term.c: Likewise. |
| 6 | (note_mouse_movement): Put code for x_autoselect_window_p in #if 0. | 15 | (note_mouse_movement): Put code for x_autoselect_window_p in #if 0. |
| 7 | 16 | ||
| 8 | * keyboard.c (Qselect_window): New symbol. | 17 | * keyboard.c (Qselect_window): New symbol. |
| 9 | (head_table): Use it. | 18 | (head_table): Use it. |
| 10 | (keys_of_keyboard): Bound select-window event to | 19 | (keys_of_keyboard): Bound select-window event to handle-select-window. |
| 11 | handle-select-window. | 20 | (kbd_buffer_get_event): Make a Lisp event from SELECT_WINDOW_EVENT. |
| 12 | (kbd_buffer_get_event): Make a Lisp event from | ||
| 13 | SELECT_WINDOW_EVENT. | ||
| 14 | 21 | ||
| 15 | * xterm.c: Rename x_autoselect_window_p to autoselect_window_p. | 22 | * xterm.c: Rename x_autoselect_window_p to autoselect_window_p. |
| 16 | (last_window): New variable. | 23 | (last_window): New variable. |
| @@ -19,8 +26,7 @@ | |||
| 19 | (XTread_socket): Generate SELECT_WINDOW_EVENTs only for | 26 | (XTread_socket): Generate SELECT_WINDOW_EVENTs only for |
| 20 | Emacs windows. | 27 | Emacs windows. |
| 21 | 28 | ||
| 22 | * termhooks.h (enum event_kind): New event type | 29 | * termhooks.h (enum event_kind): New event type `SELECT_WINDOW_EVENT'. |
| 23 | `SELECT_WINDOW_EVENT'. | ||
| 24 | 30 | ||
| 25 | 2002-03-31 Gerd Moellmann <gerd@gnu.org> | 31 | 2002-03-31 Gerd Moellmann <gerd@gnu.org> |
| 26 | 32 | ||
| @@ -36,8 +42,8 @@ | |||
| 36 | 42 | ||
| 37 | 2002-03-30 Gerd Moellmann <gerd@gnu.org> | 43 | 2002-03-30 Gerd Moellmann <gerd@gnu.org> |
| 38 | 44 | ||
| 39 | * dispnew.c (direct_output_for_insert): Call | 45 | * dispnew.c (direct_output_for_insert): |
| 40 | mark_window_display_accurate. | 46 | Call mark_window_display_accurate. |
| 41 | 47 | ||
| 42 | 2002-03-29 Jason Rumney <jasonr@gnu.org> | 48 | 2002-03-29 Jason Rumney <jasonr@gnu.org> |
| 43 | 49 | ||
diff --git a/src/process.c b/src/process.c index 3742fe23ad2..b7c5076a2a9 100644 --- a/src/process.c +++ b/src/process.c | |||
| @@ -307,7 +307,7 @@ struct sockaddr_and_len { | |||
| 307 | int len; | 307 | int len; |
| 308 | } datagram_address[MAXDESC]; | 308 | } datagram_address[MAXDESC]; |
| 309 | #define DATAGRAM_CHAN_P(chan) (datagram_address[chan].sa != 0) | 309 | #define DATAGRAM_CHAN_P(chan) (datagram_address[chan].sa != 0) |
| 310 | #define DATAGRAM_CONN_P(proc) (PROCESSP (proc) && datagram_address[XPROCESS (proc)->infd].sa != 0) | 310 | #define DATAGRAM_CONN_P(proc) (PROCESSP (proc) && datagram_address[XINT (XPROCESS (proc)->infd)].sa != 0) |
| 311 | #else | 311 | #else |
| 312 | #define DATAGRAM_CHAN_P(chan) (0) | 312 | #define DATAGRAM_CHAN_P(chan) (0) |
| 313 | #define DATAGRAM_CONN_P(proc) (0) | 313 | #define DATAGRAM_CONN_P(proc) (0) |
| @@ -1200,7 +1200,7 @@ list_processes_1 (query_only) | |||
| 1200 | if (INTEGERP (port)) | 1200 | if (INTEGERP (port)) |
| 1201 | port = Fnumber_to_string (port); | 1201 | port = Fnumber_to_string (port); |
| 1202 | sprintf (tembuf, "(network %s server on %s)\n", | 1202 | sprintf (tembuf, "(network %s server on %s)\n", |
| 1203 | (DATAGRAM_CHAN_P (p->infd) ? "datagram" : "stream"), | 1203 | (DATAGRAM_CHAN_P (XINT (p->infd)) ? "datagram" : "stream"), |
| 1204 | XSTRING (port)->data); | 1204 | XSTRING (port)->data); |
| 1205 | insert_string (tembuf); | 1205 | insert_string (tembuf); |
| 1206 | } | 1206 | } |
| @@ -1216,7 +1216,7 @@ list_processes_1 (query_only) | |||
| 1216 | host = Fnumber_to_string (host); | 1216 | host = Fnumber_to_string (host); |
| 1217 | } | 1217 | } |
| 1218 | sprintf (tembuf, "(network %s connection to %s)\n", | 1218 | sprintf (tembuf, "(network %s connection to %s)\n", |
| 1219 | (DATAGRAM_CHAN_P (p->infd) ? "datagram" : "stream"), | 1219 | (DATAGRAM_CHAN_P (XINT (p->infd)) ? "datagram" : "stream"), |
| 1220 | XSTRING (host)->data); | 1220 | XSTRING (host)->data); |
| 1221 | insert_string (tembuf); | 1221 | insert_string (tembuf); |
| 1222 | } | 1222 | } |
| @@ -2119,7 +2119,7 @@ DEFUN ("process-datagram-address", Fprocess_datagram_address, Sprocess_datagram_ | |||
| 2119 | if (!DATAGRAM_CONN_P (process)) | 2119 | if (!DATAGRAM_CONN_P (process)) |
| 2120 | return Qnil; | 2120 | return Qnil; |
| 2121 | 2121 | ||
| 2122 | channel = XPROCESS (process)->infd; | 2122 | channel = XINT (XPROCESS (process)->infd); |
| 2123 | return conv_sockaddr_to_lisp (datagram_address[channel].sa, | 2123 | return conv_sockaddr_to_lisp (datagram_address[channel].sa, |
| 2124 | datagram_address[channel].len); | 2124 | datagram_address[channel].len); |
| 2125 | } | 2125 | } |
| @@ -2139,7 +2139,7 @@ Returns nil upon error setting address, ADDRESS otherwise. */) | |||
| 2139 | if (!DATAGRAM_CONN_P (process)) | 2139 | if (!DATAGRAM_CONN_P (process)) |
| 2140 | return Qnil; | 2140 | return Qnil; |
| 2141 | 2141 | ||
| 2142 | channel = XPROCESS (process)->infd; | 2142 | channel = XINT (XPROCESS (process)->infd); |
| 2143 | 2143 | ||
| 2144 | len = get_lisp_to_sockaddr_size (address, &family); | 2144 | len = get_lisp_to_sockaddr_size (address, &family); |
| 2145 | if (datagram_address[channel].len != len) | 2145 | if (datagram_address[channel].len != len) |
| @@ -2374,10 +2374,10 @@ usage: (set-network-process-options PROCESS &rest OPTIONS) */) | |||
| 2374 | 2374 | ||
| 2375 | process = args[0]; | 2375 | process = args[0]; |
| 2376 | CHECK_PROCESS (process); | 2376 | CHECK_PROCESS (process); |
| 2377 | if (nargs > 1 && XPROCESS (process)->infd >= 0) | 2377 | if (nargs > 1 && XINT (XPROCESS (process)->infd) >= 0) |
| 2378 | { | 2378 | { |
| 2379 | opts = Flist (nargs, args); | 2379 | opts = Flist (nargs, args); |
| 2380 | set_socket_options (XPROCESS (process)->infd, opts, 0); | 2380 | set_socket_options (XINT (XPROCESS (process)->infd), opts, 0); |
| 2381 | } | 2381 | } |
| 2382 | return process; | 2382 | return process; |
| 2383 | } | 2383 | } |
| @@ -3528,7 +3528,7 @@ server_accept_connection (server, channel) | |||
| 3528 | (STRINGP (host) ? host : build_string ("-")), | 3528 | (STRINGP (host) ? host : build_string ("-")), |
| 3529 | build_string ("\n"))); | 3529 | build_string ("\n"))); |
| 3530 | 3530 | ||
| 3531 | if (p->sentinel) | 3531 | if (!NILP (p->sentinel)) |
| 3532 | exec_sentinel (proc, | 3532 | exec_sentinel (proc, |
| 3533 | concat3 (build_string ("open from "), | 3533 | concat3 (build_string ("open from "), |
| 3534 | (STRINGP (host) ? host : build_string ("-")), | 3534 | (STRINGP (host) ? host : build_string ("-")), |