Mailing-List: contact cygwin-developers-help AT sourceware DOT cygnus DOT com; run by ezmlm List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-developers-owner AT sources DOT redhat DOT com Delivered-To: mailing list cygwin-developers AT sources DOT redhat DOT com From: Chris Faylor Date: Fri, 1 Sep 2000 20:58:07 -0400 To: Chris Faylor Subject: Re: sync with children problem Message-ID: <20000901205807.A32178@cygnus.com> Reply-To: cygwin-developers AT sources DOT redhat DOT com Mail-Followup-To: Chris Faylor References: <1975989842 DOT 20000901235524 AT logos-m DOT ru> <20000901160904 DOT A29015 AT cygnus DOT com> <1137440989 DOT 20000902001935 AT logos-m DOT ru> <20000901163248 DOT A29171 AT cygnus DOT com> <1958635367 DOT 20000902003930 AT logos-m DOT ru> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="W/nzBZO5zC0uMSeA" Content-Disposition: inline User-Agent: Mutt/1.3.6i In-Reply-To: <1958635367.20000902003930@logos-m.ru>; from deo@logos-m.ru on Sat, Sep 02, 2000 at 12:39:30AM +0400 --W/nzBZO5zC0uMSeA Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Sat, Sep 02, 2000 at 12:39:30AM +0400, Egor Duda wrote: >Hi! > >Saturday, 02 September, 2000 Chris Faylor cgf AT cygnus DOT com wrote: > >>>i've reproduced this under gdb and see that if i call >>>proc_can_be_signalled it won't do wait_for_me() but skip to > >CF> If it's not calling wait_for_me() then why is it hanging? > >it's not hanging, waitpid returns ECHILD > >CF> "simple test case" == "some minimal number of c instructions >CF> demonstrating the behavior". > >ok, i'll try I've duplicated the problem. A test case is below. I'll look into this. cgf --W/nzBZO5zC0uMSeA Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename="forkwait.c" #include #include #include int main (int argc, char **argv) { int pid, n; if ((pid = fork ()) == 0) exit (0); sleep (2); if ((n = waitpid (pid, NULL, 0)) != pid) printf ("wait pid failed, pid %d, n %d, errno %d\n", pid, n, errno); else printf ("wait pid succeeded, pid %d, n %d, errno %d\n", pid, n, errno); exit (0); } --W/nzBZO5zC0uMSeA--