~mordred/libmemcached/fix-weird-link

« back to all changes in this revision

Viewing changes to libmemcached/memcached_callback.c

  • Committer: Brian Aker
  • Date: 2009-12-16 19:03:49 UTC
  • Revision ID: brian@gir.tangent.org-20091216190349-0qtf5mw4b88lxvbi
Updated copyright headers.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/* LibMemcached
 
2
 * Copyright (C) 2006-2009 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: Change any of the possible callbacks.
 
9
 *
 
10
 */
 
11
 
1
12
#include "common.h" 
2
13
#include <sys/types.h>
3
14
#include <sys/socket.h>
65
76
#ifdef MEMCACHED_ENABLE_DEPRECATED
66
77
  case MEMCACHED_CALLBACK_MALLOC_FUNCTION:
67
78
    {
68
 
      memcached_malloc_function func= *(memcached_malloc_function *)&data;
 
79
      memcached_malloc_function func= *(memcached_malloc_fn *)&data;
69
80
      ptr->call_malloc= func;
70
81
      break;
71
82
    }
72
83
  case MEMCACHED_CALLBACK_REALLOC_FUNCTION:
73
84
    {
74
 
      memcached_realloc_function func= *(memcached_realloc_function *)&data;
 
85
      memcached_realloc_function func= *(memcached_realloc_fn *)&data;
75
86
      ptr->call_realloc= func;
76
87
      break;
77
88
    }
78
89
  case MEMCACHED_CALLBACK_FREE_FUNCTION:
79
90
    {
80
 
      memcached_free_function func= *(memcached_free_function *)&data;
 
91
      memcached_free_function func= *(memcached_free_fn *)&data;
81
92
      ptr->call_free= func;
82
93
      break;
83
94
    }