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=tl2irot2NdmojOkBI0+4ddQRz1r2Xljdf/ll/Hbte4oalmLUdVaHW ZYJSV+8Cz4ttJ4sQnqnmEFA6GSLQUyELc3da6XFTaPITQC1oOwU5HHt7HQGAm71l u+3DjAG2MqKjyPxqdHHW4K9SZUKzQteNUSal0A9JG81HhvJHefFpyY= 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=2VTh5MMrKlfJkTTtOYFLpBgu9sg=; b=h0wjZVUT9FJFZ5XF6oG/LCNmDOG1 iHsLiyN3Wpea2Uqb+KvFRUV95imLpZxfsu4Ye7DnaBPXCbQgITVcozj1rsl+vN9n +f8nUcwXaHaovEv3AKPePEZXrLXCSAu3NxzPGlCjNPv7RTxn+ZJjJHjmFS/WQFR2 CX5k1m3PDNfBfCw= Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , 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-Spam-SWARE-Status: No, score=-104.3 required=5.0 tests=AWL,BAYES_00,GOOD_FROM_CORINNA_CYGWIN,RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.1 spammy=HX-Languages-Length:1550 X-HELO: mout.kundenserver.de Date: Fri, 2 Aug 2019 17:04:12 +0200 From: Corinna Vinschen To: cygwin AT cygwin DOT com Subject: Re: Regression (last snapshot) Message-ID: <20190802150412.GE11632@calimero.vinschen.de> Reply-To: cygwin AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com References: <8e57d4da-722d-1b9a-bd28-5f96ed182f6a AT cornell DOT edu> <0a09679b-1a0f-613b-04c8-1a63da8a00c2 AT cornell DOT edu> <33aead20-540c-ee3b-0d38-ff053fbac040 AT dronecode DOT org DOT uk> <12269538-c387-1f1e-ab5a-b36b60d09937 AT cornell DOT edu> <20190801160440 DOT GC11632 AT calimero DOT vinschen DOT de> <19e73527-cb9a-a106-a57a-2895b8a520c9 AT cornell DOT edu> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="R0SsnouPYaG+7rP6" Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.11.3 (2019-02-01) --R0SsnouPYaG+7rP6 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Aug 2 14:34, Ken Brown wrote: > On 8/1/2019 10:32 PM, Ken Brown wrote: > > On 8/1/2019 5:17 PM, Ken Brown wrote: > >> On 8/1/2019 12:04 PM, Corinna Vinschen wrote: > >>> On Aug 1 10:38, Eric Blake wrote: > >>>> Could it be a case of xwin-xdg-menu calling signal(SIGPIPE, SIG_IGN)= or > >>>> similar, and accidentally letting grep inherit the ignored SIGPIPE? > >>> > >>> execve doesn't propagate the signal dispositions, they get reset to > >>> default. > >> > > I just built a version of grep in which I added 'signal(SIGPIPE, SIG_DF= L)', and > > the error is gone. So it looks like grep has in fact been receiving SI= GPIPE, > > and for some reason it is not using the default signal handler for SIGP= IPE in a > > terminal started by xwin-xdg-menu. Could this be a gtk issue? Does it= mess > > with the signal handlers? >=20 > I think I've finally got it. >=20 > First of all, here's what POSIX says about signal handlers after an exec: >=20 > "Signals set to the default action (SIG_DFL) in the calling process=20 > image shall be set to the default action in the new process image.=20 > Except for SIGCHLD, signals set to be ignored (SIG_IGN) by the calling=20 > process image shall be set to be ignored by the new process image.=20 > Signals set to be caught by the calling process image shall be set to=20 > the default action in the new process image (see )." Oh, I see. I misread the exceve man page. Only signals which are caught will be reset to SIG_DFL. Sorry for the noise. Corinna --=20 Corinna Vinschen Cygwin Maintainer --R0SsnouPYaG+7rP6 Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAEBCAAdFiEEoVYPmneWZnwT6kwF9TYGna5ET6AFAl1EUOwACgkQ9TYGna5E T6DOkg//TveeWdxoyhK7WMK2u33MEMn1O65FYHrifrnaJ3XJdbp/fyxtFOexwQ+d 361XjKBKvzYxfZdquVzgf/ZuKvkavQK0o/U398O0CEqREIGidk4DraGHl/Wda6JF BgRYfUmisWdO9ovppw1rIg/DzQ7WlUnidQrmGc+zVKPIUApVzYPyWoWzidUr2dV7 6Xye9RP4PoMXIGymgSm+64c2W8Ny6L03UEZ7N0HDrheZ+8Y5RSP5rqDlDSirWFWU HMsebg6K44feCg8i7EzFzF9NP6l0kLq90K5+Dsh+NKn9WsddGAJpRCUn0YGuArIh yyJ5081cI3/eU840bVqh2CCWIJeWZ7cU5T77cpMSNRabxC9FDOX67W78T8KpG4IJ 5oZ0ITQBROaHOmlInBsGJLE0rQelYchxcZ6GLAHHRstolUR/HKnR+/8SdFDYKK0k rsMNEKxj+9k3qCCJ8c4FuzWr/eujhacwW0vRrw4JAiOeKIJQN+AmytKuN5lxrGoq vu+GgQy3o872ySXI1gv+uuvUVs+dem94L4RnBMwSxBnWLVHM/bgyujsC8Bs9gKI9 nKfcqY0j2S0Z82t/7nwLnku2CeA3PAFltoUvWh1usTyCGXKZyniNfDiDubpZE4dz o30fBlcIqOGr2zESxZdkUJtwZ8gwA8Os7/VlH+7YBz09NKBfjdo= =NKbc -----END PGP SIGNATURE----- --R0SsnouPYaG+7rP6--