~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/optimizer/sel_arg.cc

  • Committer: Olaf van der Spek
  • Date: 2011-06-22 21:57:14 UTC
  • mto: This revision was merged to the branch mainline in revision 2348.
  • Revision ID: olafvdspek@gmail.com-20110622215714-0wmhwrx6of27etov
Refactor

Show diffs side-by-side

added added

removed removed

Lines of Context:
342
342
 
343
343
  if (type != KEY_RANGE)
344
344
  {
345
 
    if (! (tmp= new (param->mem_root) optimizer::SEL_ARG(type)))
346
 
      return 0; // out of memory
 
345
    tmp= new (param->mem_root) optimizer::SEL_ARG(type);
347
346
    tmp->prev= *next_arg; // Link into next/prev chain
348
347
    (*next_arg)->next= tmp;
349
348
    (*next_arg)= tmp;
350
349
  }
351
350
  else
352
351
  {
353
 
    if (! (tmp= new (param->mem_root) optimizer::SEL_ARG(field,
354
 
                                                         part,
355
 
                                                         min_value,
356
 
                                                         max_value,
357
 
                                                         min_flag,
358
 
                                                         max_flag,
359
 
                                                         maybe_flag)))
360
 
      return 0; // OOM
 
352
    tmp= new (param->mem_root) optimizer::SEL_ARG(field, part, min_value, max_value, min_flag, max_flag, maybe_flag);
361
353
    tmp->parent= new_parent;
362
354
    tmp->next_key_part= next_key_part;
363
355
    if (left != &optimizer::null_element)