From owner-freebsd-current Mon Jan 24 7:21:18 2000 Delivered-To: freebsd-current@freebsd.org Received: from kronos.alcnet.com (kronos.alcnet.com [63.69.28.22]) by hub.freebsd.org (Postfix) with ESMTP id 5CBC514E98; Mon, 24 Jan 2000 07:21:03 -0800 (PST) (envelope-from kbyanc@posi.net) X-Provider: ALC Communications, Inc. http://www.alcnet.com/ Received: from localhost (kbyanc@localhost) by kronos.alcnet.com (8.9.3/8.9.3/antispam) with ESMTP id KAA39763; Mon, 24 Jan 2000 10:20:59 -0500 (EST) Date: Mon, 24 Jan 2000 10:20:50 -0500 (EST) From: Kelly Yancey X-Sender: kbyanc@kronos.alcnet.com To: Satoshi - Ports Wraith - Asami Cc: Bruce Evans , current@FreeBSD.ORG Subject: Re: sigisempty? In-Reply-To: Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On 24 Jan 2000, Satoshi - Ports Wraith - Asami wrote: > Anyway, I have committed the following patch submitted by Alexander > Langer. It has a nice feature of working for both -current and > -stable without any additional #ifdef's. I hope it's ok. > > Satoshi > ======= > --- lib/libxview/notify/ntfy.h.orig Tue Jun 29 07:18:14 1993 > +++ lib/libxview/notify/ntfy.h Mon Jan 10 15:50:53 2000 > @@ -188,7 +197,12 @@ > #define sigisempty(s) (!(((s)->__sigbits[0]) | ((s)->__sigbits[1]) \ > | ((s)->__sigbits[2]) | ((s)->__sigbits[3]))) > #else > -#define sigisempty(s) (!(*(s))) > +static int > +sigisempty (sigset_t *s) { > + sigset_t n; > + bzero(&n, sizeof(sigset_t)); > + return (! memcmp(&n, s, sizeof(sigset_t))); > +} > #endif > > /* > Suggestion: use sigemptyset() rather than bzero(). Kelly -- Kelly Yancey - kbyanc@posi.net - Richmond, VA Analyst / E-business Development, Bell Industries http://www.bellind.com/ Maintainer, BSD Driver Database http://www.posi.net/freebsd/drivers/ Coordinator, Team FreeBSD http://www.posi.net/freebsd/Team-FreeBSD/ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message