Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

net: netrom: nr_in: Remove redundant assignment to ns

Variable ns is set to 'skb->data[17]' but this value is never read as
it is overwritten or not used later on, hence it is a redundant
assignment and can be removed.

Cleans up the following clang-analyzer warning:

net/netrom/nr_in.c:156:2: warning: Value stored to 'ns' is never read
[clang-analyzer-deadcode.DeadStores].

Reported-by: Abaci Robot <abaci@linux.alibaba.com>
Signed-off-by: Jiapeng Chong <jiapeng.chong@linux.alibaba.com>
Link: https://lore.kernel.org/r/1619603885-115604-1-git-send-email-jiapeng.chong@linux.alibaba.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>

authored by

Jiapeng Chong and committed by
Jakub Kicinski
15c0a64b 808337be

-1
-1
net/netrom/nr_in.c
··· 153 153 int queued = 0; 154 154 155 155 nr = skb->data[18]; 156 - ns = skb->data[17]; 157 156 158 157 switch (frametype) { 159 158 case NR_CONNREQ: