1 /*
2  * Copyright (c) 2012 Tim Ruehsen
3  * Copyright (c) 2015-2021 Free Software Foundation, Inc.
4  *
5  * This file is part of libwget.
6  *
7  * Libwget is free software: you can redistribute it and/or modify
8  * it under the terms of the GNU Lesser General Public License as published by
9  * the Free Software Foundation, either version 3 of the License, or
10  * (at your option) any later version.
11  *
12  * Libwget is distributed in the hope that it will be useful,
13  * but WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
15  * GNU Lesser General Public License for more details.
16  *
17  * You should have received a copy of the GNU Lesser General Public License
18  * along with libwget.  If not, see <https://www.gnu.org/licenses/>.
19  *
20  *
21  * Memory allocation routines
22  *
23  * Changelog
24  * 25.06.2012  Tim Ruehsen  created
25  *
26  */
27 
28 #include <config.h>
29 
30 #include <stdlib.h>
31 
32 #include <wget.h>
33 #include "private.h"
34 
35 /**
36  * \file
37  * \brief Memory allocation functions
38  * \defgroup libwget-xalloc Memory allocation functions
39  * @{
40  *
41  * Global function pointers to memory allocation functions and to free().
42  *
43  * These pointers can be set to custom functions.
44  */
45 
46 wget_malloc_function *wget_malloc_fn = malloc;
47 wget_calloc_function *wget_calloc_fn = calloc;
48 wget_realloc_function *wget_realloc_fn = realloc;
49 wget_free_function *wget_free = free;
50 
51 /**@}*/
52