Can someone help me with commit of this patch?

-----Original Message-----
From: Ye, Ting [mailto:ting...@intel.com] 
Sent: Thursday, October 29, 2015 6:57 AM
To: Hegde, Nagaraj P; edk2-devel@lists.01.org
Subject: RE: [edk2] [PATCH] NetworkPkg: HttpDxe: Address double FreePool issue

Looks good to me. 

Reviewed-by: Ye Ting <ting...@intel.com> 

-----Original Message-----
From: edk2-devel [mailto:edk2-devel-boun...@lists.01.org] On Behalf Of Nagaraj 
Hegde
Sent: Wednesday, October 28, 2015 4:54 PM
To: edk2-devel@lists.01.org
Cc: Nagaraj Hegde
Subject: [edk2] [PATCH] NetworkPkg: HttpDxe: Address double FreePool issue

In EfiHttpRequest, HostName was getting freed twice whenever
HttpTransmitTcp4 failed. Moved FreePool (HostName) after
HttpTransmitTcp4 call to avoid a double free.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Nagaraj Hegde <nagaraj-p.he...@hpe.com>
---
 NetworkPkg/HttpDxe/HttpImpl.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/NetworkPkg/HttpDxe/HttpImpl.c b/NetworkPkg/HttpDxe/HttpImpl.c 
index 588e1bb..3094400 100644
--- a/NetworkPkg/HttpDxe/HttpImpl.c
+++ b/NetworkPkg/HttpDxe/HttpImpl.c
@@ -485,10 +485,6 @@ EfiHttpRequest (
     goto Error4;
   }
 
-  if (HostName != NULL) {
-    FreePool (HostName);
-  }
-
   //
   // Transmit the request message.
   //
@@ -504,6 +500,10 @@ EfiHttpRequest (
 
   DispatchDpc ();
 
+  if (HostName != NULL) {
+    FreePool (HostName);
+  }
+
   return EFI_SUCCESS;
 
 Error5:
--
2.6.2.windows.1

_______________________________________________
edk2-devel mailing list
edk2-devel@lists.01.org
https://lists.01.org/mailman/listinfo/edk2-devel
_______________________________________________
edk2-devel mailing list
edk2-devel@lists.01.org
https://lists.01.org/mailman/listinfo/edk2-devel

Reply via email to