delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2004/09/17/03:51:17

Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
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
Subject: RE: Bash returns incorrect process status
Date: Fri, 17 Sep 2004 09:51:07 +0200
MIME-Version: 1.0
Message-ID: <90459864DAD67D43BDD3D517DEFC2F7D7138@axon.Axentia.local>
X-MS-Has-Attach:
X-MS-TNEF-Correlator:
From: "Peter Ekberg" <peda AT axentia DOT se>
To: <pierre DOT humblet AT ieee DOT org>, <chet AT po DOT cwru DOT edu>
Cc: <cygwin AT cygwin DOT com>, <ronald AT landheer DOT com>
X-MIME-Autoconverted: from quoted-printable to 8bit by delorie.com id i8H7pGcW007419

Pierre A. Humblet wrote:
> FWIW, attached is a patch to bash that may improve its 
> behavior on Cygwin.
> The idea is that when a new process is stored in the memory array, any
> existing process with the same pid is marked "reused". 
> "reused" processes
> are never considered when searching for a process by pid. 
> They are still
> still available, e.g. to get the status of processes in a job. 
> 
> It's a proof of principle code, not meant to be efficient. It 
> can still print
> a debug message on stderr.

Tried it and it doesn't solve the problem for me. It shifts the trigger
pattern though.

Without the patch, an almost sure thing to do to trigger the bug is to
run the configure script under "strace bash". But with the patch, I have
not been able to trigger the bug once.

However, just running the configure script without straceing bash
triggers the bug at about the same rate as without the patch (I estimate
that between 1/3 and 1/2 of the runs fail).

But wait, now I tried to trigger the bug with the original bash and that
also fails when straceing. So I guess my remark about the shift in
trigger pattern is not certain...

/me makes a note of the phase of the moon

I have not noted any occurance of the "Found old pid..." message. Is
that an indication that the patch never kicks in?

Cheers,
Peter

--
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