man pages section 3: Multimedia Library Functions

Exit Print View

Updated: July 2014
 
 

mlib_realloc(3MLIB)

Name

mlib_realloc - reallocate a block of bytes

Synopsis

cc [ flag... ] file... –lmlib [ library... ]
#include <mlib.h>

void *mlib_realloc(void *ptr, size_t size);

Description

The mlib_realloc() function changes the size of the block pointed to by ptr to size bytes and returns a pointer to the (possibly moved) block.

This function is a wrapper of the standard C function realloc().

Parameters

The function takes the following arguments:

size

New size of the block in bytes.

ptr

Pointer to a block.

Return Values

The function returns a pointer to the reallocated block if successful. Otherwise it returns a null pointer.

Attributes

See attributes(5) for descriptions of the following attributes:

ATTRIBUTE TYPE
ATTRIBUTE VALUE
Interface Stability
Committed
MT-Level
MT-Safe

See also

mlib_free(3MLIB), mlib_malloc(3MLIB), malloc(3C), attributes(5)