[PATCH 3/3] opal: pci_info: remove redundant assignment to bytes

Colin King colin.king at canonical.com
Tue Feb 28 19:02:43 UTC 2017


From: Colin Ian King <colin.king at canonical.com>

bytes being set to zero is redundant as it will be set to the
return value of readlink on the next iteration.  Remove it.

Signed-off-by: Colin Ian King <colin.king at canonical.com>
---
 src/opal/pci_info.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/src/opal/pci_info.c b/src/opal/pci_info.c
index 40430d9..a0b6cab 100644
--- a/src/opal/pci_info.c
+++ b/src/opal/pci_info.c
@@ -273,7 +273,6 @@ static int get_linux_pci_devices(fwts_framework *fw)
 				free(of_node_link);
 				free(pci_slot);
 				free(namelist[i]);
-				bytes = 0;
 				continue;
 			}
 			of_node_path[bytes] = '\0';
-- 
2.10.2




More information about the fwts-devel mailing list