All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Gujulan Elango, Hari Prasath (H.)" <hgujulan@visteon.com>
To: Dan Carpenter <dan.carpenter@oracle.com>
Cc: Jes Sorensen <Jes.Sorensen@redhat.com>,
	"devel@driverdev.osuosl.org" <devel@driverdev.osuosl.org>,
	"gregkh@linuxfoundation.org" <gregkh@linuxfoundation.org>,
	"linux-wireless@vger.kernel.org" <linux-wireless@vger.kernel.org>,
	"Larry.Finger@lwfinger.net" <Larry.Finger@lwfinger.net>,
	"Babu, Viswanathan (V.)" <vbabu3@visteon.com>
Subject: Re: [PATCH] staging: rtl8723au : remove goto & return error directly
Date: Thu, 7 May 2015 13:49:07 +0000	[thread overview]
Message-ID: <20150507134344.GA11599@IND12F0122> (raw)
In-Reply-To: <20150507121934.GH14154@mwanda>

On Thu, May 07, 2015 at 03:19:34PM +0300, Dan Carpenter wrote:
> On Thu, May 07, 2015 at 08:03:06AM -0400, Jes Sorensen wrote:
> > "Gujulan Elango, Hari Prasath (H.)" <hgujulan@visteon.com> writes:
> > > Remove the goto and return error directly thereby removing a variable
> > >
> > > Signed-off-by: Hari Prasath Gujulan Elango <hgujulan@visteon.com>
> > > ---
> > >  drivers/staging/rtl8723au/os_dep/ioctl_cfg80211.c | 7 ++-----
> > >  1 file changed, 2 insertions(+), 5 deletions(-)
> > 
> > NACK!
> 
> SHOUTING!
> 
> > 
> > The goto is cleaner and more consistent, rather than hiding a return in
> > the middle of the code.
> 
> More consistent with what?  There are already returns earlier in the
> function.  Do-nothing gotos are pointless and annoying.
> 
> regards,
> dan carpenter
> 

I sent this patch  because goto & return was mixed up in this function.
There was a return as well as goto used. And i guess goto is not 
encouraged anywhere. In this case especially,I couldn't see any 
significant cleanup being done in the goto label.

  reply	other threads:[~2015-05-07 14:05 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-05-07 11:22 [PATCH] staging: rtl8723au : remove goto & return error directly Gujulan Elango, Hari Prasath (H.)
2015-05-07 12:03 ` Jes Sorensen
2015-05-07 12:19   ` Dan Carpenter
2015-05-07 13:49     ` Gujulan Elango, Hari Prasath (H.) [this message]
2015-05-07 14:09       ` Jes Sorensen
2015-05-12 10:37         ` Gujulan Elango, Hari Prasath (H.)
2015-05-12 11:16           ` Jes Sorensen
2015-05-07 14:08     ` Jes Sorensen
2015-05-07 14:29       ` Joe Perches
2015-05-07 14:44         ` Jes Sorensen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20150507134344.GA11599@IND12F0122 \
    --to=hgujulan@visteon.com \
    --cc=Jes.Sorensen@redhat.com \
    --cc=Larry.Finger@lwfinger.net \
    --cc=dan.carpenter@oracle.com \
    --cc=devel@driverdev.osuosl.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-wireless@vger.kernel.org \
    --cc=vbabu3@visteon.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.