From: Kenichi Handa Date: Tue, 7 May 2002 04:50:09 +0000 (+0000) Subject: (Fcall_process): Be sure to give the current buffer X-Git-Tag: emacs-pretest-23.0.90~8295^2~1864^2~928 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=ea99bcc1c79f6ec893bf5b7558541b94cff281fe;p=emacs.git (Fcall_process): Be sure to give the current buffer to decode_coding_c_string. Update PT and PT_BYTE after the insertion. --- diff --git a/src/callproc.c b/src/callproc.c index bb3df43d433..9fa97d862c1 100644 --- a/src/callproc.c +++ b/src/callproc.c @@ -770,8 +770,11 @@ usage: (call-process PROGRAM &optional INFILE BUFFER DISPLAY &rest ARGS) */) insert_1_both (bufptr, nread, nread, 0, 1, 0); else { /* We have to decode the input. */ + Lisp_Object buf; + + XSETBUFFER (buf, current_buffer); decode_coding_c_string (&process_coding, bufptr, nread, - buffer); + buf); if (display_on_the_fly && CODING_REQUIRE_DETECTION (&saved_coding) && ! CODING_REQUIRE_DETECTION (&process_coding)) @@ -793,6 +796,8 @@ usage: (call-process PROGRAM &optional INFILE BUFFER DISPLAY &rest ARGS) */) continue; } + TEMP_SET_PT_BOTH (PT + process_coding.produced_char, + PT_BYTE + process_coding.produced); nread -= process_coding.consumed; carryover = nread; if (carryover > 0)