~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/function/get_system_var.cc

  • Committer: Mark Atwood
  • Date: 2011-11-23 20:58:36 UTC
  • mfrom: (2462.2.1 rf)
  • Revision ID: me@mark.atwood.name-20111123205836-6vovpscxr5h3w8qi
mergeĀ lp:~olafvdspek/drizzle/refactor12

Show diffs side-by-side

added added

removed removed

Lines of Context:
58
58
{
59
59
  str_ref *base_name, *component_name;
60
60
 
61
 
  if (component.data())
 
61
  if (component.empty())
 
62
  {
 
63
    base_name= &name;
 
64
    component_name= &component;                 // Empty string
 
65
  }
 
66
  else
62
67
  {
63
68
    base_name= &component;
64
69
    component_name= &name;
65
70
  }
66
 
  else
67
 
  {
68
 
    base_name= &name;
69
 
    component_name= &component;                 // Empty string
70
 
  }
71
71
 
72
 
  sys_var *var= find_sys_var(base_name->data());
 
72
  sys_var *var= find_sys_var(*base_name);
73
73
  if (not var)
74
74
    return NULL;
75
 
  if (component.data())
 
75
  if (not component.empty())
76
76
  {
77
77
    my_error(ER_VARIABLE_IS_NOT_STRUCT, MYF(0), base_name->data());
78
78
    return NULL;