delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2008/03/26/10:49:34

X-Recipient: archive-cygwin AT delorie DOT com
X-Spam-Check-By: sourceware.org
Date: Wed, 26 Mar 2008 11:49:04 -0400
From: Christopher Faylor <cgf-use-the-mailinglist-please AT cygwin DOT com>
To: cygwin AT cygwin DOT com
Subject: Re: 1.5.24-2: Applications automatically restart on crash
Message-ID: <20080326154904.GB16865@ednor.casa.cgf.cx>
Reply-To: cygwin AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
References: <47E95B8E DOT 7050406 AT morlier DOT us> <035601c88f4b$9da22eb0$2708a8c0 AT CAM DOT ARTIMI DOT COM>
MIME-Version: 1.0
In-Reply-To: <035601c88f4b$9da22eb0$2708a8c0@CAM.ARTIMI.COM>
User-Agent: Mutt/1.5.16 (2007-06-09)
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Unsubscribe: <mailto:cygwin-unsubscribe-archive-cygwin=delorie DOT com AT cygwin DOT 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

On Wed, Mar 26, 2008 at 02:13:50PM -0000, Dave Korn wrote:
>Christopher Morlier wrote on 25 March 2008 20:08:
>
>> Hi Everyone,
>> For a couple of years I have noticed that when I run programs from
>> within Cygwin (currently 1.5.24-2), if the program crashes (ie segfault)
>> then the program gets automatically restarted.  This is primarily a
>> problem when compiling/testing a windows program I am developing
>> (compiled with MSVC), as I have to wait for the program to
>> restart so I
>> can shut it down. It seems like this hasn't always been the behavior,
>> although it has been for several years (in the past, it just didn't
>> effect me as much). 
>
>  Yep.  Because it's a non-cygwin child process, cygwin doesn't realise it's
>started and crashed, it thinks the process creation suffered a temporary
>failure and has up to 5 retries.
>
>> 
>> I was wondering, is this a bug or a feature? 
>
>  Feature.
>
>> And if it is a
>> feature is there a way to prevent it from happening?
>
>  Recompile the dll, with attention to sigproc.cc:
>
>int child_info::retry_count = 10;
>
>and the way that child_info::proc_retry decrements the 'retry' counter which
>is initialised to that value.

set CYGWIN=proc_retry:1

is a much less intrusive way of dealing with this.

cgf

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

- Raw text -


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