aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/process.c18
1 files changed, 5 insertions, 13 deletions
diff --git a/src/process.c b/src/process.c
index 4e2717577cd..1960e6a914c 100644
--- a/src/process.c
+++ b/src/process.c
@@ -696,8 +696,6 @@ setup_process_coding_systems (process)
696 = (struct coding_system *) xmalloc (sizeof (struct coding_system)); 696 = (struct coding_system *) xmalloc (sizeof (struct coding_system));
697 setup_coding_system (p->encode_coding_system, 697 setup_coding_system (p->encode_coding_system,
698 proc_encode_coding_system[outch]); 698 proc_encode_coding_system[outch]);
699 if (proc_encode_coding_system[outch]->eol_type == CODING_EOL_UNDECIDED)
700 proc_encode_coding_system[outch]->eol_type = system_eol_type;
701} 699}
702 700
703DEFUN ("processp", Fprocessp, Sprocessp, 1, 1, 0, 701DEFUN ("processp", Fprocessp, Sprocessp, 1, 1, 0,
@@ -5066,13 +5064,10 @@ read_process_output (proc, channel)
5066 if (NILP (p->encode_coding_system) 5064 if (NILP (p->encode_coding_system)
5067 && proc_encode_coding_system[XINT (p->outfd)]) 5065 && proc_encode_coding_system[XINT (p->outfd)])
5068 { 5066 {
5069 p->encode_coding_system = Vlast_coding_system_used; 5067 p->encode_coding_system
5068 = coding_inherit_eol_type (Vlast_coding_system_used, Qnil);
5070 setup_coding_system (p->encode_coding_system, 5069 setup_coding_system (p->encode_coding_system,
5071 proc_encode_coding_system[XINT (p->outfd)]); 5070 proc_encode_coding_system[XINT (p->outfd)]);
5072 if (proc_encode_coding_system[XINT (p->outfd)]->eol_type
5073 == CODING_EOL_UNDECIDED)
5074 proc_encode_coding_system[XINT (p->outfd)]->eol_type
5075 = system_eol_type;
5076 } 5071 }
5077 } 5072 }
5078 5073
@@ -5179,13 +5174,10 @@ read_process_output (proc, channel)
5179 if (NILP (p->encode_coding_system) 5174 if (NILP (p->encode_coding_system)
5180 && proc_encode_coding_system[XINT (p->outfd)]) 5175 && proc_encode_coding_system[XINT (p->outfd)])
5181 { 5176 {
5182 p->encode_coding_system = Vlast_coding_system_used; 5177 p->encode_coding_system
5178 = coding_inherit_eol_type (Vlast_coding_system_used, Qnil);
5183 setup_coding_system (p->encode_coding_system, 5179 setup_coding_system (p->encode_coding_system,
5184 proc_encode_coding_system[XINT (p->outfd)]); 5180 proc_encode_coding_system[XINT (p->outfd)]);
5185 if (proc_encode_coding_system[XINT (p->outfd)]->eol_type
5186 == CODING_EOL_UNDECIDED)
5187 proc_encode_coding_system[XINT (p->outfd)]->eol_type
5188 = system_eol_type;
5189 } 5181 }
5190 } 5182 }
5191 if (coding->carryover_bytes > 0) 5183 if (coding->carryover_bytes > 0)
@@ -6698,7 +6690,7 @@ encode subprocess input. */)
6698 error ("Output file descriptor of %s closed", SDATA (p->name)); 6690 error ("Output file descriptor of %s closed", SDATA (p->name));
6699 Fcheck_coding_system (decoding); 6691 Fcheck_coding_system (decoding);
6700 Fcheck_coding_system (encoding); 6692 Fcheck_coding_system (encoding);
6701 6693 encoding = coding_inherit_eol_type (encoding, Qnil);
6702 p->decode_coding_system = decoding; 6694 p->decode_coding_system = decoding;
6703 p->encode_coding_system = encoding; 6695 p->encode_coding_system = encoding;
6704 setup_process_coding_systems (process); 6696 setup_process_coding_systems (process);