GNU bug report logs - #6800
23.1; EOT / ^D inserted into comint input string

Previous Next

Package: emacs;

Reported by: David Fox <ddssff <at> gmail.com>

Date: Thu, 5 Aug 2010 15:14:02 UTC

Severity: normal

Merged with 7078

Found in versions 23.1, 24.0.50, 24.0.90

Done: David Fox <ddssff <at> gmail.com>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: help-debbugs <at> gnu.org (GNU bug Tracking System)
To: David Fox <ddssff <at> gmail.com>
Cc: tracker <at> debbugs.gnu.org
Subject: bug#7078: closed (24.0.50; process-send-string doesn't work with
 long lines on Solaris)
Date: Fri, 12 Aug 2016 19:53:02 +0000
[Message part 1 (text/plain, inline)]
Your message dated Fri, 12 Aug 2016 11:40:03 -0700
with message-id <CAJN_RF4RQtWdP_E-yycZC4NQXzNU4zPKocg10ZYrKXcYm_snEw <at> mail.gmail.com>
and subject line Re: bug#6800: 23.1; EOT / ^D inserted into comint input string
has caused the debbugs.gnu.org bug report #6800,
regarding 24.0.50; process-send-string doesn't work with long lines on Solaris
to be marked as done.

(If you believe you have received this mail in error, please contact
help-debbugs <at> gnu.org.)


-- 
6800: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=6800
GNU Bug Tracking System
Contact help-debbugs <at> gnu.org with problems
[Message part 2 (message/rfc822, inline)]
From: Knut Anders Hatlen <kahatlen <at> gmail.com>
To: bug-gnu-emacs <at> gnu.org
Subject: 24.0.50; process-send-string doesn't work with long lines on Solaris
Date: Tue, 21 Sep 2010 00:18:30 +0200
With Emacs 24 on Solaris, the code below will insert ^G into the current
buffer. With Emacs 23.2, and with Emacs 24 on Linux, it will insert 257
a's into the current buffer, which is the expected behaviour. The
problem is only seen if the string passed to process-send-string
contains lines that exceed 256 characters.

(let ((process (start-process "cat" (current-buffer) "cat")))
  (process-send-string process (format "%s\n" (make-string 257 ?a))))

The bug was introduced with this change:

revno: 99890
committer: Stefan Monnier <monnier <at> iro.umontreal.ca>
branch nick: trunk
timestamp: Mon 2010-04-12 22:07:48 -0400
message:
  Try to solve the problem of spurious EOF chars in long lines of text
  sent to interactive subprocesses.
  * sysdep.c (child_setup_tty): Do not enable ICANON any more.
  (system_process_attributes): Remove unused var `ttotal'.
  * process.c (send_process): Don't bother breaking long line with EOF
  chars when talking to ttys any more.
  (wait_reading_process_output): Output a warning when called in such
  a way that it could block without being interruptible.


-- 
Knut Anders


[Message part 3 (message/rfc822, inline)]
From: David Fox <ddssff <at> gmail.com>
To: Alan Third <alan <at> idiocy.org>
Cc: 6800-done <at> debbugs.gnu.org, Stefan Monnier <monnier <at> iro.umontreal.ca>
Subject: Re: bug#6800: 23.1; EOT / ^D inserted into comint input string
Date: Fri, 12 Aug 2016 11:40:03 -0700
[Message part 4 (text/plain, inline)]
On Fri, Aug 12, 2016 at 11:36 AM, Alan Third <alan <at> idiocy.org> wrote:

> Stefan Monnier <monnier <at> iro.umontreal.ca> writes:
>
> >> When an input longer than 255 characters is typed into comint (or
> >> shell) an EOT character (ascii 4, ^D) is inserted into the string.
> >> This can cause an error depending how the sub process handles these
> >> extra characters.  For example, GHC doesn't like it when an EOT
> >> appears inside of a string:
> >
> > I believe this bug is fixed on the Emacs trunk (to become Emacs-24), but
> > the fix may introduce other problems.  Apparently nobody knows how to
> > fix it right and there is about as much as no documentation at all on
> > this part of the behavior of ttys.
>
> IIRC this code is no longer in Emacs. I'll close this bug.
>
> --
> Alan Third
>

I do know that commands longer than 4096 characters are truncated in emacs
24.3.1
[Message part 5 (text/html, inline)]

This bug report was last modified 8 years and 286 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.