From: "Philippe Mathieu-Daudé" <philmd@redhat.com>
To: devel@edk2.groups.io, michael.a.kubacki@intel.com
Cc: Liming Gao <liming.gao@intel.com>,
Michael D Kinney <michael.d.kinney@intel.com>,
Jian J Wang <jian.j.wang@intel.com>,
Hao A Wu <hao.a.wu@intel.com>
Subject: Re: [edk2-devel] [PATCH V2 2/2] MdeModulePkg/Variable: Initialize local variable "RtPtrTrack"
Date: Fri, 22 Nov 2019 12:24:59 +0100 [thread overview]
Message-ID: <ee32cbe6-3e1b-2052-80f4-d62b88502898@redhat.com> (raw)
In-Reply-To: <20191121230236.29668-3-michael.a.kubacki@intel.com>
On 11/22/19 12:02 AM, Kubacki, Michael A wrote:
> REF:https://bugzilla.tianocore.org/show_bug.cgi?id=2364
>
> Fixes a new build warning in VS2012 introduced in f8ff4cca7c.
>
> This patch initializes the local variable "RtPtrTrack" in
> FindVariableInRuntimeCache ().
>
> This ensures the pointers in the structure are initialized
> in the case no variable stores exist in the list of variable
> stores.
>
> Cc: Liming Gao <liming.gao@intel.com>
> Cc: Michael D Kinney <michael.d.kinney@intel.com>
> Cc: Jian J Wang <jian.j.wang@intel.com>
> Cc: Hao A Wu <hao.a.wu@intel.com>
> Signed-off-by: Michael Kubacki <michael.a.kubacki@intel.com>
> Reviewed-by: Liming Gao <liming.gao@intel.com>
> Reviewed-by: Jian J Wang <jian.j.wang@intel.com>
> ---
> MdeModulePkg/Universal/Variable/RuntimeDxe/VariableSmmRuntimeDxe.c | 2 ++
> 1 file changed, 2 insertions(+)
>
> diff --git a/MdeModulePkg/Universal/Variable/RuntimeDxe/VariableSmmRuntimeDxe.c b/MdeModulePkg/Universal/Variable/RuntimeDxe/VariableSmmRuntimeDxe.c
> index d525998ae3..2cf0ed32ae 100644
> --- a/MdeModulePkg/Universal/Variable/RuntimeDxe/VariableSmmRuntimeDxe.c
> +++ b/MdeModulePkg/Universal/Variable/RuntimeDxe/VariableSmmRuntimeDxe.c
> @@ -590,6 +590,8 @@ FindVariableInRuntimeCache (
> return EFI_INVALID_PARAMETER;
> }
>
> + ZeroMem (&RtPtrTrack, sizeof (RtPtrTrack));
> +
> //
> // The UEFI specification restricts Runtime Services callers from invoking the same or certain other Runtime Service
> // functions prior to completion and return from a previous Runtime Service call. These restrictions prevent
>
Reviewed-by: Philippe Mathieu-Daude <philmd@redhat.com>
prev parent reply other threads:[~2019-11-22 11:25 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-11-21 23:02 [PATCH V2 0/2] MdeModulePkg/Variable: Initialize local variables Kubacki, Michael A
2019-11-21 23:02 ` [PATCH V2 1/2] MdeModulePkg/Variable: Initialize local variable "Variable" Kubacki, Michael A
2019-11-25 14:36 ` Liming Gao
2019-11-21 23:02 ` [PATCH V2 2/2] MdeModulePkg/Variable: Initialize local variable "RtPtrTrack" Kubacki, Michael A
2019-11-22 11:24 ` Philippe Mathieu-Daudé [this message]
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-list 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=ee32cbe6-3e1b-2052-80f4-d62b88502898@redhat.com \
--to=devel@edk2.groups.io \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox