~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/memory/multi_malloc.cc

  • Committer: Brian Aker
  • Date: 2010-10-20 20:25:52 UTC
  • mto: (1864.2.1 merge)
  • mto: This revision was merged to the branch mainline in revision 1865.
  • Revision ID: brian@tangent.org-20101020202552-51y5sz5ledoxbp7t
Add support for --with-valgrind

Show diffs side-by-side

added added

removed removed

Lines of Context:
61
61
  }
62
62
  va_end(args);
63
63
 
 
64
#ifdef HAVE_VALGRIND
 
65
  if (!(start= calloc(0, tot_length)))
 
66
    return(0);
 
67
#else
64
68
  if (!(start= malloc(tot_length)))
65
69
    return(0);
66
70
  if (zerofill)
67
71
    memset(start, 0, tot_length);
 
72
#endif
68
73
 
69
74
  va_start(args, zerofill);
70
75
  res= static_cast<char *>(start);