Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT sources DOT redhat DOT com Delivered-To: mailing list cygwin AT sources DOT redhat DOT com Message-ID: <8F23E55D511AD5119A6800D0B76FDDE11E101A@cpex3.channelpoint.com> From: Troy Noble To: "'cygwin AT cygwin DOT com'" Subject: RE: Brainstorming a fix for CTRL-C handling in an emacs shell buf fer (non-TTY) Date: Mon, 7 May 2001 12:00:48 -0600 MIME-Version: 1.0 X-Mailer: Internet Mail Service (5.5.2653.19) Content-Type: text/plain; charset="iso-8859-1" X-Scanned-By: MIMEDefang 1.0 (http://www.roaringpenguin.com/mimedefang/) I was hoping you wouldn't say that ;-> I will look at it some more. I spent many hours looking at tty.cc, fhandler_termios.cc, dtable.cc, and related code over the weekend, and got wound around the axle trying to figure out where the pgid of the tty was getting set. I couldn't get the watch point to tell me when/where it was getting changed. And as you know printf is problematic during the early startup sections where it's setting up the tty itself. You're right, t->getpgid() should be 0 for a process with a pipe for stdin. There's definitely a bug lurking in there somewhere. Will let you know what I find out. BTW, do you want me to jump over to the cygwin developer list? I just don't want to annoy folks with the traffic if this is not the appropriate place to get feedback for this type of a debugging exercise. And thanks for your patience. This is my first "dive" into the internals of the cygwin DLL code. Troy -----Original Message----- From: Christopher Faylor [mailto:cgf AT redhat DOT com] Sent: Monday, May 07, 2001 11:23 AM To: 'cygwin AT cygwin DOT com' Subject: Re: Brainstorming a fix for CTRL-C handling in an emacs shell buf fer (non-TTY) On Sun, May 06, 2001 at 10:16:38PM -0600, Troy Noble wrote: >Christopher, > >Looks like t->getpgid() is OK, it's the > > t->getpgid () != myself->pid > >that's causing the behavior... and I think I understand why >now. Thanks for leading me in the right direction. > >What do you think about the patch below for exceptions.cc >instead? No extra environment variables required this time ;-> You're still fixing the symptom rather than the problem. If the program doesn't have a controlling tty then t->getpgid should be zero. If it isn't zero, then I want to know why it isn't zero. >to kill other non-cygwin child processes (like java.exe for example) >when running bash in a shell buffer. They probably had CYGWIN=tty >set. You probably already knew that, No, I didn't know that. It's difficult to understand why anyone would do something that dumb. If they do, they get what they paid for. Or, rather, I guess I'll get what they paid for because then they'll send email whining about cygwin instabilities. cgf -- Want to unsubscribe from this list? Check out: http://cygwin.com/ml/#unsubscribe-simple -- Want to unsubscribe from this list? Check out: http://cygwin.com/ml/#unsubscribe-simple