File Refactoring
[m6w6/libmemcached] / libmemcached / allocators.h
1 /* LibMemcached
2 * Copyright (C) 2010 Brian Aker
3 * All rights reserved.
4 *
5 * Use and distribution licensed under the BSD license. See
6 * the COPYING file in the parent directory for full text.
7 *
8 * Summary: work with user defined memory allocators
9 *
10 */
11
12 #ifndef __MEMCACHED_ALLOCATORS_H__
13 #define __MEMCACHED_ALLOCATORS_H__
14
15 #ifdef __cplusplus
16 extern "C" {
17 #endif
18
19 LIBMEMCACHED_API
20 memcached_return_t memcached_set_memory_allocators(memcached_st *ptr,
21 memcached_malloc_fn mem_malloc,
22 memcached_free_fn mem_free,
23 memcached_realloc_fn mem_realloc,
24 memcached_calloc_fn mem_calloc);
25
26 LIBMEMCACHED_API
27 void memcached_get_memory_allocators(memcached_st *ptr,
28 memcached_malloc_fn *mem_malloc,
29 memcached_free_fn *mem_free,
30 memcached_realloc_fn *mem_realloc,
31 memcached_calloc_fn *mem_calloc);
32
33
34 #ifdef __cplusplus
35 }
36 #endif
37
38 #endif /* __MEMCACHED_ALLOCATORS_H__ */