~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/sql_parse.cc

  • Committer: Toru Maesaka
  • Date: 2008-12-14 08:26:38 UTC
  • mto: (670.1.24 devel)
  • mto: This revision was merged to the branch mainline in revision 676.
  • Revision ID: dev@torum.net-20081214082638-c8uje8oiwk4s2dh0
First pass of replacing MySQL's strxmov with libc alternatives

Show diffs side-by-side

added added

removed removed

Lines of Context:
2574
2574
  LEX *lex;
2575
2575
  LEX_STRING tmp, null_lex_string;
2576
2576
  Item *var;
2577
 
  char buff[MAX_SYS_VAR_LENGTH*2+4+8], *end;
 
2577
  char buff[MAX_SYS_VAR_LENGTH*2+4+8];
 
2578
  char *end= buff;
2578
2579
 
2579
2580
  session= current_session;
2580
2581
  lex= session->lex;
2589
2590
  */
2590
2591
  if ((var= get_system_var(session, OPT_SESSION, tmp, null_lex_string)))
2591
2592
  {
2592
 
    end= strxmov(buff, "@@session.", var_name, NULL);
 
2593
    end+= sprintf(buff, "@@session.%s", var_name);
2593
2594
    var->set_name(buff, end-buff, system_charset_info);
2594
2595
    add_item_to_list(session, var);
2595
2596
  }
3632
3633
  if (!(ptr= (char*) session->alloc((size_t) (end-buff) + strlen(table_name)+1)))
3633
3634
    return 1;                                   // End of memory
3634
3635
  *filename_ptr=ptr;
3635
 
  strxmov(ptr,buff,table_name,NULL);
 
3636
  sprintf(ptr,"%s%s",buff,table_name);
3636
3637
  return 0;
3637
3638
}
3638
3639