A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://en.wikibooks.org/wiki/C++_Programming/Code/Standard_C_Library/Functions/realloc below:

C++ Programming/Code/Standard C Library/Functions/realloc - Wikibooks, open books for an open world

From Wikibooks, open books for an open world

Syntax
#include <cstdlib>
void *realloc( void *p, size_t s);

The function realloc() resizes a block created by malloc() or calloc(), and returns a pointer to the new memory region.

If the resize operation fails, realloc() returns NULL and leaves the old memory region intact.

Note: realloc() does not have a corresponding operator in C++ - however, this is not required since the standard template library already provides the necessary memory management for most usages.

Related topics
calloc - free - malloc

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4