~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/user_var_entry.h

  • Committer: Olaf van der Spek
  • Date: 2011-10-06 18:18:31 UTC
  • mto: This revision was merged to the branch mainline in revision 2433.
  • Revision ID: olafvdspek@gmail.com-20111006181831-1ix5b80ry7iifbjf
Use lex_string assign(), data() and size()

Show diffs side-by-side

added added

removed removed

Lines of Context:
38
38
    unsigned_flag(false),
39
39
    collation(NULL, DERIVATION_IMPLICIT)
40
40
  { 
41
 
    name.str= strdup(arg);
42
 
    name.length= strlen(arg);
 
41
    name.assign(strdup(arg), strlen(arg));
43
42
  }
44
43
 
45
44
  ~user_var_entry()
46
45
  {
47
 
    free(const_cast<char*>(name.str));
 
46
    free(const_cast<char*>(name.data()));
48
47
    free(value);
49
48
  }
50
49