From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Steven Tamm Newsgroups: gmane.emacs.devel Subject: process-connection-type nil & gdb (was Re: C-c C-c killing gdb on OS/X) Date: Tue, 25 Nov 2003 09:02:45 -0800 Sender: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Message-ID: <307A721B-1F69-11D8-B29E-00039390AB82@mac.com> References: NNTP-Posting-Host: deer.gmane.org Mime-Version: 1.0 (Apple Message framework v553) Content-Type: text/plain; charset=US-ASCII; format=flowed Content-Transfer-Encoding: 7bit X-Trace: sea.gmane.org 1069780203 10911 80.91.224.253 (25 Nov 2003 17:10:03 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Tue, 25 Nov 2003 17:10:03 +0000 (UTC) Cc: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Tue Nov 25 18:10:00 2003 Return-path: Original-Received: from quimby.gnus.org ([80.91.224.244]) by deer.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 1AOghL-0006rd-00 for ; Tue, 25 Nov 2003 18:09:59 +0100 Original-Received: from monty-python.gnu.org ([199.232.76.173]) by quimby.gnus.org with esmtp (Exim 3.35 #1 (Debian)) id 1AOghL-0003RP-00 for ; Tue, 25 Nov 2003 18:09:59 +0100 Original-Received: from localhost ([127.0.0.1] helo=monty-python.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.24) id 1AOhct-0007Se-S8 for emacs-devel@quimby.gnus.org; Tue, 25 Nov 2003 13:09:27 -0500 Original-Received: from list by monty-python.gnu.org with tmda-scanned (Exim 4.24) id 1AOhaP-0006vL-9i for emacs-devel@gnu.org; Tue, 25 Nov 2003 13:06:53 -0500 Original-Received: from mail by monty-python.gnu.org with spam-scanned (Exim 4.24) id 1AOhZd-0006cC-Mp for emacs-devel@gnu.org; Tue, 25 Nov 2003 13:06:37 -0500 Original-Received: from [199.232.41.8] (helo=mx20.gnu.org) by monty-python.gnu.org with esmtp (TLSv1:DES-CBC3-SHA:168) (Exim 4.24) id 1AOhZd-0006bQ-FD; Tue, 25 Nov 2003 13:06:05 -0500 Original-Received: from [17.250.248.97] (helo=smtpout.mac.com) by mx20.gnu.org with esmtp (Exim 4.24) id 1AOgaP-0005Tb-Lq; Tue, 25 Nov 2003 12:02:49 -0500 Original-Received: from mac.com (smtpin08-en2 [10.13.10.153]) by smtpout.mac.com (Xserve/MantshX 2.0) with ESMTP id hAPH2liQ012572; Tue, 25 Nov 2003 09:02:47 -0800 (PST) Original-Received: from mac.com (c-67-169-52-219.client.comcast.net [67.169.52.219]) (authenticated bits=0) by mac.com (Xserve/smtpin08/MantshX 3.0) with ESMTP id hAPH2kxO001011; Tue, 25 Nov 2003 09:02:47 -0800 (PST) Original-To: John Wiegley In-Reply-To: X-Mailer: Apple Mail (2.553) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.2 Precedence: list List-Id: Emacs development discussions. List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Xref: main.gmane.org gmane.emacs.devel:18111 X-Report-Spam: http://spam.gmane.org/gmane.emacs.devel:18111 I noticed this bug a while ago in the carbon port, and it works correctly with both X11 and the terminal emacs. It has to do with the (setq process-connection-type nil) problem. With X & the terminal the subprocesses are allocated with a pty, while with carbon they are allocated with pipes. So if you (setq process-connection-type t), gdb will work; and if you (setq process-connection-type nil) in X11 and the terminal, it will fail and will probably fail on other platforms as well. The "real bug" is that process-connection-type needs to be nil for darwin due to a bug in the pty implementation. I'm not that familiar with the process code, nor with ptys, so I have no idea what is going wrong. Can someone else look and figure out what the problem with interrupting gdb with pipes is? Thanks, -Steven On Thursday, November 20, 2003, at 05:43 PM, John Wiegley wrote: > To any of the Mac developers: > > If I write a program that waits in a loop, and hit C-c C-c while in > gdb under gud, gdb will terminate with: > > C-c C-c > Debugger finished > > But I do the same thing in the Terminal, it interrupts the program as > I expect. > > Ideas? I checked process.c, and it doesn't seem that anything is > being done differently for darwin. > > John > > > _______________________________________________ > Emacs-devel mailing list > Emacs-devel@gnu.org > http://mail.gnu.org/mailman/listinfo/emacs-devel