malloc.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2014 Freie Universität Berlin
3  *
4  * This file is subject to the terms and conditions of the GNU Lesser
5  * General Public License v2.1. See the file LICENSE in the top level
6  * directory for more details.
7  */
8 
9 #pragma once
10 
34 #include <stdlib.h>
35 
36 #ifdef __cplusplus
37 extern "C" {
38 #endif
39 
45 void *malloc(size_t size);
46 
57 void *realloc(void *ptr, size_t size);
58 
67 void *calloc(size_t size, size_t cnt);
68 
75 void free(void *ptr);
76 
77 #ifdef __cplusplus
78 }
79 #endif
80 
void * realloc(void *ptr, size_t size)
Allocated a new block of memory and move the existing content.
void * calloc(size_t size, size_t cnt)
Allocate a memory block and set all its content to zeroes.
void * malloc(size_t size)
Allocation a block of memory.
void free(void *ptr)
This is a no-op.