IMallocSpy::PreDidAlloc method (objidl.h)

Performs operations required before calling IMalloc::DidAlloc.

Syntax

void * PreDidAlloc(
  [in] void *pRequest,
  [in] BOOL fSpyed
);

Parameters

[in] pRequest

The pointer specified in the call to DidAlloc.

[in] fSpyed

Indicates whether the allocation was done while this spy was active.

Return value

The value passed to DidAlloc as the fActual parameter.

Remarks

When a spy object implementing IMallocSpy is registered with the CoRegisterMallocSpy function, COM calls this method immediately before any call to IMalloc::DidAlloc. This method is included for completeness and consistency; it is not anticipated that developers will implement significant functionality in this method.

Requirements

Requirement Value
Minimum supported client Windows 2000 Professional [desktop apps only]
Minimum supported server Windows 2000 Server [desktop apps only]
Target Platform Windows
Header objidl.h

See also

IMalloc::DidAlloc

IMallocSpy

IMallocSpy::PostDidAlloc