typedef struct memcached_server_st memcached_server_st;
typedef memcached_return (*clone_func)(memcached_st *parent, memcached_st *clone);
typedef memcached_return (*cleanup_func)(memcached_st *ptr);
-
+typedef void (*memcached_free_function)(memcached_st *ptr, void *mem);
+typedef void *(*memcached_malloc_function)(memcached_st *ptr, const size_t size);
+typedef void *(*memcached_realloc_function)(memcached_st *ptr, void *mem, const size_t size);
typedef enum {
MEMCACHED_DISTRIBUTION_MODULA,
MEMCACHED_CALLBACK_USER_DATA,
MEMCACHED_CALLBACK_CLEANUP_FUNCTION,
MEMCACHED_CALLBACK_CLONE_FUNCTION,
+ MEMCACHED_CALLBACK_MALLOC_FUNCTION,
+ MEMCACHED_CALLBACK_REALLOC_FUNCTION,
+ MEMCACHED_CALLBACK_FREE_FUNCTION,
} memcached_callback;
typedef enum {
unsigned int wheel[MEMCACHED_WHEEL_SIZE];
clone_func on_clone;
cleanup_func on_cleanup;
+ memcached_free_function call_free;
+ memcached_malloc_function call_malloc;
+ memcached_realloc_function call_realloc;
#ifdef NOT_USED /* Future Use */
uint8_t replicas;
memcached_return warning;