From owner-freebsd-current Sat Sep 28 19: 5:51 2002 Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.FreeBSD.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 5B67637B401; Sat, 28 Sep 2002 19:05:49 -0700 (PDT) Received: from mailman.zeta.org.au (mailman.zeta.org.au [203.26.10.16]) by mx1.FreeBSD.org (Postfix) with ESMTP id 526BA43E4A; Sat, 28 Sep 2002 19:05:48 -0700 (PDT) (envelope-from bde@zeta.org.au) Received: from bde.zeta.org.au (bde.zeta.org.au [203.2.228.102]) by mailman.zeta.org.au (8.9.3/8.8.7) with ESMTP id MAA01530; Sun, 29 Sep 2002 12:05:45 +1000 Date: Sun, 29 Sep 2002 12:15:03 +1000 (EST) From: Bruce Evans X-X-Sender: bde@gamplex.bde.org To: Poul-Henning Kamp Cc: current@FreeBSD.ORG Subject: Re: kern_sig.c mis-indentation In-Reply-To: <31992.1033227935@critter.freebsd.dk> Message-ID: <20020929115617.J39631-100000@gamplex.bde.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Sat, 28 Sep 2002, Poul-Henning Kamp wrote: > The indentation and the braces look rather odd in this bit of > kern_sig.c, somebody should straighten it up and check if > there are any bugs in this: > > mi_switch(); > mtx_unlock_spin(&sched_lock); > PICKUP_GIANT(); > PROC_LOCK(p); > break; > } else > if (prop & SA_IGNORE) { > /* > * Except for SIGCONT, shouldn't get here. > * Default action is to ignore; drop it. > */ > break; /* == ignore */ > } else > return (sig); > /*NOTREACHED*/ This seemed to be just sloppy editing when it was first committed. IIRC, this was messed up by putting some ifdefed crud in there, and the smaller than usual indentation for the 'if' was a hack to avoid re-indenting properly. The ifdefed crud was soon removed, leaving only the (now completely bogus) indentation hack. I never merged these bugs and now use the following patch which just restores to the unmangled version which is still byte for byte identical with RELENG_4 here: %%% Index: kern_sig.c =================================================================== RCS file: /home/ncvs/src/sys/kern/kern_sig.c,v retrieving revision 1.190 diff -u -2 -r1.190 kern_sig.c --- kern_sig.c 28 Sep 2002 17:14:53 -0000 1.190 +++ kern_sig.c 29 Sep 2002 01:27:20 -0000 @@ -1732,6 +1698,5 @@ PROC_LOCK(p); break; - } else - if (prop & SA_IGNORE) { + } else if (prop & SA_IGNORE) { /* * Except for SIGCONT, shouldn't get here. %%% > PS: Yes, another score by FlexeLint! Nah. This was painfully obvious to the non-casual observer :). I have 1115 more lines of patches for style bugs in this file. Bruce To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message