All of lore.kernel.org
 help / color / mirror / Atom feed
From: Matt Fleming <matt-mF/unelCI9GS6iBeEJttW/XRex20P6io@public.gmane.org>
To: Ivan Hu <ivan.hu-Z7WLFzj8eWMS+FvcfC7Uqw@public.gmane.org>
Cc: linux-efi-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	Ard Biesheuvel
	<ard.biesheuvel-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org>
Subject: Re: [PATCH 2/3] efi/efi_test: fix the uninitialized value datasize
Date: Mon, 3 Oct 2016 21:23:56 +0100	[thread overview]
Message-ID: <20161003202356.GM16071@codeblueprint.co.uk> (raw)
In-Reply-To: <1474859691-8574-3-git-send-email-ivan.hu-Z7WLFzj8eWMS+FvcfC7Uqw@public.gmane.org>

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-Z7WLFzj8eWMS+FvcfC7Uqw@public.gmane.org>
> ---
>  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'.

  parent reply	other threads:[~2016-10-03 20:23 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-09-26  3:14 [PATCH 0/3] efi_test: fix Coccinelle warning and CoverityScan issues Ivan Hu
     [not found] ` <1474859691-8574-1-git-send-email-ivan.hu-Z7WLFzj8eWMS+FvcfC7Uqw@public.gmane.org>
2016-09-26  3:14   ` [PATCH 1/3] efi/efi_test: use memdup_user() as a cleanup Ivan Hu
     [not found]     ` <1474859691-8574-2-git-send-email-ivan.hu-Z7WLFzj8eWMS+FvcfC7Uqw@public.gmane.org>
2016-10-03 20:17       ` Matt Fleming
     [not found]         ` <20161003201718.GL16071-mF/unelCI9GS6iBeEJttW/XRex20P6io@public.gmane.org>
2016-10-04  3:04           ` ivanhu
     [not found]             ` <3fb6d9fa-b554-509b-fc59-d75340017589-Z7WLFzj8eWMS+FvcfC7Uqw@public.gmane.org>
2016-10-04 21:37               ` Matt Fleming
     [not found]                 ` <20161004213743.GV16071-mF/unelCI9GS6iBeEJttW/XRex20P6io@public.gmane.org>
2016-10-05  1:31                   ` ivanhu
2016-09-26  3:14   ` [PATCH 2/3] efi/efi_test: fix the uninitialized value datasize Ivan Hu
     [not found]     ` <1474859691-8574-3-git-send-email-ivan.hu-Z7WLFzj8eWMS+FvcfC7Uqw@public.gmane.org>
2016-10-03 20:23       ` Matt Fleming [this message]
2016-09-26  3:14   ` [PATCH 3/3] efi/efi_test: fix the uninitialized value rv Ivan Hu
     [not found]     ` <1474859691-8574-4-git-send-email-ivan.hu-Z7WLFzj8eWMS+FvcfC7Uqw@public.gmane.org>
2016-10-03 20:25       ` Matt Fleming

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20161003202356.GM16071@codeblueprint.co.uk \
    --to=matt-mf/unelci9gs6ibeejttw/xrex20p6io@public.gmane.org \
    --cc=ard.biesheuvel-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org \
    --cc=ivan.hu-Z7WLFzj8eWMS+FvcfC7Uqw@public.gmane.org \
    --cc=linux-efi-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.