Posts Tagged ‘malloc’
cfree – free allocated memory
USAGE
#include <stdlib.h>
/* In SunOS 4 */
int cfree(void *ptr);
/* In glibc or FreeBSD libcompat */
void cfree(void *ptr);
[...]
calloc, malloc, free, realloc – Allocate and free dynamic memory
USAGE
#include <stdlib.h>
void *calloc(size_t nmemb, size_t size);
void *malloc(size_t size);
void free(void *ptr);
void *realloc(void [...]
cdecl, c++decl – Compose C and C++ type declarations
USAGE
cdecl [-a | -+ | -p | -r] [-ciqdDV]
[[ files ...] | explain … | declare … | cast … | set … |
[...]
brk, sbrk – change data segment size
USAGE
#include <unistd.h>
int brk(void *end_data_segment);
void *sbrk(intptr_t increment);
DESCRIPTION
brk() sets the end of the data segment to [...]
asprintf, vasprintf – print to allocated string
USAGE
#define _GNU_SOURCE
#include <stdio.h>
int asprintf(char **strp, const char *fmt, …);
int vasprintf(char **strp, const char *fmt, va_list ap);
DESCRIPTION
[...]
alloca – memory allocator
USAGE
#include <alloca.h>
void *alloca(size_t size);
DESCRIPTION
The alloca() function allocates size bytes of space in the stack frame
of the caller. This temporary space is automatically [...]
