GNU bug report logs - #2148
In shell mode, comint-send-input seems to cut off at 254 characters

Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.

Package: emacs; Reported by: Richard Addison-Wood <richard <at> wetafx.co.nz>; dated Mon, 2 Feb 2009 03:30:02 UTC; Maintainer for emacs is bug-gnu-emacs <at> gnu.org.

Message received at 2148 <at> emacsbugs.donarmstrong.com:


Received: (at 2148) by emacsbugs.donarmstrong.com; 8 Apr 2009 18:33:49 +0000
From rms <at> gnu.org Wed Apr  8 11:33:49 2009
X-Spam-Checker-Version: SpamAssassin 3.2.5-bugs.debian.org_2005_01_02
	(2008-06-10) on rzlab.ucr.edu
X-Spam-Level: 
X-Spam-Bayes: score:0.5 Bayes not run. spammytokens:Tokens not available.
	hammytokens:Tokens not available.
X-Spam-Status: No, score=-3.0 required=4.0 tests=HAS_BUG_NUMBER autolearn=ham
	version=3.2.5-bugs.debian.org_2005_01_02
Received: from fencepost.gnu.org (fencepost.gnu.org [140.186.70.10])
	by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id n38IXkeW024727
	for <2148 <at> emacsbugs.donarmstrong.com>; Wed, 8 Apr 2009 11:33:48 -0700
Received: from rms by fencepost.gnu.org with local (Exim 4.67)
	(envelope-from <rms <at> gnu.org>)
	id 1Lrcan-0006hn-Qp; Wed, 08 Apr 2009 14:33:45 -0400
Content-Type: text/plain; charset=ISO-8859-15
From: Richard M Stallman <rms <at> gnu.org>
To: Stefan Monnier <monnier <at> iro.umontreal.ca>, 2148 <at> debbugs.gnu.org
CC: cyd <at> stupidchicken.com, 2148 <at> debbugs.gnu.org
In-reply-to: <jwveiw4zhd6.fsf-monnier+emacsbugreports <at> gnu.org> (message from
	Stefan Monnier on Tue, 07 Apr 2009 10:09:35 -0400)
Subject: Re: bug#2148: In shell mode,
	comint-send-input seems to cut off at 254 characters
Reply-to: rms <at> gnu.org
References: <87bpr9ul08.fsf <at> cyd.mit.edu> <jwveiw4zhd6.fsf-monnier+emacsbugreports <at> gnu.org>
Message-Id: <E1Lrcan-0006hn-Qp <at> fencepost.gnu.org>
Date: Wed, 08 Apr 2009 14:33:45 -0400

    The obvious fix is to not add this ^D.  At least I could never
    understand what it was supposed to do ("force it though"?  what does
    that mean?).

The problem is that the subprogram is reading from its tty with line
editing, so it won't receive any input until Emacs "types" one of the
few characters that says "give the input to the program".  Until that
occurs, theoretically Emacs could get rid of the pending input by
typing DEL or Backspace or C-u or C-w.

If the system's line-editing buffer gets full, everything hangs.  The
subprogram waits for a complete input line, but Emacs can't finish the
line because it's waiting for space to appear in that buffer (and
anyway the buffer has no room for more).

At least this is what was happening at the time I implemented that code.

If emacs_set_tty turns off the line editing, or turns off the
characters that could cancel input, it would be proper for the kernel
to give the characters to the subprogram right away.  Then the buffer
would never get full.  We could suggest this change in Linux.




Acknowledgement sent to rms <at> gnu.org:
Extra info received and forwarded to list. Copy sent to Emacs Bugs <bug-gnu-emacs <at> gnu.org>. Full text available.
Information forwarded to bug-submit-list <at> lists.donarmstrong.com, Emacs Bugs <bug-gnu-emacs <at> gnu.org>:
bug#2148; Package emacs. Full text available.
Severity set to `normal' from `serious' Request was from Chong Yidong <cyd <at> stupidchicken.com> to control <at> emacsbugs.donarmstrong.com. Full text available.

Message received at 2148 <at> emacsbugs.donarmstrong.com:


Received: (at 2148) by emacsbugs.donarmstrong.com; 7 Apr 2009 15:47:23 +0000
From monnier <at> iro.umontreal.ca Tue Apr  7 08:47:23 2009
X-Spam-Checker-Version: SpamAssassin 3.2.5-bugs.debian.org_2005_01_02
	(2008-06-10) on rzlab.ucr.edu
X-Spam-Level: **
X-Spam-Bayes: score:0.5 Bayes not run. spammytokens:Tokens not available.
	hammytokens:Tokens not available.
X-Spam-Status: No, score=2.6 required=4.0 tests=FOURLA,MURPHY_DRUGS_REL8,
	XIRONPORT autolearn=no version=3.2.5-bugs.debian.org_2005_01_02
Received: from ironport2-out.teksavvy.com (ironport2-out.teksavvy.com [206.248.154.182])
	by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id n37FlKV5011611
	for <2148 <at> emacsbugs.donarmstrong.com>; Tue, 7 Apr 2009 08:47:21 -0700
X-IronPort-Anti-Spam-Filtered: true
X-IronPort-Anti-Spam-Result: ArUEAFMS20lMCqib/2dsb2JhbACBUs08g30GhQ4
X-IronPort-AV: E=Sophos;i="4.39,338,1235970000"; 
   d="scan'208";a="36714992"
Received: from 76-10-168-155.dsl.teksavvy.com (HELO pastel.home) ([76.10.168.155])
  by ironport2-out.teksavvy.com with ESMTP; 07 Apr 2009 11:47:15 -0400
Received: by pastel.home (Postfix, from userid 20848)
	id EB1A780A8; Tue,  7 Apr 2009 11:47:14 -0400 (EDT)
From: Stefan Monnier <monnier <at> iro.umontreal.ca>
To: Chong Yidong <cyd <at> stupidchicken.com>
Cc: 2148 <at> debbugs.gnu.org
Subject: Re: In shell mode, comint-send-input seems to cut off at 254 characters
Message-ID: <jwvljqcwkk2.fsf-monnier+emacsbugreports <at> gnu.org>
References: <87bpr9ul08.fsf <at> cyd.mit.edu>
	<jwveiw4zhd6.fsf-monnier+emacsbugreports <at> gnu.org>
	<871vs4pmqv.fsf <at> cyd.mit.edu>
Date: Tue, 07 Apr 2009 11:47:14 -0400
In-Reply-To: <871vs4pmqv.fsf <at> cyd.mit.edu> (Chong Yidong's message of "Tue, 07
	Apr 2009 10:22:16 -0400")
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.92 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii

>> The obvious fix is to not add this ^D.  At least I could never
>> understand what it was supposed to do ("force it though"?  what does
>> that mean?).
> Ah, ok---for some reason, I thought you wrote that code, but on closer
> inspection it was written by Gerd in 2000.

Not close enough: his 2000 patch just changed indentation.  I think the
origin of this problem is:

   revno: 6577
   committer: rms
   branch nick: HEAD
   timestamp: Thu 1994-03-03 05:50:31 +0000
   message:
     Include unistd.h.
     (pty_max_bytes): New variable.
     (send_process): Send an eof after each pty_max_bytes bytes.

And clearly there was a good reason for that.  I don't know enough about
PTY programming to know what we should do.

> The current symptoms don't seem serious enough to risk changing this
> now, so I think we should do it after the release.  WDYT?

Agreed (if at all).


        Stefan




Acknowledgement sent to Stefan Monnier <monnier <at> iro.umontreal.ca>:
Extra info received and forwarded to list. Copy sent to Emacs Bugs <bug-gnu-emacs <at> gnu.org>. Full text available.
Information forwarded to bug-submit-list <at> lists.donarmstrong.com, Emacs Bugs <bug-gnu-emacs <at> gnu.org>:
bug#2148; Package emacs. Full text available.

Message received at 2148 <at> emacsbugs.donarmstrong.com:


Received: (at 2148) by emacsbugs.donarmstrong.com; 7 Apr 2009 14:20:39 +0000
From cyd <at> stupidchicken.com Tue Apr  7 07:20:39 2009
X-Spam-Checker-Version: SpamAssassin 3.2.5-bugs.debian.org_2005_01_02
	(2008-06-10) on rzlab.ucr.edu
X-Spam-Level: 
X-Spam-Bayes: score:0.5 Bayes not run. spammytokens:Tokens not available.
	hammytokens:Tokens not available.
X-Spam-Status: No, score=0.1 required=4.0 tests=FOURLA autolearn=no
	version=3.2.5-bugs.debian.org_2005_01_02
Received: from cyd.mit.edu (CYD.MIT.EDU [18.115.2.24])
	by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id n37EKavf018534
	for <2148 <at> emacsbugs.donarmstrong.com>; Tue, 7 Apr 2009 07:20:37 -0700
Received: by cyd.mit.edu (Postfix, from userid 1000)
	id 75E9957E21C; Tue,  7 Apr 2009 10:22:16 -0400 (EDT)
From: Chong Yidong <cyd <at> stupidchicken.com>
To: Stefan Monnier <monnier <at> iro.umontreal.ca>
Cc: 2148 <at> debbugs.gnu.org
Subject: Re: In shell mode, comint-send-input seems to cut off at 254 characters
References: <87bpr9ul08.fsf <at> cyd.mit.edu>
	<jwveiw4zhd6.fsf-monnier+emacsbugreports <at> gnu.org>
Date: Tue, 07 Apr 2009 10:22:16 -0400
In-Reply-To: <jwveiw4zhd6.fsf-monnier+emacsbugreports <at> gnu.org> (Stefan
	Monnier's message of "Tue, 07 Apr 2009 10:09:35 -0400")
Message-ID: <871vs4pmqv.fsf <at> cyd.mit.edu>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.91 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii

Stefan Monnier <monnier <at> iro.umontreal.ca> writes:

> The obvious fix is to not add this ^D.  At least I could never
> understand what it was supposed to do ("force it though"?  what does
> that mean?).

Ah, ok---for some reason, I thought you wrote that code, but on closer
inspection it was written by Gerd in 2000.

The current symptoms don't seem serious enough to risk changing this
now, so I think we should do it after the release.  WDYT?




Acknowledgement sent to Chong Yidong <cyd <at> stupidchicken.com>:
Extra info received and forwarded to list. Copy sent to Emacs Bugs <bug-gnu-emacs <at> gnu.org>. Full text available.
Information forwarded to bug-submit-list <at> lists.donarmstrong.com, Emacs Bugs <bug-gnu-emacs <at> gnu.org>:
bug#2148; Package emacs. Full text available.

Message received at 2148 <at> emacsbugs.donarmstrong.com:


Received: (at 2148) by emacsbugs.donarmstrong.com; 7 Apr 2009 14:09:57 +0000
From monnier <at> iro.umontreal.ca Tue Apr  7 07:09:57 2009
X-Spam-Checker-Version: SpamAssassin 3.2.5-bugs.debian.org_2005_01_02
	(2008-06-10) on rzlab.ucr.edu
X-Spam-Level: **
X-Spam-Bayes: score:0.5 Bayes not run. spammytokens:Tokens not available.
	hammytokens:Tokens not available.
X-Spam-Status: No, score=2.5 required=4.0 tests=XIRONPORT autolearn=no
	version=3.2.5-bugs.debian.org_2005_01_02
Received: from ironport2-out.teksavvy.com (ironport2-out.pppoe.ca [206.248.154.182])
	by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id n37E9st6014350
	for <2148 <at> emacsbugs.donarmstrong.com>; Tue, 7 Apr 2009 07:09:55 -0700
X-IronPort-Anti-Spam-Filtered: true
X-IronPort-Anti-Spam-Result: ArUEAA/82klMCqib/2dsb2JhbACBUs0Wg30GhQ4
X-IronPort-AV: E=Sophos;i="4.39,337,1235970000"; 
   d="scan'208";a="36706227"
Received: from 76-10-168-155.dsl.teksavvy.com (HELO ceviche.home) ([76.10.168.155])
  by ironport2-out.teksavvy.com with ESMTP; 07 Apr 2009 10:09:35 -0400
Received: by ceviche.home (Postfix, from userid 20848)
	id 4D72970A2F; Tue,  7 Apr 2009 10:09:35 -0400 (EDT)
From: Stefan Monnier <monnier <at> iro.umontreal.ca>
To: Chong Yidong <cyd <at> stupidchicken.com>
Cc: 2148 <at> debbugs.gnu.org
Subject: Re: In shell mode, comint-send-input seems to cut off at 254 characters
Message-ID: <jwveiw4zhd6.fsf-monnier+emacsbugreports <at> gnu.org>
References: <87bpr9ul08.fsf <at> cyd.mit.edu>
Date: Tue, 07 Apr 2009 10:09:35 -0400
In-Reply-To: <87bpr9ul08.fsf <at> cyd.mit.edu> (Chong Yidong's message of "Tue, 07
	Apr 2009 00:48:39 -0400")
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.92 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii

> The ^D is sent in process.c:5781.  If we are splitting a string into
> chunks for sending to the process, Emacs puts in an EOF (C-d) to "force
> it through".

> I can't think of any fix, off the top of my head.  Stefan, can you?  If
> not, we could simply document this limitation in PROBLEMS.

The obvious fix is to not add this ^D.  At least I could never
understand what it was supposed to do ("force it though"?  what does
that mean?).


        Stefan




Acknowledgement sent to Stefan Monnier <monnier <at> iro.umontreal.ca>:
Extra info received and forwarded to list. Copy sent to Emacs Bugs <bug-gnu-emacs <at> gnu.org>. Full text available.
Information forwarded to bug-submit-list <at> lists.donarmstrong.com, Emacs Bugs <bug-gnu-emacs <at> gnu.org>:
bug#2148; Package emacs. Full text available.

Message received at 2148 <at> emacsbugs.donarmstrong.com:


Received: (at 2148) by emacsbugs.donarmstrong.com; 7 Apr 2009 04:47:01 +0000
From cyd <at> stupidchicken.com Mon Apr  6 21:47:01 2009
X-Spam-Checker-Version: SpamAssassin 3.2.5-bugs.debian.org_2005_01_02
	(2008-06-10) on rzlab.ucr.edu
X-Spam-Level: *
X-Spam-Bayes: score:0.5 Bayes not run. spammytokens:Tokens not available.
	hammytokens:Tokens not available.
X-Spam-Status: No, score=1.0 required=4.0 tests=RERE autolearn=no
	version=3.2.5-bugs.debian.org_2005_01_02
Received: from cyd.mit.edu (CYD.MIT.EDU [18.115.2.24])
	by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id n374kxK2012000
	for <2148 <at> emacsbugs.donarmstrong.com>; Mon, 6 Apr 2009 21:47:00 -0700
Received: by cyd.mit.edu (Postfix, from userid 1000)
	id 35B9C57E18A; Tue,  7 Apr 2009 00:48:39 -0400 (EDT)
From: Chong Yidong <cyd <at> stupidchicken.com>
To: Stefan Monnier  <monnier <at> iro.umontreal.ca>
Cc: 2148 <at> debbugs.gnu.org
Subject: Re: Re: In shell mode, comint-send-input seems to cut off at 254 characters
Date: Tue, 07 Apr 2009 00:48:39 -0400
Message-ID: <87bpr9ul08.fsf <at> cyd.mit.edu>
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii

> [in shell mode]
> /bin/tcsh -f
> set filec
> echo [very long line]
>
> I get the strange behaviour I described before.
>
> So, in /bin/tcsh, one of the things that 'set filec' turns on is to use 
> control-D to show a list of what matches the prefix of the immediately 
> preceding word.
>
> It appears that 'send_process(proc, buf, len, object)' in process.c will 
> determine that it should send a maximum of 254 characters and will send 
> '\004' at each 254 character interval.
>
> It still seems strange to me that emacs would have this behaviour.  Is 
> that really how it should be done?  I wouldn't think that I would be the 
> only user who would be using /bin/tcsh with 'set filec'.

The ^D is sent in process.c:5781.  If we are splitting a string into
chunks for sending to the process, Emacs puts in an EOF (C-d) to "force
it through".

I can't think of any fix, off the top of my head.  Stefan, can you?  If
not, we could simply document this limitation in PROBLEMS.




Acknowledgement sent to Chong Yidong <cyd <at> stupidchicken.com>:
Extra info received and forwarded to list. Copy sent to Emacs Bugs <bug-gnu-emacs <at> gnu.org>. Full text available.
Information forwarded to bug-submit-list <at> lists.donarmstrong.com, Emacs Bugs <bug-gnu-emacs <at> gnu.org>:
bug#2148; Package emacs. Full text available.
Severity set to `serious' from `normal' Request was from Chong Yidong <cyd <at> stupidchicken.com> to control <at> emacsbugs.donarmstrong.com. Full text available.

Message received at 2148 <at> emacsbugs.donarmstrong.com:


Received: (at 2148) by emacsbugs.donarmstrong.com; 10 Feb 2009 00:13:17 +0000
From rms <at> gnu.org Mon Feb  9 16:13:17 2009
X-Spam-Checker-Version: SpamAssassin 3.2.5-bugs.debian.org_2005_01_02
	(2008-06-10) on rzlab.ucr.edu
X-Spam-Level: 
X-Spam-Bayes: score:0.5 Bayes not run. spammytokens:Tokens not available.
	hammytokens:Tokens not available.
X-Spam-Status: No, score=-3.0 required=4.0 tests=HAS_BUG_NUMBER autolearn=ham
	version=3.2.5-bugs.debian.org_2005_01_02
Received: from fencepost.gnu.org (fencepost.gnu.org [140.186.70.10])
	by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id n1A0DEYM013428
	for <2148 <at> emacsbugs.donarmstrong.com>; Mon, 9 Feb 2009 16:13:15 -0800
Received: from rms by fencepost.gnu.org with local (Exim 4.67)
	(envelope-from <rms <at> gnu.org>)
	id 1LWgDd-0004IX-Q7; Mon, 09 Feb 2009 19:11:17 -0500
Content-Type: text/plain; charset=ISO-8859-15
From: Richard M Stallman <rms <at> gnu.org>
To: Richard Addison-Wood <richard <at> wetafx.co.nz>,
        2148 <at> debbugs.gnu.org
CC: cyd <at> stupidchicken.com, 2148 <at> debbugs.gnu.org
In-reply-to: <498F83AA.1000105 <at> wetafx.co.nz> (message from Richard
	Addison-Wood on Mon, 09 Feb 2009 14:15:22 +1300)
Subject: Re: bug#2148: In shell mode,
	comint-send-input seems to cut off at 254 characters
Reply-to: rms <at> gnu.org
References:  <498F83AA.1000105 <at> wetafx.co.nz>
Message-Id: <E1LWgDd-0004IX-Q7 <at> fencepost.gnu.org>
Date: Mon, 09 Feb 2009 19:11:17 -0500

This may have to do with truncation in the input buffer
used for line-at-a-time input.




Acknowledgement sent to rms <at> gnu.org:
Extra info received and forwarded to list. Copy sent to Emacs Bugs <bug-gnu-emacs <at> gnu.org>. Full text available.
Information forwarded to bug-submit-list <at> lists.donarmstrong.com, Emacs Bugs <bug-gnu-emacs <at> gnu.org>:
bug#2148; Package emacs. Full text available.

Message received at 2148 <at> emacsbugs.donarmstrong.com:


Received: (at 2148) by emacsbugs.donarmstrong.com; 9 Feb 2009 01:15:32 +0000
From richard <at> wetafx.co.nz Sun Feb  8 17:15:32 2009
X-Spam-Checker-Version: SpamAssassin 3.2.5-bugs.debian.org_2005_01_02
	(2008-06-10) on rzlab.ucr.edu
X-Spam-Level: 
X-Spam-Bayes: score:0.5 Bayes not run. spammytokens:Tokens not available.
	hammytokens:Tokens not available.
X-Spam-Status: No, score=0.0 required=4.0 tests=none autolearn=ham
	version=3.2.5-bugs.debian.org_2005_01_02
Received: from wheke.wetafx.co.nz (wheke.wetafx.co.nz [131.203.105.13])
	by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id n191FTYb026333
	for <2148 <at> emacsbugs.donarmstrong.com>; Sun, 8 Feb 2009 17:15:30 -0800
Received: from localhost (localhost.localdomain [127.0.0.1])
	by wheke.wetafx.co.nz (Postfix) with ESMTP id EFA931ADC60C;
	Mon,  9 Feb 2009 14:15:22 +1300 (NZDT)
X-Virus-Scanned: with amavisd-new by waha at wetafx.co.nz
Received: from wheke.wetafx.co.nz ([127.0.0.1])
	by localhost (wheke.wetafx.co.nz [127.0.0.1]) (amavisd-new, port 10024)
	with ESMTP id 7F8Ed+UN0IRg; Mon,  9 Feb 2009 14:15:22 +1300 (NZDT)
Received: from set01.wetafx.co.nz (webmail.wetafx.co.nz [192.168.17.82])
	by wheke.wetafx.co.nz (Postfix) with ESMTP id ACACA1ADC60B;
	Mon,  9 Feb 2009 14:15:22 +1300 (NZDT)
Received: from localhost (localhost [127.0.0.1])
	by set01.wetafx.co.nz (Postfix) with ESMTP id 9C1E962C2DF;
	Mon,  9 Feb 2009 14:15:22 +1300 (NZDT)
X-Virus-Scanned: Debian amavisd-new at wetafx.co.nz
Received: from set01.wetafx.co.nz ([127.0.0.1])
	by localhost (set01.wetafx.co.nz [127.0.0.1]) (amavisd-new, port 10024)
	with LMTP id u-UMRLX1Lr4S; Mon,  9 Feb 2009 14:15:22 +1300 (NZDT)
Received: from [192.168.48.188] (surfperch.wetafx.co.nz [192.168.48.188])
	by set01.wetafx.co.nz (Postfix) with ESMTP id 7EBA862C2DE;
	Mon,  9 Feb 2009 14:15:22 +1300 (NZDT)
Message-ID: <498F83AA.1000105 <at> wetafx.co.nz>
Date: Mon, 09 Feb 2009 14:15:22 +1300
From: Richard Addison-Wood <richard <at> wetafx.co.nz>
User-Agent: Thunderbird 2.0.0.6 (X11/20070728)
MIME-Version: 1.0
To: Chong Yidong <cyd <at> stupidchicken.com>
CC: 2148 <at> debbugs.gnu.org
Subject: Re: In shell mode, comint-send-input seems to cut off at 254 characters
References: <87zlgz7d3o.fsf <at> cyd.mit.edu>
In-Reply-To: <87zlgz7d3o.fsf <at> cyd.mit.edu>
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit

I have more information about what is going on.

Can you see if you can reproduce it?

After opening a new shell buffer, I type:

/bin/tcsh -f

to get a tcsh shell without running custom start-up stuff.

Then, I type this:

set filec

to turn on tcsh's file completion mechanisms (since this is one of the 
settings that my start-up stuff does).

And then, when I type this:

echo 
_234567_10_234567_20_234567_30_234567_40_234567_50_234567_60_234567_70_234567_80_234567_90_23456_100_23456_110_23456_120_23456_130_23456_140_23456_150_23456_160_23456_170_23456_180_23456_190_23456_200_23456_210_23456_220_23456_230_23456_240_23456_250_23456_260

I get the strange behaviour I described before.

Alternatively, If I type this:

unset filec

I can enter that long line without a problem.

So, in /bin/tcsh, one of the things that 'set filec' turns on is to use 
control-D to show a list of what matches the prefix of the immediately 
preceding word.

It appears that 'send_process(proc, buf, len, object)' in process.c will 
determine that it should send a maximum of 254 characters and will send 
'\004' at each 254 character interval.

It still seems strange to me that emacs would have this behaviour.  Is 
that really how it should be done?  I wouldn't think that I would be the 
only user who would be using /bin/tcsh with 'set filec'.





Acknowledgement sent to Richard Addison-Wood <richard <at> wetafx.co.nz>:
Extra info received and forwarded to list. Copy sent to Emacs Bugs <bug-gnu-emacs <at> gnu.org>. Full text available.
Information forwarded to bug-submit-list <at> lists.donarmstrong.com, Emacs Bugs <bug-gnu-emacs <at> gnu.org>:
bug#2148; Package emacs. Full text available.

Message received at 2148 <at> emacsbugs.donarmstrong.com:


Received: (at 2148) by emacsbugs.donarmstrong.com; 6 Feb 2009 16:18:13 +0000
From cyd <at> stupidchicken.com Fri Feb  6 08:18:13 2009
X-Spam-Checker-Version: SpamAssassin 3.2.5-bugs.debian.org_2005_01_02
	(2008-06-10) on rzlab.ucr.edu
X-Spam-Level: 
X-Spam-Bayes: score:0.5 Bayes not run. spammytokens:Tokens not available.
	hammytokens:Tokens not available.
X-Spam-Status: No, score=0.0 required=4.0 tests=none autolearn=ham
	version=3.2.5-bugs.debian.org_2005_01_02
Received: from cyd.mit.edu (CYD.MIT.EDU [18.115.2.24])
	by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id n16GIAtT014646
	for <2148 <at> emacsbugs.donarmstrong.com>; Fri, 6 Feb 2009 08:18:11 -0800
Received: by cyd.mit.edu (Postfix, from userid 1000)
	id 88BA957E196; Fri,  6 Feb 2009 11:18:51 -0500 (EST)
From: Chong Yidong <cyd <at> stupidchicken.com>
To: Richard Addison-Wood <richard <at> wetafx.co.nz>
Cc: 2148 <at> debbugs.gnu.org
Subject: Re: In shell mode, comint-send-input seems to cut off at 254 characters
Date: Fri, 06 Feb 2009 11:18:51 -0500
Message-ID: <87zlgz7d3o.fsf <at> cyd.mit.edu>
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii

> I attempted to do this command in shell mode:
> echo
> _234567_10....
> The immediate output was:
> 0_23456_260: Command not found.
> but when I hit enter again without typing anything else, I got:
> _234567_10_234567....
> So the first 254 characters I typed got held back, and the additional
> 11 characters were sent to the inferior shell.  Further, the held back
> characters were then sent when I pressed enter again.
>
>In GNU Emacs 22.3.1 (x86_64-unknown-linux-gnu)

I can't reproduce this, on either 22.3.1 or Emacs 23.  Could you see if
the bug is present in the Emacs 23 pretest?  You can find the pretest
tarball at

 http://alpha.gnu.org/gnu/emacs/pretest/

Thanks.




Acknowledgement sent to Chong Yidong <cyd <at> stupidchicken.com>:
Extra info received and forwarded to list. Copy sent to Emacs Bugs <bug-gnu-emacs <at> gnu.org>. Full text available.
Information forwarded to bug-submit-list <at> lists.donarmstrong.com, Emacs Bugs <bug-gnu-emacs <at> gnu.org>:
bug#2148; Package emacs. Full text available.

Message received at submit <at> emacsbugs.donarmstrong.com:


Received: (at submit) by emacsbugs.donarmstrong.com; 2 Feb 2009 03:20:58 +0000
From richard <at> wetafx.co.nz Sun Feb  1 19:20:58 2009
X-Spam-Checker-Version: SpamAssassin 3.2.5-bugs.debian.org_2005_01_02
	(2008-06-10) on rzlab.ucr.edu
X-Spam-Level: 
X-Spam-Bayes: score:0.5 Bayes not run. spammytokens:Tokens not available.
	hammytokens:Tokens not available.
X-Spam-Status: No, score=0.1 required=4.0 tests=FOURLA autolearn=no
	version=3.2.5-bugs.debian.org_2005_01_02
Received: from lists.gnu.org (lists.gnu.org [199.232.76.165])
	by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id n123KsVd021039
	for <submit <at> emacsbugs.donarmstrong.com>; Sun, 1 Feb 2009 19:20:56 -0800
Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43)
	id 1LTpMk-0005uU-3u
	for bug-gnu-emacs <at> gnu.org; Sun, 01 Feb 2009 22:20:54 -0500
Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43)
	id 1LTpMg-0005uI-C8
	for bug-gnu-emacs <at> gnu.org; Sun, 01 Feb 2009 22:20:52 -0500
Received: from [199.232.76.173] (port=59783 helo=monty-python.gnu.org)
	by lists.gnu.org with esmtp (Exim 4.43)
	id 1LTpMg-0005uF-62
	for bug-gnu-emacs <at> gnu.org; Sun, 01 Feb 2009 22:20:50 -0500
Received: from wheke.wetafx.co.nz ([131.203.105.13]:36042)
	by monty-python.gnu.org with esmtp (Exim 4.60)
	(envelope-from <richard <at> wetafx.co.nz>)
	id 1LTpMf-0001cD-9h
	for bug-gnu-emacs <at> gnu.org; Sun, 01 Feb 2009 22:20:50 -0500
Received: from localhost (localhost.localdomain [127.0.0.1])
	by wheke.wetafx.co.nz (Postfix) with ESMTP id 6A1CC1ADC5B2
	for <bug-gnu-emacs <at> gnu.org>; Mon,  2 Feb 2009 16:20:37 +1300 (NZDT)
X-Virus-Scanned: with amavisd-new by waha at wetafx.co.nz
Received: from wheke.wetafx.co.nz ([127.0.0.1])
	by localhost (wheke.wetafx.co.nz [127.0.0.1]) (amavisd-new, port 10024)
	with ESMTP id yt2pFOaQSHj6; Mon,  2 Feb 2009 16:20:06 +1300 (NZDT)
Received: from set01.wetafx.co.nz (webmail.wetafx.co.nz [192.168.17.82])
	by wheke.wetafx.co.nz (Postfix) with ESMTP id 889431ADC361
	for <bug-gnu-emacs <at> gnu.org>; Mon,  2 Feb 2009 16:20:06 +1300 (NZDT)
Received: from localhost (localhost [127.0.0.1])
	by set01.wetafx.co.nz (Postfix) with ESMTP id 5DC6162C8CB
	for <bug-gnu-emacs <at> gnu.org>; Mon,  2 Feb 2009 16:20:06 +1300 (NZDT)
X-Virus-Scanned: Debian amavisd-new at wetafx.co.nz
Received: from set01.wetafx.co.nz ([127.0.0.1])
	by localhost (set01.wetafx.co.nz [127.0.0.1]) (amavisd-new, port 10024)
	with LMTP id FlVLPAqANadt for <bug-gnu-emacs <at> gnu.org>;
	Mon,  2 Feb 2009 16:20:06 +1300 (NZDT)
Received: from surfperch.wetafx.co.nz (surfperch.wetafx.co.nz [192.168.48.188])
	by set01.wetafx.co.nz (Postfix) with ESMTP id 3D65D62C8C6
	for <bug-gnu-emacs <at> gnu.org>; Mon,  2 Feb 2009 16:20:06 +1300 (NZDT)
Received: by surfperch.wetafx.co.nz (Postfix, from userid 2069)
	id 39140958D3E; Mon,  2 Feb 2009 16:20:06 +1300 (NZDT)
From: Richard Addison-Wood <richard <at> wetafx.co.nz>
To: bug-gnu-emacs <at> gnu.org
Subject: In shell mode, comint-send-input seems to cut off at 254 characters
Message-Id: <20090202032006.39140958D3E <at> surfperch.wetafx.co.nz>
Date: Mon,  2 Feb 2009 16:20:06 +1300 (NZDT)
X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 1)

I attempted to do this command in shell mode:

echo _234567_10_234567_20_234567_30_234567_40_234567_50_234567_60_234567_70_234567_80_234567_90_23456_100_23456_110_23456_120_23456_130_23456_140_23456_150_23456_160_23456_170_23456_180_23456_190_23456_200_23456_210_23456_220_23456_230_23456_240_23456_250_23456_260

The immediate output was:

0_23456_260: Command not found.

but when I hit enter again without typing anything else, I got:

_234567_10_234567_20_234567_30_234567_40_234567_50_234567_60_234567_70_234567_80_234567_90_23456_100_23456_110_23456_120_23456_130_23456_140_23456_150_23456_160_23456_170_23456_180_23456_190_23456_200_23456_210_23456_220_23456_230_23456_240_23456_25

So the first 254 characters I typed got held back, and the additional 11 characters were sent to the inferior shell.  Further, the held back characters were then sent when I pressed enter again.

So this is what the buffer looked like:

====================
>echo _234567_10_234567_20_234567_30_234567_40_234567_50_234567_60_234567_70_234567_80_234567_90_23456_100_23456_110_23456_120_23456_130_23456_140_23456_150_23456_160_23456_170_23456_180_23456_190_23456_200_23456_210_23456_220_23456_230_23456_240_23456_250_23456_260
echo _234567_10_234567_20_234567_30_234567_40_234567_50_234567_60_234567_70_234567_80_234567_90_23456_100_23456_110_23456_120_23456_130_23456_140_23456_150_23456_160_23456_170_23456_180_23456_190_23456_200_23456_210_23456_220_23456_230_23456_240_23456_250_23456_260

>0_23456_260: Command not found.
>

_234567_10_234567_20_234567_30_234567_40_234567_50_234567_60_234567_70_234567_80_234567_90_23456_100_23456_110_23456_120_23456_130_23456_140_23456_150_23456_160_23456_170_23456_180_23456_190_23456_200_23456_210_23456_220_23456_230_23456_240_23456_25
>
====================

I would count this as very unexpected and dangerous behaviour.


In GNU Emacs 22.3.1 (x86_64-unknown-linux-gnu)
 of 2008-09-15 on lambretta
Windowing system distributor `The X.Org Foundation', version 11.0.70200000
configured using `configure  '--prefix=/vol/apps_master/apps.Linux64/emacs-22.3_64''

Important settings:
  value of $LC_ALL: nil
  value of $LC_COLLATE: nil
  value of $LC_CTYPE: nil
  value of $LC_MESSAGES: nil
  value of $LC_MONETARY: nil
  value of $LC_NUMERIC: nil
  value of $LC_TIME: nil
  value of $LANG: nil
  locale-coding-system: nil
  default-enable-multibyte-characters: t

Major mode: Shell

Minor modes in effect:
  shell-dirtrack-mode: t
  tooltip-mode: t
  mouse-wheel-mode: t
  menu-bar-mode: t
  file-name-shadow-mode: t
  global-font-lock-mode: t
  font-lock-mode: t
  blink-cursor-mode: t
  unify-8859-on-encoding-mode: t
  utf-translate-cjk-mode: t
  auto-compression-mode: t
  line-number-mode: t

Recent input:
<help-echo> <help-echo> <help-echo> <help-echo> M-x 
s h e l l <return> <down-mouse-2> <mouse-2> <return> 
<return> M-x r e p o r t - e m a c s - b u g <retu
rn>

Recent messages:
("/vol/apps/emacs-22.3_64/bin/emacs" "--no-init")
For information about GNU Emacs and the GNU system, type C-h C-a.
Loading shell...done
Mark set
Loading emacsbug...
Loading regexp-opt...done
Loading emacsbug...done





Acknowledgement sent to Richard Addison-Wood <richard <at> wetafx.co.nz>:
New bug report received and forwarded. Copy sent to Emacs Bugs <bug-gnu-emacs <at> gnu.org>. Full text available.
Report forwarded to bug-submit-list <at> lists.donarmstrong.com, Emacs Bugs <bug-gnu-emacs <at> gnu.org>:
bug#2148; Package emacs. Full text available.
Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.
Last modified: Tue, 20 Sep 2011 19:45:02 UTC

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