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

RDMA/iwpm: Remove redundant initialization of pointer err_str

The pointer err_str is being initialized with a value that is never read,
it is being updated later on. The assignment is redundant and can be
removed.

Link: https://lore.kernel.org/r/20211007173942.21933-1-colin.king@canonical.com
Addresses-Coverity: ("Unused value")
Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>

authored by

Colin Ian King and committed by
Jason Gunthorpe
4bd46f3a 9a33f398

+1 -1
+1 -1
drivers/infiniband/core/iwpm_util.c
··· 762 762 { 763 763 struct sk_buff *skb = NULL; 764 764 struct nlmsghdr *nlh; 765 - const char *err_str = ""; 765 + const char *err_str; 766 766 int ret = -EINVAL; 767 767 768 768 skb = iwpm_create_nlmsg(RDMA_NL_IWPM_HELLO, &nlh, nl_client);