Re: [PATCH 2/3] efi/efi_test: fix the uninitialized value datasize

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, 26 Sep, at 11:14:50AM, Ivan Hu wrote:
> Fix the minor issue found by CoverityScan
> CID 1358931 (#1 of 1): Uninitialized scalar variable (UNINIT)9.
> uninit_use: Using uninitialized value datasize.
> 199        prev_datasize = datasize;
> 200        status = efi.get_variable(name, vd, at, dz, data);
> 
> Signed-off-by: Ivan Hu <ivan.hu@xxxxxxxxxxxxx>
> ---
>  drivers/firmware/efi/test/efi_test.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/firmware/efi/test/efi_test.c b/drivers/firmware/efi/test/efi_test.c
> index 5602c46..87394f0 100644
> --- a/drivers/firmware/efi/test/efi_test.c
> +++ b/drivers/firmware/efi/test/efi_test.c
> @@ -156,7 +156,7 @@ static long efi_runtime_get_variable(unsigned long arg)
>  {
>  	struct efi_getvariable __user *getvariable_user;
>  	struct efi_getvariable getvariable;
> -	unsigned long datasize, prev_datasize, *dz;
> +	unsigned long datasize = 0, prev_datasize, *dz;
>  	efi_guid_t vendor_guid, *vd = NULL;
>  	efi_status_t status;
>  	efi_char16_t *name = NULL;

Thanks, applied to 'next'.
--
To unsubscribe from this list: send the line "unsubscribe linux-efi" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux