X-Recipient: archive-cygwin AT delorie DOT com X-SWARE-Spam-Status: No, hits=-1.9 required=5.0 tests=BAYES_00,T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Message-ID: <50CEF551.3010807@mathematik.uni-kl.de> Date: Mon, 17 Dec 2012 11:34:57 +0100 From: Andreas Steenpass User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/17.0 Thunderbird/17.0 MIME-Version: 1.0 To: cygwin AT cygwin DOT com Subject: sigpending() crashes Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-IsSubscribed: yes Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com A few days ago, I posted a bug report on this mailing list, see http://cygwin.com/ml/cygwin/2012-12/msg00155.html There hasn't been any reply to it. Maybe I should have started a new thread, maybe it was just too much at once, I don't know. But I still think that this needs to be fixed, so I just post it again. Here is a test case: #################### #include #include int main() { int signr; sigset_t sigusr1, sigusr2, pending; sigemptyset(&sigusr1); sigemptyset(&sigusr2); sigemptyset(&pending); sigaddset(&sigusr1, SIGUSR1); sigaddset(&sigusr2, SIGUSR2); sigprocmask(SIG_BLOCK, &sigusr1, NULL); sigprocmask(SIG_BLOCK, &sigusr2, NULL); printf("pid: %d\n", getpid()); sigwait(&sigusr1, &signr); sigpending(&pending); sigwait(&sigusr2, &signr); return(0); } #################### $ uname -a CYGWIN_NT-6.1-WOW64 zoppo 1.7.18s(0.263/5/3) 20121207 21:00:18 i686 Cygwin $ ./test_case pid: 2640 // In another console, type (in this order!) $ kill -SIGUSR2 2640 $ kill -SIGUSR1 2640 // Then the program gives: Segmentation fault (core dumped) $ The program doesn't crash if I send SIGUSR1 first and then SIGUSR2. Regards, Andreas -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple