mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Eric Sesterhenn <snakebyte@gmx.de>
To: linux-kernel@vger.kernel.org
Subject: [Patch] Remove useless check in drivers/net/pcmcia/xirc2ps_cs.c
Date: Wed, 21 Jun 2006 16:10:48 +0200	[thread overview]
Message-ID: <1150899048.16427.2.camel@alice> (raw)

hi,

coverity choked at this check (id #223), assuming that
skb might be NULL and used anyways later. Since
start_hard_xmit() always gets called with a valid
skb, the check is useless and this patch removes it.

Signed-off-by: Eric Sesterhenn <snakebyte@gmx.de>

--- linux-2.6.17-git2/drivers/net/pcmcia/xirc2ps_cs.c.orig	2006-06-21 16:06:48.000000000 +0200
+++ linux-2.6.17-git2/drivers/net/pcmcia/xirc2ps_cs.c	2006-06-21 16:06:59.000000000 +0200
@@ -1359,7 +1359,7 @@ do_start_xmit(struct sk_buff *skb, struc
     kio_addr_t ioaddr = dev->base_addr;
     int okay;
     unsigned freespace;
-    unsigned pktlen = skb? skb->len : 0;
+    unsigned pktlen = skb->len;
 
     DEBUG(1, "do_start_xmit(skb=%p, dev=%p) len=%u\n",
 	  skb, dev, pktlen);



                 reply	other threads:[~2006-06-21 14:10 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=1150899048.16427.2.camel@alice \
    --to=snakebyte@gmx.de \
    --cc=linux-kernel@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

Powered by JetHome