Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm Sender: cygwin-owner AT sourceware DOT cygnus DOT com Delivered-To: mailing list cygwin AT sourceware DOT cygnus DOT com From: Chris Faylor Date: Thu, 25 Mar 1999 14:09:14 -0500 To: Richard DOT Hirst AT net-tel DOT co DOT uk Cc: cygwin AT sourceware DOT cygnus DOT com Subject: Re: B20.1: Returning from pause() before signal handler runs? Message-ID: <19990325140914.A3064@cygnus.com> References: <"SLOE:0092-990325140215-0004*/G=Richard/S=Hirst/O=NET-TEL Computer Systems Ltd/PRMD=NET-TEL/ADMD=GOLD 400/C=GB/"@MHS> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Mailer: Mutt 0.95.3i In-Reply-To: <"SLOE:0092-990325140215-0004*/G=Richard/S=Hirst/O=NET-TEL Computer Systems Ltd/PRMD=NET-TEL/ADMD=GOLD 400/C=GB/"@MHS>; from Richard.Hirst@net-tel.co.uk on Thu, Mar 25, 1999 at 02:02:53PM +0000 On Thu, Mar 25, 1999 at 02:02:53PM +0000, Richard DOT Hirst AT net-tel DOT co DOT uk wrote: >Hi, > I am running "sendmail -q1" under B20.1 on NT4.0 SP3. This should poll a >queue directory once a minute, but I find that after a few polls it goes to >sleep. I have provided a small test program which shows the problem. >The parent installs ALRM and CHLD signal handlers, forks a child, >requests an alarm tick., and calls pause(). The child exits. Sometimes >the child exits before the parent calls pause(), sometimes not. The >signal handlers increment counts each time they run. The parent notes >these counts before calling pause, and again after returning from pause(). >Sometimes the parent finds that the counts havn't changed; it does a >printf() and checks the counts again - now they have changed. > >It looks to me as though the parent is returning from pause() before >the signal handler has been run. > >I can provoke the problem within a few cycles if I run a couple of >copies of the program and then start up a few other programs (DevStudio, >MSDOS boxes, etc). This is on a PII-233 with 64MB, NT4.0 SP3. > >If anyone could reproduce the problem, and say whether it looks like >a cygwin bug or not, I'd appreciate it. Looking at the code, it does appear to be a bug. I've fixed the problem and it will be in the next snapshot. cgf -- Want to unsubscribe from this list? Send a message to cygwin-unsubscribe AT sourceware DOT cygnus DOT com