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: <20151202092349.GK18797@mwanda>
Date:	Wed, 2 Dec 2015 12:23:50 +0300
From:	Dan Carpenter <dan.carpenter@...cle.com>
To:	James Simmons <jsimmons@...radead.org>
Cc:	Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
	devel@...verdev.osuosl.org, Oleg Drokin <oleg.drokin@...el.com>,
	Andreas Dilger <andreas.dilger@...el.com>,
	Amir Shehata <amir.shehata@...el.com>,
	Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
	lustre-devel@...ts.lustre.org
Subject: Re: [PATCH 11/40] staging: lustre: DLC Feature dynamic net config

On Fri, Nov 20, 2015 at 06:35:47PM -0500, James Simmons wrote:
> +
> +	return 0;
>  
>   failed4:
> -	lnet_ping_target_fini();
> - failed3:
>  	the_lnet.ln_refcount = 0;
> +	lnet_ping_md_unlink(pinfo, &md_handle);
> +	lnet_ping_info_free(pinfo);
> + failed3:
>  	lnet_acceptor_stop();
> +	rc = LNetEQFree(the_lnet.ln_ping_target_eq);
> +	LASSERT(rc == 0);
        ^^^^^^^^^^^^^^^^

>   failed2:
>  	lnet_destroy_routes();
>  	lnet_shutdown_lndnis();
> @@ -1263,8 +1609,12 @@ LNetNIInit(lnet_pid_t requested_pid)
>  	lnet_unprepare();
>   failed0:
>  	LASSERT(rc < 0);
        ^^^^^^^^^^^^^^^

These asserts contradict each other.


But mostly please remove all the GW-BASIC style numbered labeled names
from this patch.  You wouldn't name your variables "int var1, var2,
var3" so for label names you should give them meaningful names as well.
Don't name them after the goto location, name them after the label
location to say the first thing that the label does.

err_fini:
err_acceptor_stop:
err_destroy_routes:
err_empty_list:

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