[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <632598f6-c36d-a672-edfe-fbf62e9a2e25@users.sourceforge.net>
Date: Thu, 12 Oct 2017 12:46:03 +0200
From: SF Markus Elfring <elfring@...rs.sourceforge.net>
To: devel@...verdev.osuosl.org, netdev@...r.kernel.org,
Al Viro <viro@...iv.linux.org.uk>,
Corentin Labbe <clabbe.montjoie@...il.com>,
David Howells <dhowells@...hat.com>,
"David S. Miller" <davem@...emloft.net>,
Georgiana Chelu <georgiana.chelu93@...il.com>,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
Johannes Berg <johannes.berg@...el.com>,
Julia Lawall <julia.lawall@...6.fr>,
Samuel Ortiz <samuel@...tiz.org>,
Srishti Sharma <srishtishar@...il.com>,
Stephen Hemminger <stephen@...workplumber.org>,
Yuan Linyu <Linyu.Yuan@...atel-sbell.com.cn>
Cc: LKML <linux-kernel@...r.kernel.org>,
kernel-janitors@...r.kernel.org
Subject: [PATCH 06/10] staging/irda/net: Delete an unnecessary variable
initialisation in two functions
From: Markus Elfring <elfring@...rs.sourceforge.net>
Date: Wed, 11 Oct 2017 22:22:13 +0200
The local variable "tx_skb" will only be used in a single if branch
of these functions. Thus omit the explicit initialisation at the beginning.
Signed-off-by: Markus Elfring <elfring@...rs.sourceforge.net>
---
drivers/staging/irda/net/irlap_frame.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/staging/irda/net/irlap_frame.c b/drivers/staging/irda/net/irlap_frame.c
index 5b8be5b9812e..25ceb06efd58 100644
--- a/drivers/staging/irda/net/irlap_frame.c
+++ b/drivers/staging/irda/net/irlap_frame.c
@@ -862,7 +862,7 @@ void irlap_send_data_primary_poll(struct irlap_cb *self, struct sk_buff *skb)
void irlap_send_data_secondary_final(struct irlap_cb *self,
struct sk_buff *skb)
{
- struct sk_buff *tx_skb = NULL;
+ struct sk_buff *tx_skb;
IRDA_ASSERT(self, return;);
IRDA_ASSERT(self->magic == LAP_MAGIC, return;);
@@ -922,7 +922,7 @@ void irlap_send_data_secondary_final(struct irlap_cb *self,
*/
void irlap_send_data_secondary(struct irlap_cb *self, struct sk_buff *skb)
{
- struct sk_buff *tx_skb = NULL;
+ struct sk_buff *tx_skb;
/* Is this reliable or unreliable data? */
if (skb->data[1] == I_FRAME) {
--
2.14.2
Powered by blists - more mailing lists