Re: dangling else

Riley Williams (rhw@MemAlpha.CX)
Wed, 14 Jul 1999 23:46:50 +0100 (GMT)


Hi there.

> Lets beautify this,

> if(write) {
>>> if(!(vma->vm_flags & VM_WRITE))
>>> goto bad_area;
>>> } else if(!(vma->vm_flags & (VM_READ | VM_EXEC)))
>>> goto bad_area;

> Or somebody disagree with this C style..

Linus has stated several times that he requires patches to use the
same formatting as already in the kernel before he will accept them,
hence my use of the style used elsewhere.

Personally, I prefer the braces as you've put them, but when I'm
modifying somebody else's work, I use the style they've used for the
same reason Linus insists on it...

Best wishes from Riley.

+----------------------------------------------------------------------+
| There is something frustrating about the quality and speed of Linux |
| development, ie., the quality is too high and the speed is too high, |
| in other words, I can implement this XXXX feature, but I bet someone |
| else has already done so and is just about to release their patch. |
+----------------------------------------------------------------------+
* ftp://ftp.MemAlpha.cx/pub/rhw/Linux
* http://www.MemAlpha.cx/kernel.versions.html

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/