Export (0) Print
Expand All

IMalloc::GetSize

Windows CE .NET

This method returns the size (in bytes) of a memory block previously allocated with the IMalloc::Alloc or IMalloc::Realloc method.

ULONG GetSize(
  void* pv 
);

Parameters

pv
[in] Pointer to the memory block for which the size is requested.

Return Values

The size of the allocated memory block in bytes or, if pv is a NULL pointer, -1.

Remarks

To get the size in bytes of a memory block, the block must have been previously allocated with IMalloc::Alloc or IMalloc::Realloc. The size returned is the actual size of the allocation, which may be greater than the size requested when the allocation was made.

To determine whether the platform supports this interface, see Determining Supported COM APIs.

Requirements

OS Versions: Windows CE 3.0 and later.
Header: Objidl.h, Objidl.idl.
Link Library: Ole32.lib

See Also

IMalloc::Alloc | IMalloc::Realloc


Last updated on Wednesday, April 13, 2005

© 2005 Microsoft Corporation. All rights reserved.

Show:
© 2014 Microsoft