From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.devel Subject: Re: ^D is broken in shell-mode Date: Tue, 08 Jun 2010 16:22:41 -0400 Message-ID: References: NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: dough.gmane.org 1276028577 27693 80.91.229.12 (8 Jun 2010 20:22:57 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Tue, 8 Jun 2010 20:22:57 +0000 (UTC) Cc: emacs-devel@gnu.org To: Miles Bader Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Jun 08 22:22:55 2010 connect(): No such file or directory Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1OM5K2-0000eK-Qj for ged-emacs-devel@m.gmane.org; Tue, 08 Jun 2010 22:22:55 +0200 Original-Received: from localhost ([127.0.0.1]:55188 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OM5K2-0005kB-6B for ged-emacs-devel@m.gmane.org; Tue, 08 Jun 2010 16:22:54 -0400 Original-Received: from [140.186.70.92] (port=54822 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OM5Jv-0005jz-JB for emacs-devel@gnu.org; Tue, 08 Jun 2010 16:22:48 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1OM5Jt-0003g1-LZ for emacs-devel@gnu.org; Tue, 08 Jun 2010 16:22:47 -0400 Original-Received: from chene.dit.umontreal.ca ([132.204.246.20]:51343) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OM5Jr-0003fC-MM; Tue, 08 Jun 2010 16:22:43 -0400 Original-Received: from faina.iro.umontreal.ca (faina.iro.umontreal.ca [132.204.26.177]) by chene.dit.umontreal.ca (8.14.1/8.14.1) with ESMTP id o58KMghM007500; Tue, 8 Jun 2010 16:22:42 -0400 Original-Received: by faina.iro.umontreal.ca (Postfix, from userid 20848) id A137870365; Tue, 8 Jun 2010 16:22:41 -0400 (EDT) In-Reply-To: (Miles Bader's message of "Tue, 08 Jun 2010 22:16:42 +0900") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (gnu/linux) X-NAI-Spam-Score: 0 X-NAI-Spam-Rules: 1 Rules triggered RV3552=0 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:125640 Archived-At: > It now results in a literal ^D being seen by the subproces. > I vaguely recall seeing recently that emacs stopped using ICANON mode > for ptys; I presume this is the cause? Yes. > It's been a long time since I did pty programming, but I seem to recall > that at least in some pty states, doing a zero-length write in the pty > master will send an end-of-file to the slave tty. I don't recall the > details though... I really wish someone could help. At least if someone could point me to some kind of documentation that would be very helpful. The best "doc" I could find so far is the xterm source code, which I do not really understand and whose behavior I haven't been able to reproduce yet (e.g. it seems not to disable ICANON mode, and it doesn't seem to ever send EOF either, even when sending large chunks of data, yet that data doesn't get truncated, whereas when I try to to make Emacs send large amounts of data in ICANON mode without EOFs, it gets truncated). Stefan