linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Dan Carpenter <error27@gmail.com>
To: linux-wireless@vger.kernel.org
Subject: unreachable code in airo_set_auth()
Date: Wed, 8 Apr 2009 14:02:41 +0300 (EAT)	[thread overview]
Message-ID: <alpine.DEB.2.00.0904072049540.8684@bicker> (raw)

Smatch (http://repo.or.cz/w/smatch.git) complains about unreachable code 
in airo_set_auth() from drivers/net/wireless/airo.c

We don't actually commit the changes, but instead break on line 6577.  I 
didn't know what was intended there.  Or who the maintainer was.

regards,
dan carpenter

  6567          case IW_AUTH_80211_AUTH_ALG: {
  6568                          /* FIXME: What about AUTH_OPEN?  This API seems to
  6569                           * disallow setting our auth to AUTH_OPEN.
  6570                           */
  6571                          if (param->value & IW_AUTH_ALG_SHARED_KEY) {
  6572                                  local->config.authType = AUTH_SHAREDKEY;
  6573                          } else if (param->value & IW_AUTH_ALG_OPEN_SYSTEM) {
  6574                                  local->config.authType = AUTH_ENCRYPT;
  6575                          } else
  6576                                  return -EINVAL;
  6577                          break;
  6578  
  6579                          /* Commit the changes to flags if needed */
  6580                          if (local->config.authType != currentAuthType)
  6581                                  set_bit (FLAG_COMMIT, &local->flags);
  6582                  }


             reply	other threads:[~2009-04-08 11:06 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-04-08 11:02 Dan Carpenter [this message]
2009-04-08 13:45 ` unreachable code in airo_set_auth() John W. Linville
2009-04-08 14:15   ` [PATCH] airo: queue SIOCSIWAUTH-requested auth mode change for next commit Dan Williams

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=alpine.DEB.2.00.0904072049540.8684@bicker \
    --to=error27@gmail.com \
    --cc=linux-wireless@vger.kernel.org \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).