[merged mm-nonmm-stable] lib-ts_bmc-remove-redundant-store-to-variable-consumed-after-addition.patch removed from -mm tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The quilt patch titled
     Subject: lib/ts_bm.c: remove redundant store to variable consumed after addition
has been removed from the -mm tree.  Its filename was
     lib-ts_bmc-remove-redundant-store-to-variable-consumed-after-addition.patch

This patch was dropped because it was merged into the mm-nonmm-stable branch
of git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm

------------------------------------------------------
From: Colin Ian King <colin.i.king@xxxxxxxxx>
Subject: lib/ts_bm.c: remove redundant store to variable consumed after addition
Date: Mon, 4 Jul 2022 22:53:25 +0100

There is no need to store the result of the addition back to variable
consumed after the addition.  The store is redundant, replace += with just
+

Cleans up clang scan build warning: lib/ts_bm.c:83:11: warning: Although
the value stored to 'consumed' is used in the enclosing expression, the
value is never actually read from 'consumed' [deadcode.DeadStores]

Link: https://lkml.kernel.org/r/20220704215325.600993-1-colin.i.king@xxxxxxxxx
Signed-off-by: Colin Ian King <colin.i.king@xxxxxxxxx>
Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>
---

 lib/ts_bm.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

--- a/lib/ts_bm.c~lib-ts_bmc-remove-redundant-store-to-variable-consumed-after-addition
+++ a/lib/ts_bm.c
@@ -80,7 +80,7 @@ static unsigned int bm_find(struct ts_co
 
 			/* London calling... */
 			DEBUGP("found!\n");
-			return consumed += (shift-(bm->patlen-1));
+			return consumed + (shift-(bm->patlen-1));
 
 next:			bs = bm->bad_shift[text[shift-i]];
 
_

Patches currently in -mm which might be from colin.i.king@xxxxxxxxx are





[Index of Archives]     [Kernel Archive]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]

  Powered by Linux