~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/statement/alter_table.cc

Merged up with latest plugin-slot-reorg.

Show diffs side-by-side

added added

removed removed

Lines of Context:
64
64
  Select_Lex *select_lex= &session->lex->select_lex;
65
65
  bool need_start_waiting= false;
66
66
 
67
 
  /*
68
 
     Code in alter_table() may modify its HA_CREATE_INFO argument,
69
 
     so we have to use a copy of this structure to make execution
70
 
     prepared statement- safe. A shallow copy is enough as no memory
71
 
     referenced from this structure will be modified.
72
 
   */
73
 
  HA_CREATE_INFO create_info(session->lex->create_info);
74
 
  AlterInfo alter_info(session->lex->alter_info, session->mem_root);
75
 
 
76
 
  if (session->is_fatal_error) /* out of memory creating a copy of alter_info */
77
 
  {
78
 
    return true;
79
 
  }
80
 
 
81
67
  /* Must be set in the parser */
82
68
  assert(select_lex->db);
83
69
 
96
82
                        select_lex->db, 
97
83
                        session->lex->name.str,
98
84
                        &create_info,
99
 
                        session->lex->create_table_proto,
 
85
                        &create_table_proto,
100
86
                        first_table,
101
87
                        &alter_info,
102
88
                        select_lex->order_list.elements,