Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752578AbaG1P2X (ORCPT ); Mon, 28 Jul 2014 11:28:23 -0400 Received: from mail-pd0-f174.google.com ([209.85.192.174]:52081 "EHLO mail-pd0-f174.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753116AbaG1P2U (ORCPT ); Mon, 28 Jul 2014 11:28:20 -0400 Date: Mon, 28 Jul 2014 20:58:12 +0530 From: Himangi Saraogi To: Samuel Ortiz , "David S. Miller" , netdev@vger.kernel.org, linux-kernel@vger.kernel.org Cc: julia.lawall@lip6.fr Subject: [PATCH] net: irda: delete double assignment Message-ID: <20140728152812.GA3000@himangi-Dell> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Delete successive assignments to the same location. A simplified version of Coccinelle semantic match that finds this problem is as follows: // @@ expression i; @@ *i = ...; i = ...; // Signed-off-by: Himangi Saraogi --- Should the second assignment have been |=? net/irda/irlap_frame.c | 1 - 1 file changed, 1 deletion(-) diff --git a/net/irda/irlap_frame.c b/net/irda/irlap_frame.c index 9ea0c93..4c169f6 100644 --- a/net/irda/irlap_frame.c +++ b/net/irda/irlap_frame.c @@ -621,7 +621,6 @@ void irlap_send_rd_frame(struct irlap_cb *self) frame = (struct rd_frame *)skb_put(tx_skb, 2); - frame->caddr = self->caddr; frame->caddr = RD_RSP | PF_BIT; irlap_queue_xmit(self, tx_skb); -- 1.9.1 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/