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]
Date:	Mon, 20 May 2013 10:01:12 +0100
From:	Wei Liu <wei.liu2@...rix.com>
To:	David Miller <davem@...emloft.net>
CC:	<wei.liu2@...rix.com>, <xen-devel@...ts.xen.org>,
	<netdev@...r.kernel.org>, <ian.campbell@...rix.com>
Subject: Re: [PATCH net-next] xen-netfront: avoid leaking resources when
 setup_netfront fails

On Sun, May 19, 2013 at 11:28:33PM -0700, David Miller wrote:
> From: Wei Liu <wei.liu2@...rix.com>
> Date: Fri, 17 May 2013 10:43:58 +0100
> 
> >  
> > + /* If we fail to setup netfront, it is safe to just revoke access to granted
> > +  * pages because backend is not accessing it at this point.
> > +  */
> > + bind_fail:
> > +	xenbus_free_evtchn(dev, info->evtchn);
> > + alloc_evtchn_fail:
> > +	gnttab_end_foreign_access_ref(info->rx_ring_ref, 0);
> > + grant_rx_ring_fail:
> > +	free_page((unsigned long)rxs);
> > + alloc_rx_ring_fail:
> > +	gnttab_end_foreign_access_ref(info->tx_ring_ref, 0);
> > + grant_tx_ring_fail:
> > +	free_page((unsigned long)txs);
> >   fail:
> >  	return err;
> >  }
> 
> This is not even close to adhering to proper coding style.
> 
> The comment should be indented by one tab not one space:
> 
> 	/* Like
> 	 * this.
> 	 */
> 
> And the code labels should appear at the first column, not
> with a leading space.

Thanks, coding style problems are fixed now.

For some reason some other labels in this file appear to have the same
style problem, I will fix them when I touch other part of the file in
the future.


Wei.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ