lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <1437071891.2495.26.camel@perches.com>
Date:	Thu, 16 Jul 2015 11:38:11 -0700
From:	Joe Perches <joe@...ches.com>
To:	Ahmed Mohamed Abd EL Mawgood <ahmedsoliman0x666@...il.com>
Cc:	james.l.morris@...cle.com, serge@...lyn.com,
	linux-security-module@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] Security.c: fix 3 coding style indentation errors

On Thu, 2015-07-16 at 18:21 +0200, Ahmed Mohamed Abd EL Mawgood wrote:
> This is my first patch to get my hand dirty
> 3 simple indentation errors fixing withen security/security.c
[]
> diff --git a/security/security.c b/security/security.c
[]
> @@ -567,8 +567,8 @@ int security_inode_rename(struct inode *old_dir, struct dentry *old_dentry,
>  			   struct inode *new_dir, struct dentry *new_dentry,
>  			   unsigned int flags)
>  {
> -        if (unlikely(IS_PRIVATE(d_backing_inode(old_dentry)) ||
> -            (d_is_positive(new_dentry) && IS_PRIVATE(d_backing_inode(new_dentry)))))
> +	if (unlikely(IS_PRIVATE(d_backing_inode(old_dentry)) ||
> +	(d_is_positive(new_dentry) && IS_PRIVATE(d_backing_inode(new_dentry)))))
>  		return 0;

See Documentation/CodingStyle, chapter 2:

Descendents are "substantially to the right", not aligned to the if

Some prefer alignment to open parentheses like:

	if (unlikely(IS_PRIVATE(d_backing_inode(old_dentry)) ||
		     (d_is_positive(new_dentry) &&
		      IS_PRIVATE(d_backing_inode(new_dentry)))))

Others just want the indentation on a tab stop.


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

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ