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

ivanhu ivan.hu at canonical.com
Thu Mar 2 06:52:29 UTC 2017



On 03/01/2017 03:02 AM, Colin King wrote:
> 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';
>


Acked-by: Ivan Hu <ivan.hu at canonical.com>



More information about the fwts-devel mailing list