From: David Kastrup <dak@gnu.org> Date: Sat, 17 May 2003 20:03:22 +0000 (+0000) Subject: (read_process_output): Back out change from 2003-03-09. X-Git-Tag: ttn-vms-21-2-B4~10120 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=47714441724d5579d844c9ef4730dda10f02d2c9;p=emacs.git (read_process_output): Back out change from 2003-03-09. --- diff --git a/src/process.c b/src/process.c index 6dc052e716b..9790b7d29a6 100644 --- a/src/process.c +++ b/src/process.c @@ -4463,18 +4463,18 @@ read_process_output (proc, channel) if (DATAGRAM_CHAN_P (channel)) { int len = datagram_address[channel].len; - nbytes = recvfrom (channel, chars + carryover, readmax, + nbytes = recvfrom (channel, chars + carryover, readmax - carryover, 0, datagram_address[channel].sa, &len); } else #endif if (proc_buffered_char[channel] < 0) - nbytes = emacs_read (channel, chars + carryover, readmax); + nbytes = emacs_read (channel, chars + carryover, readmax - carryover); else { chars[carryover] = proc_buffered_char[channel]; proc_buffered_char[channel] = -1; - nbytes = emacs_read (channel, chars + carryover + 1, readmax - 1); + nbytes = emacs_read (channel, chars + carryover + 1, readmax - 1 - carryover); if (nbytes < 0) nbytes = 1; else