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] [thread-next>] [day] [month] [year] [list]
Message-ID: <20131231111225.GT28413@mwanda>
Date:	Tue, 31 Dec 2013 14:12:25 +0300
From:	Dan Carpenter <dan.carpenter@...cle.com>
To:	Michael Gunselmann <michael.gunselmann@...dium.uni-erlangen.de>
Cc:	devel@...verdev.osuosl.org, linux-kernel@...cs.fau.de,
	gregkh@...uxfoundation.org, linux-kernel@...r.kernel.org,
	martin.hofmann@...dium.uni-erlangen.de, forest@...ttletooquiet.net
Subject: Re: [PATCH 2/7] vt6655: Fix most of checkpatch.pl errors in wroute

On Mon, Dec 30, 2013 at 03:52:32PM +0100, Michael Gunselmann wrote:
> wroute.h: Fixed all line-over-80-character errors. No errors remain.
> wroute.c: Fixed line-over-80-character errors, bracing errors
> 	  and C99-comments.
> 	  Three warnings remain, fixing them would deteriorate readability.
> 	  One warning on a memory barrier without comment in line 189
> 	  will be fixed in a later commit because it's purpose is not
> 	  yet known.
> 

Don't do the weird indenting.

> @@ -86,22 +88,25 @@ bool ROUTEbRelay(PSDevice pDevice, unsigned char *pbySkbData, unsigned int uData
>  
>  	pHeadTD->m_td1TD1.byTCR = (TCR_EDP | TCR_STP);
>  
> -	memcpy(pDevice->sTxEthHeader.abyDstAddr, (unsigned char *)pbySkbData, ETH_HLEN);
> +	memcpy(pDevice->sTxEthHeader.abyDstAddr,
> +	       (unsigned char *)pbySkbData, ETH_HLEN);
>  

It would be better to fix this like so:

	memcpy(pDevice->sTxEthHeader.abyDstAddr, pbySkbData, ETH_HLEN);

> -			}
> +			else
> +				pDevice->wCurrentRate =
> +					(unsigned short)pDevice->uConnectionRate;

Remove the silly cast here as well.

				pDevice->wCurrentRate = pDevice->uConnectionRate;

Both your patch and mine are still 81 characters long.

I don't get upset by lines over 80 characters...  Eventually we will fix
that.  Just leave it as-is, until we can clean it up from a human
perspective as well as from a checkpatch.pl robot perspective.

regards,
dan carpenter

--
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