X-Recipient: archive-cygwin@delorie.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:cc:subject:message-id:in-reply-to
	:references:mime-version:content-type:content-transfer-encoding;
	 q=dns; s=default; b=HeaOK8ZCRzQX3L4kwN1pOMtwiUxk+YwT6xB75QUtAvm
	YVpQa3lTheRN95FKIIyDU+IwaNJmW7nuTR6jTnA1NyEE4LrF9mHyCtoFVRfy/NLA
	l49h8FuabbndNVyUnNkQYLkmfIwT5fFsP5ogiCunR9j3lOnfLD1Hk9Bk9qDo68/I
	=
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:cc:subject:message-id:in-reply-to
	:references:mime-version:content-type:content-transfer-encoding;
	 s=default; bh=cvytXSQkrUkgYs3guzYvEa8Hv2g=; b=iW6G/O3pHULRYSbrY
	T3YohZda5zEgfDnD5KHVqZRxm5HRggsI0Z8pwdhcWm+Dlm3ldmrjhifsVVHnuou4
	BVwPDtyOYNrcIBWwrapje0hyyUO26beCVJgULn1k/C8lYFSFJtup3cm3SMxnas5p
	u/2ypOp6bkbj1hS2rvmmKAqzAU=
Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe@cygwin.com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin@cygwin.com>
List-Help: <mailto:cygwin-help@cygwin.com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner@cygwin.com
Mail-Followup-To: cygwin@cygwin.com
Delivered-To: mailing list cygwin@cygwin.com
Authentication-Results: sourceware.org; auth=none
X-Spam-SWARE-Status: No, score=-5.9 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.1 spammy=
X-HELO: conssluserg-01.nifty.com
DKIM-Filter: OpenDKIM Filter v2.10.3 conssluserg-01.nifty.com 01BDFvDc019303
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nifty.ne.jp;	s=dec2015msa; t=1581426957;	bh=fz1FHWoMiuS+OWUK8qKhEVwHqjrHA17AqsZuanjCbiM=;	h=Date:From:To:Cc:Subject:In-Reply-To:References:From;	b=yUM2zW1EggwiQ7U9vydoBxsBaKBDH800SbswEwFi6w1Q5uOWuYYsHehRjsWu2AlgZ	 dsmZ65jGQ5HnND0RAlSf17GGKWO4lq6BZJMJ1G6UhGskE9OWJRhkGcr3YjUS0bCmtW	 bhFVRPqaoxgWP28QQeRVLuJFzisEPXEWxTq3+vdzNCaCky4QwwkfFRNup8MKRgtefi	 xaN7TcAlepzekyolmQ2Ez4cnGwVaS9RWIJH7TaY+UCUOhZKaS/e2vLxH7Pj9dWW1HY	 +K7alJvB23o+gaGOkSGGFUWNrz6gRcGgUIUIZyJHciIAqWuMRIrNkS8Nbc8/bjcHa8	 lu/2ALd3wImnw==
Date: Tue, 11 Feb 2020 22:16:06 +0900
From: Takashi Yano <takashi.yano@nifty.ne.jp>
To: cygwin@cygwin.com
Cc: pdt@dontech.dk
Subject: Re: fork: Resource temporarily unavailable errors after upgrading cygwin packages
Message-Id: <20200211221606.c82d718ec32a6d0ce3c2ad7b@nifty.ne.jp>
In-Reply-To: <b3f992f6b2ba69b9f29e2b126e8580e76d98e4a8.camel@dontech.dk>
References: <6d43c714-c4ba-4f0c-9913-cb8453129c85@gmail.com>	<d24aa066-ab3d-9ff0-215a-0a1ed1ec2e5d@cornell.edu>	<93562f34-3a14-0c10-cb57-1ae861307d82@gmail.com>	<f4a808cf-d129-f6ce-0da8-674cf88a71ad@gmail.com>	<810b0c97ee0697c06bdaa4dff4081bb502bc46ab.camel@dontech.dk>	<CACSsrOzmexPqVeAoZigrkR4Tv6sWa-506Ui8UzsgLcTSBotgLw@mail.gmail.com>	<9ed4b0776323e4a0f62191121715d52a0429bdb2.camel@dontech.dk>	<d5109f77-9d73-fd68-fac6-1119037c8468@gmail.com>	<23d3cd65794886745e2070a1d1b74013418b0bd8.camel@dontech.dk>	<20200211112026.05664f5c68b6282a39da8ac2@nifty.ne.jp>	<b3f992f6b2ba69b9f29e2b126e8580e76d98e4a8.camel@dontech.dk>
Mime-Version: 1.0
Content-Type: text/plain; charset=US-ASCII
Content-Transfer-Encoding: 7bit
X-IsSubscribed: yes

On Tue, 11 Feb 2020 11:38:35 +0100
Peter Dons Tychsen wrote:
> On Tue, 2020-02-11 at 11:20 +0900, Takashi Yano wrote:
> > Is this the same as your problem?
> 
> Yeah, it could be. Could this result in fork error messages as we are
> seeing all over the place?

No. Fork error is not seen in my environment. This could be another
problem. However, the code using kill() below is called also by fork().
So, it may be related.

I have not investigated your problem on make, so the mechanism to
cause the problem is not clear. I do not have confidence that this
patch really fixes your problem.

> > If so, it goes without stopping 1 minute with patch:
> > https://cygwin.com/ml/cygwin-patches/2020-q1/msg00148.html
> 
> Nice trick to use pinfo as a work-around, but i could fear that others
> also call kill() at this critical time. Is there an actual fix for
> kill() in the cooking? I could fear that tools like "make" actually
> call this all over the place, especially if its aborting running
> processes. And why did this work before?

The commit message says:
>  This seems to be caused by invalid pointer access which occurs
>  when the process exits during the kill() code is execuetd. This
>  patch avoids the issue by not using kill().
however, I found the real cause is that errno is accidentally set
by kill() in pty system calls. That is, the problem is not in the
kill() itself but in usage of it. Cygwin older than 3.1.0 does not
have these code in pty. 

On Tue, 11 Feb 2020 11:40:45 +0100
Peter Dons Tychsen wrote:
> And why does it work when running without minnty? How does that play
> into this?

The code which has this problem is in the pty code. So, this occurs
only in pty such as mintty, xterm, etc. Console (cygwin in command
prompt) does not use pty, so problem does not occur in console.

-- 
Takashi Yano <takashi.yano@nifty.ne.jp>

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

