Mercurial > emacs
comparison src/process.c @ 18540:c9470cd6de93
(Fstart_process): Call Ffind_operation_coding_system.
(Fopen_network_stream): Likewise.
| author | Kenichi Handa <handa@m17n.org> |
|---|---|
| date | Wed, 02 Jul 1997 12:54:06 +0000 |
| parents | 6f986049dff1 |
| children | 64184009811b |
comparison
equal
deleted
inserted
replaced
| 18539:8c13c54d52c8 | 18540:c9470cd6de93 |
|---|---|
| 1167 XPROCESS (proc)->encode_coding_system = Qnil; | 1167 XPROCESS (proc)->encode_coding_system = Qnil; |
| 1168 } | 1168 } |
| 1169 else | 1169 else |
| 1170 { | 1170 { |
| 1171 /* Setup coding systems for communicating with the process. */ | 1171 /* Setup coding systems for communicating with the process. */ |
| 1172 /* Qt denotes that we have not yet called Ffind_coding_system. */ | 1172 /* Qt denotes we have not yet called Ffind_operation_coding_system. */ |
| 1173 Lisp_Object coding_systems = Qt; | 1173 Lisp_Object coding_systems = Qt; |
| 1174 Lisp_Object val, *args2; | 1174 Lisp_Object val, *args2; |
| 1175 struct gcpro gcpro1; | 1175 struct gcpro gcpro1; |
| 1176 | 1176 |
| 1177 if (NILP (val = Vcoding_system_for_read)) | 1177 if (NILP (val = Vcoding_system_for_read)) |
| 1178 { | 1178 { |
| 1179 args2 = (Lisp_Object *) alloca ((nargs + 1) * sizeof *args2); | 1179 args2 = (Lisp_Object *) alloca ((nargs + 1) * sizeof *args2); |
| 1180 args2[0] = Qstart_process; | 1180 args2[0] = Qstart_process; |
| 1181 for (i = 0; i < nargs; i++) args2[i + 1] = args[i]; | 1181 for (i = 0; i < nargs; i++) args2[i + 1] = args[i]; |
| 1182 GCPRO1 (proc); | 1182 GCPRO1 (proc); |
| 1183 coding_systems = Ffind_coding_system (nargs + 1, args2); | 1183 coding_systems = Ffind_operation_coding_system (nargs + 1, args2); |
| 1184 UNGCPRO; | 1184 UNGCPRO; |
| 1185 if (CONSP (coding_systems)) | 1185 if (CONSP (coding_systems)) |
| 1186 val = XCONS (coding_systems)->car; | 1186 val = XCONS (coding_systems)->car; |
| 1187 else if (CONSP (Vdefault_process_coding_system)) | 1187 else if (CONSP (Vdefault_process_coding_system)) |
| 1188 val = XCONS (Vdefault_process_coding_system)->car; | 1188 val = XCONS (Vdefault_process_coding_system)->car; |
| 1195 { | 1195 { |
| 1196 args2 = (Lisp_Object *) alloca ((nargs + 1) * sizeof args2); | 1196 args2 = (Lisp_Object *) alloca ((nargs + 1) * sizeof args2); |
| 1197 args2[0] = Qstart_process; | 1197 args2[0] = Qstart_process; |
| 1198 for (i = 0; i < nargs; i++) args2[i + 1] = args[i]; | 1198 for (i = 0; i < nargs; i++) args2[i + 1] = args[i]; |
| 1199 GCPRO1 (proc); | 1199 GCPRO1 (proc); |
| 1200 coding_systems = Ffind_coding_system (nargs + 1, args2); | 1200 coding_systems = |
| 1201 Ffind_operation_coding_system (nargs + 1, args2); | |
| 1201 UNGCPRO; | 1202 UNGCPRO; |
| 1202 } | 1203 } |
| 1203 if (CONSP (coding_systems)) | 1204 if (CONSP (coding_systems)) |
| 1204 val = XCONS (coding_systems)->cdr; | 1205 val = XCONS (coding_systems)->cdr; |
| 1205 else if (CONSP (Vdefault_process_coding_system)) | 1206 else if (CONSP (Vdefault_process_coding_system)) |
| 1900 } | 1901 } |
| 1901 else | 1902 else |
| 1902 { | 1903 { |
| 1903 /* Setup coding systems for communicating with the network stream. */ | 1904 /* Setup coding systems for communicating with the network stream. */ |
| 1904 struct gcpro gcpro1; | 1905 struct gcpro gcpro1; |
| 1905 /* Qt denotes that we have not yet called Ffind_coding_system. */ | 1906 /* Qt denotes we have not yet called Ffind_operation_coding_system. */ |
| 1906 Lisp_Object coding_systems = Qt; | 1907 Lisp_Object coding_systems = Qt; |
| 1907 Lisp_Object args[5], val; | 1908 Lisp_Object args[5], val; |
| 1908 | 1909 |
| 1909 if (NILP (val = Vcoding_system_for_read)) | 1910 if (NILP (val = Vcoding_system_for_read)) |
| 1910 { | 1911 { |
| 1911 args[0] = Qopen_network_stream, args[1] = name, | 1912 args[0] = Qopen_network_stream, args[1] = name, |
| 1912 args[2] = buffer, args[3] = host, args[4] = service; | 1913 args[2] = buffer, args[3] = host, args[4] = service; |
| 1913 GCPRO1 (proc); | 1914 GCPRO1 (proc); |
| 1914 coding_systems = Ffind_coding_system (5, args); | 1915 coding_systems = Ffind_operation_coding_system (5, args); |
| 1915 UNGCPRO; | 1916 UNGCPRO; |
| 1916 if (CONSP (coding_systems)) | 1917 if (CONSP (coding_systems)) |
| 1917 val = XCONS (coding_systems)->car; | 1918 val = XCONS (coding_systems)->car; |
| 1918 else if (CONSP (Vdefault_process_coding_system)) | 1919 else if (CONSP (Vdefault_process_coding_system)) |
| 1919 val = XCONS (Vdefault_process_coding_system)->car; | 1920 val = XCONS (Vdefault_process_coding_system)->car; |
| 1925 if (EQ (coding_systems, Qt)) | 1926 if (EQ (coding_systems, Qt)) |
| 1926 { | 1927 { |
| 1927 args[0] = Qopen_network_stream, args[1] = name, | 1928 args[0] = Qopen_network_stream, args[1] = name, |
| 1928 args[2] = buffer, args[3] = host, args[4] = service; | 1929 args[2] = buffer, args[3] = host, args[4] = service; |
| 1929 GCPRO1 (proc); | 1930 GCPRO1 (proc); |
| 1930 coding_systems = Ffind_coding_system (5, args); | 1931 coding_systems = Ffind_operation_coding_system (5, args); |
| 1931 UNGCPRO; | 1932 UNGCPRO; |
| 1932 } | 1933 } |
| 1933 if (CONSP (coding_systems)) | 1934 if (CONSP (coding_systems)) |
| 1934 val = XCONS (coding_systems)->cdr; | 1935 val = XCONS (coding_systems)->cdr; |
| 1935 else if (CONSP (Vdefault_process_coding_system)) | 1936 else if (CONSP (Vdefault_process_coding_system)) |
