[edk2-devel] [Patch V5 07/11] EmulatorPkg/Unix/Host: Initialize field in BerkeleyPacketFilter.c

Michael D Kinney michael.d.kinney at intel.com
Sat Aug 17 00:57:11 UTC 2019


From: Andrew Fish <afish at apple.com>

Initialize Private->ReadBuffer to NULL.

Cc: Jordan Justen <jordan.l.justen at intel.com>
Cc: Ray Ni <ray.ni at intel.com>
Cc: Michael D Kinney <michael.d.kinney at intel.com>
Signed-off-by: Andrew Fish <afish at apple.com>
Reviewed-by: Michael D Kinney <michael.d.kinney at intel.com>
Tested-by: Andrew Fish <afish at apple.com>
---
 EmulatorPkg/Unix/Host/BerkeleyPacketFilter.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/EmulatorPkg/Unix/Host/BerkeleyPacketFilter.c b/EmulatorPkg/Unix/Host/BerkeleyPacketFilter.c
index 8d0eb0d197..540340f25f 100644
--- a/EmulatorPkg/Unix/Host/BerkeleyPacketFilter.c
+++ b/EmulatorPkg/Unix/Host/BerkeleyPacketFilter.c
@@ -216,6 +216,7 @@ EmuSnpStart (
   }
 
   Status = EFI_SUCCESS;
+  Private->ReadBuffer = NULL;
   if (Private->BpfFd == 0) {
     Status = OpenBpfFileDescriptor (Private, &Private->BpfFd);
     if (EFI_ERROR (Status)) {
-- 
2.21.0.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#45960): https://edk2.groups.io/g/devel/message/45960
Mute This Topic: https://groups.io/mt/32918481/1813853
Group Owner: devel+owner at edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [edk2-devel-archive at redhat.com]
-=-=-=-=-=-=-=-=-=-=-=-




More information about the edk2-devel-archive mailing list