nfc: nci: fix warning comparison to bool
Subsystems (3)
PATCH 1/1 nfc: nci: fix warning comparison to bool
Fix below warning reported by coccicheck
net/nfc/nci/ntf.c:367:5-15: WARNING: Comparison to bool
Signed-off-by Hariprasad Kelam <[email protected]>
--- net/nfc/nci/ntf.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
net/nfc/nci/ntf.c +1 -1
@@ -364,7 +364,7 @@ static void nci_rf_discover_ntf_packet(struct nci_dev *ndev, ntf.ntf_type = *data++;pr_debug ("ntf_type %d\n" , ntf.ntf_type); -if (add_target == true) +if (add_target)nci_add_new_target (ndev, &ntf);if (ntf.ntf_type ==NCI_DISCOVER_NTF_TYPE_MORE ) {
Signature · 1 line
2.7.4
David Miller
maintainerFrom: Hariprasad Kelam <[email protected]>
Date: Sat, 8 Jun 2019 14:11:54 +0530
Quoted 14 lines
Fix below warning reported by coccicheck
net/nfc/nci/ntf.c:367:5-15: WARNING: Comparison to bool
Signed-off-by Hariprasad Kelam <[email protected]>--- net/nfc/nci/ntf.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)net/nfc/nci/ntf.c +0
-0
net/nfc/nci/ntf.c static void nci_rf_discover_ntf_packet(struct nci_dev *ndev, · line 367
Quoted 5 lines
net/nfc/nci/ntf.c +1
-1@@ -364,7 +364,7 @@ static void nci_rf_discover_ntf_packet(struct nci_dev *ndev, ntf.ntf_type = *data++;pr_debug ("ntf_type %d\n" , ntf.ntf_type); -if (add_target == true) +if (add_target)
add_target is a bool, these kinds of changes are not good.