From owner-freebsd-hackers@FreeBSD.ORG Wed May 3 19:54:04 2006 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 07B4616A43B; Wed, 3 May 2006 19:54:04 +0000 (UTC) (envelope-from aanton@spintech.ro) Received: from smtpx.spintech.ro (smtpx.spintech.ro [81.180.92.70]) by mx1.FreeBSD.org (Postfix) with ESMTP id 16EE543D7C; Wed, 3 May 2006 19:54:02 +0000 (GMT) (envelope-from aanton@spintech.ro) Received: from [10.0.0.2] (beastie [10.0.0.2]) by smtpx.spintech.ro (Postfix) with ESMTP id 7C1123A4AA; Wed, 3 May 2006 20:27:43 +0000 (UTC) Message-ID: <44590A59.7000307@spintech.ro> Date: Wed, 03 May 2006 22:54:01 +0300 From: Alin-Adrian Anton Organization: Spintech Security Systems User-Agent: Mozilla Thunderbird 1.0 (X11/20041229) X-Accept-Language: en-us, en MIME-Version: 1.0 To: Daniel Eischen References: <4456A5B3.2010809@spintech.ro> <44579DE0.1050207@spintech.ro> <44589A77.7070707@spintech.ro> In-Reply-To: X-Enigmail-Version: 0.89.5.0 X-Enigmail-Supports: pgp-inline, pgp-mime Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-hackers@freebsd.org Subject: Re: which running thread gests the external signal X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: aanton@spintech.ro List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 03 May 2006 19:54:04 -0000 Daniel Eischen wrote: [..] > > Note that sigprocmask() and pthread_sigprocmask() are equivalent. I > don't even think pthread_sigprocmask() is in the standard any longer > (it used to be in an older version of the standard). New applications > should be using sigprocmask(). > Yes I noticed. However, this just happens to be the implementation (probably pthread_sigmask is a wrapper to sigprocmask). This might not be the case on other OS, so for portability I'll stick to the pthread_sigmask in threads, and sigprocmask in single threaded apps. Thanks, -- Alin-Adrian Anton GPG keyID 0x183087BA (B129 E8F4 7B34 15A9 0785 2F7C 5823 ABA0 1830 87BA) gpg --keyserver pgp.mit.edu --recv-keys 0x183087BA "It is dangerous to be right when the government is wrong." - Voltaire