Author: cgutman
Date: Thu Apr 23 22:56:37 2009
New Revision: 40671
URL:
http://svn.reactos.org/svn/reactos?rev=40671&view=rev
Log:
- Fix the size passed to RtlZeroMemory so it also zeros the protocol reserved memory
Modified:
trunk/reactos/drivers/network/ndis/ndis/buffer.c
Modified: trunk/reactos/drivers/network/ndis/ndis/buffer.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/network/ndis/ndis/…
==============================================================================
--- trunk/reactos/drivers/network/ndis/ndis/buffer.c [iso-8859-1] (original)
+++ trunk/reactos/drivers/network/ndis/ndis/buffer.c [iso-8859-1] Thu Apr 23 22:56:37
2009
@@ -424,7 +424,7 @@
KeReleaseSpinLock(&Pool->SpinLock.SpinLock, OldIrql);
- RtlZeroMemory(Temp, sizeof(NDIS_PACKET));
+ RtlZeroMemory(Temp, Pool->PacketLength);
Temp->Private.Pool = Pool;
Temp->Private.ValidCounts = TRUE;
Temp->Private.NdisPacketFlags = fPACKET_ALLOCATED_BY_NDIS;
@@ -707,7 +707,7 @@
KeReleaseSpinLockFromDpcLevel(&Pool->SpinLock.SpinLock);
- RtlZeroMemory(Temp, sizeof(NDIS_PACKET));
+ RtlZeroMemory(Temp, Pool->PacketLength);
Temp->Private.Pool = Pool;
Temp->Private.ValidCounts = TRUE;
Temp->Private.NdisPacketFlags = fPACKET_ALLOCATED_BY_NDIS;
@@ -756,7 +756,7 @@
Temp = Pool->FreeList;
Pool->FreeList = (PNDIS_PACKET)Temp->Reserved[0];
- RtlZeroMemory(Temp, sizeof(NDIS_PACKET));
+ RtlZeroMemory(Temp, Pool->PacketLength);
Temp->Private.Pool = Pool;
Temp->Private.ValidCounts = TRUE;
Temp->Private.NdisPacketFlags = fPACKET_ALLOCATED_BY_NDIS;