~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/sql_parse.cc

  • Committer: Grant Limberg
  • Date: 2008-08-12 21:29:49 UTC
  • mfrom: (322 drizzle)
  • mto: (322.1.1 codestyle)
  • mto: This revision was merged to the branch mainline in revision 324.
  • Revision ID: grant@glsoftware.net-20080812212949-i7vl3lz5y7u7tdry
Merge from trunk

Did a global search and replace for MYSQL_* variables.  Renamed to DRIZZLE_*.

Renamed value of DRIZZLE_CONFIG_NAME from "my" to "drizzled"

Show diffs side-by-side

added added

removed removed

Lines of Context:
2895
2895
 
2896
2896
    Lex_input_stream lip(thd, inBuf, length);
2897
2897
 
2898
 
    bool err= parse_sql(thd, &lip, NULL);
 
2898
    bool err= parse_sql(thd, &lip);
2899
2899
    *found_semicolon= lip.found_semicolon;
2900
2900
 
2901
2901
    if (!err)
2955
2955
  lex_start(thd);
2956
2956
  mysql_reset_thd_for_next_command(thd);
2957
2957
 
2958
 
  if (!parse_sql(thd, &lip, NULL) &&
 
2958
  if (!parse_sql(thd, &lip) &&
2959
2959
      all_tables_not_ok(thd,(TABLE_LIST*) lex->select_lex.table_list.first))
2960
2960
    error= 1;                  /* Ignore question */
2961
2961
  thd->end_statement();
4440
4440
 
4441
4441
  @param thd Thread context.
4442
4442
  @param lip Lexer context.
4443
 
  @param creation_ctx Object creation context.
4444
4443
 
4445
4444
  @return Error status.
4446
4445
    @retval false on success.
4447
4446
    @retval true on parsing error.
4448
4447
*/
4449
4448
 
4450
 
bool parse_sql(THD *thd,
4451
 
               Lex_input_stream *lip,
4452
 
               Object_creation_ctx *creation_ctx)
 
4449
bool parse_sql(THD *thd, Lex_input_stream *lip)
4453
4450
{
4454
4451
  assert(thd->m_lip == NULL);
4455
4452
 
4456
 
  /* Backup creation context. */
4457
 
 
4458
 
  Object_creation_ctx *backup_ctx= NULL;
4459
 
 
4460
 
  if (creation_ctx)
4461
 
    backup_ctx= creation_ctx->set_n_backup(thd);
4462
 
 
4463
4453
  /* Set Lex_input_stream. */
4464
4454
 
4465
4455
  thd->m_lip= lip;
4476
4466
 
4477
4467
  thd->m_lip= NULL;
4478
4468
 
4479
 
  /* Restore creation context. */
4480
 
 
4481
 
  if (creation_ctx)
4482
 
    creation_ctx->restore_env(thd, backup_ctx);
4483
 
 
4484
4469
  /* That's it. */
4485
4470
 
4486
4471
  return mysql_parse_status || thd->is_fatal_error;