Export (0) Print
Expand All
Expand Minimize

ExFreePool routine

The ExFreePool routine deallocates a block of pool memory.

Syntax


VOID ExFreePool(
  _In_  PVOID P
);

Parameters

P [in]

Specifies the address of the block of pool memory being deallocated.

Return value

None

Remarks

This routine releases memory allocated by ExAllocatePool, ExAllocatePoolWithTag, ExAllocatePoolWithQuota, or ExAllocatePoolWithQuotaTag. The memory block must not be accessed after it is freed.

Drivers can also use the ExFreePoolWithTag routine to free buffers allocated by ExAllocatePoolWithTag and ExAllocatePoolWithQuotaTag.

Callers of ExFreePool must be running at IRQL <= DISPATCH_LEVEL. A caller at DISPATCH_LEVEL must have specified a NonPagedXxxPoolType when the memory was allocated. Otherwise, the caller must be running at IRQL <= APC_LEVEL.

Requirements

Version

Available starting with Windows 2000.

Header

Wdm.h (include Wdm.h, Ntddk.h, or Ntifs.h)

Library

Ntoskrnl.lib

IRQL

<= DISPATCH_LEVEL (see Remarks section)

DDI compliance rules

DoubleExFreePool

See also

ExAllocatePool
ExAllocatePoolWithQuota
ExAllocatePoolWithQuotaTag
ExAllocatePoolWithTag
ExFreePoolWithTag

 

 

Send comments about this topic to Microsoft

Show:
© 2014 Microsoft