Platform SDK: Network Management

NetApiBufferReallocate

The NetApiBufferReallocate function changes the size of a buffer allocated by a previous call to the NetApiBufferAllocate function.

NET_API_STATUS NetApiBufferReallocate(
  LPVOID OldBuffer,    
  DWORD NewByteCount,  
  LPVOID *NewBuffer    
);

Parameters

OldBuffer
[in] Pointer to the buffer returned by a call to the NetApiBufferAllocate function.
NewByteCount
[in] Specifies the new size of the buffer, in bytes.
NewBuffer
[out] Receives the pointer to the reallocated buffer.

Return Values

If the function succeeds, the return value is NERR_Success.

If the function fails, the return value is a Win32 API error code. For a list of error codes, see Error Codes.

Requirements

  Windows NT/2000: Requires Windows NT 3.1 or later.
  Windows 95/98: Unsupported.
  Header: Declared in Lmapibuf.h; include Lm.h.
  Library: Use Netapi32.lib.

See Also

Network Management Overview, Network Management Functions, Api Buffer Functions, NetApiBufferAllocate, NetApiBufferFree