mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* net/mptcp/pm_netlink.c:98:22: warning: The scope of the variable 'skc' can be reduced. [variableScope]
@ 2020-04-05 10:41 kbuild test robot
  0 siblings, 0 replies; only message in thread
From: kbuild test robot @ 2020-04-05 10:41 UTC (permalink / raw)
  To: Paolo Abeni; +Cc: kbuild-all, linux-kernel, Matthieu Baerts, Mat Martineau

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head:   4c205c84e249e0a91dcfabe461d77667ec9b2d05
commit: 01cacb00b35cb62b139f07d5f84bcf0eeda8eff6 mptcp: add netlink-based PM
date:   6 days ago

If you fix the issue, kindly add following tag as appropriate
Reported-by: kbuild test robot <lkp@intel.com>


cppcheck warnings: (new ones prefixed by >>)

>> net/mptcp/pm_netlink.c:98:22: warning: The scope of the variable 'skc' can be reduced. [variableScope]
>>  struct sock_common *skc;
                        ^

vim +/skc +98 net/mptcp/pm_netlink.c

    92	
    93	static bool lookup_subflow_by_saddr(const struct list_head *list,
    94					    struct mptcp_addr_info *saddr)
    95	{
    96		struct mptcp_subflow_context *subflow;
    97		struct mptcp_addr_info cur;
  > 98		struct sock_common *skc;
    99	
   100		list_for_each_entry(subflow, list, node) {
   101			skc = (struct sock_common *)mptcp_subflow_tcp_sock(subflow);
   102	
   103			local_address(skc, &cur);
   104			if (addresses_equal(&cur, saddr, false))
   105				return true;
   106		}
   107	
   108		return false;
   109	}
   110	

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2020-04-05 10:41 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-04-05 10:41 net/mptcp/pm_netlink.c:98:22: warning: The scope of the variable 'skc' can be reduced. [variableScope] kbuild test robot

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®