_msize
Important This document may not represent best practices for current development, links to downloads and other resources may no longer be valid. Current recommended version can be found here. ArchiveDisclaimer

_msize

Returns the size of a memory block allocated in the heap.

size_t _msize(
   void *memblock 
);

Parameter

memblock
Pointer to memory block.

Return Value

_msize returns the size (in bytes) as an unsigned integer.

Remarks

The _msize function returns the size, in bytes, of the memory block allocated by a call to calloc, malloc, or realloc.

When the application is linked with a debug version of the C run-time libraries, _msize resolves to _msize_dbg. For more information about how the heap is managed during the debugging process, see The CRT Debug Heap.

Requirements

Routine Required header Compatibility
_msize <malloc.h> Win 98, Win Me, Win NT, Win 2000, Win XP

For additional compatibility information, see Compatibility in the Introduction.

Libraries

All versions of the C run-time libraries.

Example

See the example for realloc.

See Also

Memory Allocation Routines | calloc | _expand | malloc | realloc | Run-Time Routines and .NET Framework Equivalents

Show:
© 2016 Microsoft