delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2014/05/14/11:26:18

X-Recipient: archive-cygwin AT delorie DOT com
DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id
:list-unsubscribe:list-subscribe:list-archive:list-post
:list-help:sender:date:from:to:subject:message-id:reply-to
:references:mime-version:content-type:in-reply-to; q=dns; s=
default; b=R0jQSS9LLo27W3CwCVUGiMrY7MUThp80eJCYetsGPGxFUCKrPvVOv
wKyzh1ssNtMVr4dLOV8sctztVKaGPykHrrce7hBEOgvTIffMoyYLhy1BojGP1dUn
khMDwmeo1S0V4fKoY+T2l5lDmgjVKBrotioznMa3L2sRVNYo7yREY0=
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id
:list-unsubscribe:list-subscribe:list-archive:list-post
:list-help:sender:date:from:to:subject:message-id:reply-to
:references:mime-version:content-type:in-reply-to; s=default;
bh=9axNB/tfG6W3fpQcmVXw0BJ0kdY=; b=ZWRhm1MCud4M6vxbNjmO9xe1bcfq
uZyRyFGSt6yPjBki3/uRUIbGQQiguhLJp5spoC7FgDO5rBfcn+ZdJEyGYYTGVIA5
LuAvYr07SIHNYc/ALHtKOPYL06LQ244SwzTxLPulGEeVYo3yZ8eTcF2rGMHbau2n
6V5MecO5ildROTY=
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com
Authentication-Results: sourceware.org; auth=none
X-Virus-Found: No
X-Spam-SWARE-Status: No, score=-5.9 required=5.0 tests=AWL,BAYES_00 autolearn=ham version=3.3.2
X-HELO: calimero.vinschen.de
Date: Wed, 14 May 2014 17:25:58 +0200
From: Corinna Vinschen <corinna-cygwin AT cygwin DOT com>
To: cygwin AT cygwin DOT com
Subject: Re: Debugging sub-processes with gdb
Message-ID: <20140514152558.GG2436@calimero.vinschen.de>
Reply-To: cygwin AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
References: <f5boaz0e6qb DOT fsf AT troutbeck DOT inf DOT ed DOT ac DOT uk>
MIME-Version: 1.0
In-Reply-To: <f5boaz0e6qb.fsf@troutbeck.inf.ed.ac.uk>
User-Agent: Mutt/1.5.23 (2014-03-12)

--uzBRzHoDzRCefDxE
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On May 14 16:10, Henry S. Thompson wrote:
> I'm trying to debug a problem with xemacs that involves the child
> process forked when you execute M-x shell.
>=20
> None of the mechanisms in the gdb documentation for choosing to step
> into the child process (instead of the parent) after a fork() seem to
> work for me.  That is, in particular, setting follow-for-mode to child
> still leaves me in the parent after stepping over a fork().
>=20
> Setting detach-on-fork to 'off' also seems to have no effect.
>=20
> Have I misunderstood something, or does this aspect of gdb just not
> work under cygwin (x86_64, 1.7.29-2)?

No, it doesn't, it has never been implemented.  This would require
some extensions to GDB as well as the Cygwin DLL, given that Windows
is not quite up to speed in terms of fork.

As a workaround, you could tweka emacs to sleep at certain points in the
code, and then attach to the child process with a second GDB.  Granted,
it's a bit of a hassle, but it works.


Corinna

--=20
Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Maintainer                 cygwin AT cygwin DOT com
Red Hat

--uzBRzHoDzRCefDxE
Content-Type: application/pgp-signature

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1

iQIcBAEBAgAGBQJTc4sGAAoJEPU2Bp2uRE+g5j0P/juio/f+UT8bxDuA/htQrqqv
2wbltkyJajc7V6yXA/I5CTyDCJveOcfB77mz86IsDucHvsa1Evoph6NK9CHiglVp
wGBh1YWIchEbyv9FdgRPK6wBZuNMaIgaOYZYLpCEeA7+wVKnGcR5tFaZnsyWInpU
PSSxvqA/xNx6zHk4AKgC+yPRAnB8SH7Dyq2SZM05uUU1kvAZo1gSCIAeyjbg7YBd
PcAa2YMhzhX7RgE1q2U+blQx2u1xlbvEPDCEGxcszBathRlaofuXvNyKK0sUf6RM
0IV2Kh4HuHFxmtxAaUrC4WC5D4hYOc17v8RuP7RXabm4YtKzAHF/vRTDUXml9FSl
qYqKfoKtVE3SsBqNSTdg+RGrpCZa3QLpYN9c8WuxfRrHAr8bwfQQ9bv5U20dD0jP
uxXbCDOj0vjMPPZ+jLMTFvE0SP6oMQjFv+CQEIJ64lFJbHdcBF68PV3YIYT2XzMH
rrYV2RSX9LJRqaq4oNv4ajx/2tvV6K9hmBjm2LwAHZ7Fy/Da4FQg+ze5znJPaTp3
MIeS8yqvq0bkZTzbQCl/509KL4LegHgMNgeMEVWfHF0/t0KAINhmBiXT6F6qvErN
Qf/7VQEDRzhvwruuxBV310YtylUkoQ7HVT2mztKM0lYd+43tsd4D6fsS9Cl9HGkq
AbALGEYpgTZ1eyBwvktJ
=TuWC
-----END PGP SIGNATURE-----

--uzBRzHoDzRCefDxE--

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019