~piotr-sikora/libmemcached/fix-tests-on-openbsd

« back to all changes in this revision

Viewing changes to libmemcached/allocators.cc

  • Committer: Brian Aker
  • Date: 2011-04-28 00:30:03 UTC
  • mfrom: (929.1.88 libmemcached-build2)
  • Revision ID: brian@tangent.org-20110428003003-bm1qzgmg9kaawp5d
Merge in code for C++ compiling of libmemcached.

Show diffs side-by-side

added added

removed removed

Lines of Context:
35
35
  return calloc(nelem, size);
36
36
}
37
37
 
38
 
static const struct _allocators_st global_default_allocator= {
39
 
  .calloc= _libmemcached_calloc,
40
 
  .context= NULL,
41
 
  .free= _libmemcached_free,
42
 
  .malloc= _libmemcached_malloc,
43
 
  .realloc= _libmemcached_realloc
44
 
};
45
 
 
46
 
struct _allocators_st memcached_allocators_return_default(void)
 
38
struct memcached_allocator_t memcached_allocators_return_default(void)
47
39
{
 
40
  static struct memcached_allocator_t global_default_allocator= { _libmemcached_calloc, _libmemcached_free, _libmemcached_malloc, _libmemcached_realloc, 0 };
48
41
  return global_default_allocator;
49
42
}
50
43