* Re: NetworkPkg: Fix invalid pointer for DNS response token on error [not found] <TU4PR8401MB065415F7B9E638BEF95BA635BA629@TU4PR8401MB0654.NAMPRD84.PROD.OUTLOOK.COM> @ 2021-11-25 1:28 ` Anbazhagan, Baraneedharan 2021-11-25 1:36 ` Wu, Jiaxin 0 siblings, 1 reply; 2+ messages in thread From: Anbazhagan, Baraneedharan @ 2021-11-25 1:28 UTC (permalink / raw) To: devel@edk2.groups.io Cc: maciej.rabeda@linux.intel.com, jiaxin.wu@intel.com, siyuan.fu@intel.com [-- Attachment #1: Type: text/plain, Size: 956 bytes --] Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=3719 Token->RspData.H2AData is de-allocated on error but it is not set to NULL. HTTP module attempts to free again and cause assert. Signed-off-by: Baraneedharan Anbazhagan anbazhagan@hp.com<mailto:anbazhagan@hp.com> --- NetworkPkg/DnsDxe/DnsImpl.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/NetworkPkg/DnsDxe/DnsImpl.c b/NetworkPkg/DnsDxe/DnsImpl.c index 2edcb280ac..78a56f2b56 100644 --- a/NetworkPkg/DnsDxe/DnsImpl.c +++ b/NetworkPkg/DnsDxe/DnsImpl.c @@ -1700,6 +1700,7 @@ ON_EXIT: } FreePool (Dns4TokenEntry->Token->RspData.H2AData); + Dns4TokenEntry->Token->RspData.H2AData = NULL; } } } @@ -1731,6 +1732,7 @@ ON_EXIT: } FreePool (Dns6TokenEntry->Token->RspData.H2AData); + Dns6TokenEntry->Token->RspData.H2AData = NULL; } } } -- 2.33.0.windows.2 [-- Attachment #2: Type: text/html, Size: 4150 bytes --] ^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: NetworkPkg: Fix invalid pointer for DNS response token on error 2021-11-25 1:28 ` NetworkPkg: Fix invalid pointer for DNS response token on error Anbazhagan, Baraneedharan @ 2021-11-25 1:36 ` Wu, Jiaxin 0 siblings, 0 replies; 2+ messages in thread From: Wu, Jiaxin @ 2021-11-25 1:36 UTC (permalink / raw) To: Anbazhagan, Baraneedharan, devel@edk2.groups.io Cc: maciej.rabeda@linux.intel.com, Fu, Siyuan [-- Attachment #1: Type: text/plain, Size: 1313 bytes --] Reviewed-by: Wu Jiaxin <jiaxin.wu@intel.com> From: Anbazhagan, Baraneedharan <anbazhagan@hp.com> Sent: Thursday, November 25, 2021 9:28 AM To: devel@edk2.groups.io Cc: maciej.rabeda@linux.intel.com; Wu, Jiaxin <jiaxin.wu@intel.com>; Fu, Siyuan <siyuan.fu@intel.com> Subject: RE: NetworkPkg: Fix invalid pointer for DNS response token on error Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=3719 Token->RspData.H2AData is de-allocated on error but it is not set to NULL. HTTP module attempts to free again and cause assert. Signed-off-by: Baraneedharan Anbazhagan anbazhagan@hp.com<mailto:anbazhagan@hp.com> --- NetworkPkg/DnsDxe/DnsImpl.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/NetworkPkg/DnsDxe/DnsImpl.c b/NetworkPkg/DnsDxe/DnsImpl.c index 2edcb280ac..78a56f2b56 100644 --- a/NetworkPkg/DnsDxe/DnsImpl.c +++ b/NetworkPkg/DnsDxe/DnsImpl.c @@ -1700,6 +1700,7 @@ ON_EXIT: } FreePool (Dns4TokenEntry->Token->RspData.H2AData); + Dns4TokenEntry->Token->RspData.H2AData = NULL; } } } @@ -1731,6 +1732,7 @@ ON_EXIT: } FreePool (Dns6TokenEntry->Token->RspData.H2AData); + Dns6TokenEntry->Token->RspData.H2AData = NULL; } } } -- 2.33.0.windows.2 [-- Attachment #2: Type: text/html, Size: 5266 bytes --] ^ permalink raw reply related [flat|nested] 2+ messages in thread
end of thread, other threads:[~2021-11-25 1:36 UTC | newest] Thread overview: 2+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- [not found] <TU4PR8401MB065415F7B9E638BEF95BA635BA629@TU4PR8401MB0654.NAMPRD84.PROD.OUTLOOK.COM> 2021-11-25 1:28 ` NetworkPkg: Fix invalid pointer for DNS response token on error Anbazhagan, Baraneedharan 2021-11-25 1:36 ` Wu, Jiaxin
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox