delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2001/10/04/14:45:46

Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT sources DOT redhat DOT com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin AT sources DOT redhat DOT com>
List-Help: <mailto:cygwin-help AT sources DOT redhat DOT com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-owner AT sources DOT redhat DOT com
Delivered-To: mailing list cygwin AT sources DOT redhat DOT com
Date: Thu, 4 Oct 2001 14:44:01 -0400
From: Christopher Faylor <cygwin AT cygwin DOT com>
To: cygwin AT cygwin DOT com
Subject: Re: 1.3.3-2: ps.exe bug for processes with a zero ppid
Message-ID: <20011004144401.A25590@redhat.com>
Reply-To: cygwin AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
References: <20011003111116 DOT G28936 AT redhat DOT com> <20011004083922 DOT 56277 DOT qmail AT web11507 DOT mail DOT yahoo DOT com>
Mime-Version: 1.0
In-Reply-To: <20011004083922.56277.qmail@web11507.mail.yahoo.com>
User-Agent: Mutt/1.3.21i

On Thu, Oct 04, 2001 at 01:39:22AM -0700, Robert Legros wrote:
>--- Christopher Faylor <cgf AT redhat DOT com> wrote:
>>You've hit the nail on the head.  This is a hack.  If the linux kernel
>>started setting pgids to 0, you would fix the linux kernel.  You
>>wouldn't fix 'ps'.
>>
>>If ps is assuming that a pgid == 0 is not a cygwin process then
>>obviously something is screwed up somewhere.  So, the fix is in
>>cygwin1.dll not ps.
>>
>>cgf
>
>OK, it is a hack.  But with version 1.3.3-2, the hack does work.
>'ps.exe' does again behaves correctly.
>
>I do have a problem.  Here, at work, there are a few packages (shell
>scripts) running.  They are part of an important B-to-B system.  Up to
>now it was running with Cygwin version 1.1.4 and all its packages as
>from 29 Sep 2000.  The system does work in production for more than a
>year now.
>
>In that version (1.1.4), process creation gave correct PPID's and
>PGID's.  And so 'ps.exe' did behave correctly.
>
>I should like to upgrade the OS platform.  That is upgrading from
>Windows NT to Windows 2000 and upgrading from Cygwin 1.1.4 to its
>current version.
>
>* BUT IT HAS TO WORK *
>
>Now it does not work anymore.  Let's call it regression.
>[snip]
>It should be nice if it could be done within version 1.3.4.  I don't
>like (nor you, probably) leave patches in a production system.

Three points:  1) Even as a hack your patch is wrong since it will skip
valid cygwin apps  2) I tried to fix this yesterday.  It should work
correctly in the lastest snapshot 3) I don't put inappropriate hacks
in utilities to work around bugs in the DLL.

This is the point that I was trying to make.  While I applaud the fact
that you actually thought to look at the code for a solution to your
problem, you just looked to the wrong code.  It may be harder to debug
cygwin1.dll but that does not mean that a correct solution is ever to
patch something else just because it is simpler.

cgf

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.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