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 Date: Thu, 28 Jun 2001 22:06:02 -0400 From: Christopher Faylor To: Tak Ota Cc: cygwin AT cygwin DOT com, gdb AT sources DOT redhat DOT com, jimb AT redhat DOT com Subject: Re: gdb run < file Message-ID: <20010628220602.A3596@redhat.com> Reply-To: cygwin AT cygwin DOT com, gdb AT sources DOT redhat DOT com Mail-Followup-To: Tak Ota , cygwin AT cygwin DOT com, gdb AT sources DOT redhat DOT com, jimb AT redhat DOT com References: <20010626 DOT 234402 DOT 21347360 DOT Takaaki DOT Ota AT am DOT sony DOT com> <20010627025036 DOT B20160 AT redhat DOT com> <20010627 DOT 235700 DOT 01365880 DOT Takaaki DOT Ota AT am DOT sony DOT com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.3.11i In-Reply-To: <20010627.235700.01365880.Takaaki.Ota@am.sony.com>; from Takaaki.Ota@am.sony.com on Wed, Jun 27, 2001 at 11:57:00PM -0700 I'm sorry but I don't think that this is the correct way to deal with this. I think that gdb normally handles things like redirection and globbing by starting inferior processes via the user's shell. Then it uses some kind of "follow fork" method to notice when the process is finally started. It just occurred to me that Windows has the capability (check out the CreateProcess call) to do this so I think it makes sense to use gdb's standard method for dealing with this problem. I don't have any specific pointers since I'm not familiar with the code in question, but I've Cc'ed the gdb mailing list in case someone can offer advice. I should point out that you'll need to have an assignment on file with the FSF for your changes to be officially incorporated into gdb. I've Cc'ed the person responsible for gdb assignments in this email. cgf On Wed, Jun 27, 2001 at 11:57:00PM -0700, Tak Ota wrote: >Since this is the first time for me to look at gdb source it took a >while to get to the right place to tackle. Thank to Source Navigator, >eventually I found win32-nat.c was the one I needed to fix. The fix >itself is quite straight forward. > >Please see the patch to win32-nat.c in gdb-20010428-1 at the end of >this message. I am not quite satisfied with the argument parsing part >but at least it fulfills what I wanted. Please improve it if you have >better idea. > >However I have verified this works, my testing environment is fairly >limited. Please verify it in various different configuration. > >-Tak > >On Wed, 27 Jun 2001 02:50:36 -0400, Christopher Faylor wrote: > >> On Tue, Jun 26, 2001 at 11:44:02PM -0700, Tak Ota wrote: >> >I encountered a problem in gdb. >> > >> >(gdb) run < file >> > >> >does not change the process stdin to the file. >> >> Yep. That's a limitation in windows gdb. >> >> >I just started looking into gdb source code for the first time in my >> >left. For now I found top.c has command loop but the size of the code >> >is so overwhelming. So I thought reporting the incident first may >> >solve the problem way before I can find the cause and fix. >> >> No one is working on this, currently. If you can provide a fix it would >> be appreciated. I don't know of any easy way to get this functionality, >> though. -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Bug reporting: http://cygwin.com/bugs.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/