~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to libdrizzle-2.0/result.cc

  • Committer: Brian Aker
  • Date: 2011-11-23 21:52:22 UTC
  • mfrom: (2461.1.4 drizzle-build)
  • mto: This revision was merged to the branch mainline in revision 2465.
  • Revision ID: brian@tangent.org-20111123215222-r9qdzhzch2b8jj2b
Break out options, first pass.

Show diffs side-by-side

added added

removed removed

Lines of Context:
58
58
      return NULL;
59
59
    }
60
60
 
61
 
    result->options|= DRIZZLE_RESULT_ALLOCATED;
 
61
    result->_options.is_allocated= true;
62
62
  }
63
63
  else
64
64
  {
93
93
    result->row_list= NULL;
94
94
    result->field_sizes= NULL;
95
95
    result->field_sizes_list= NULL;
 
96
 
 
97
    result->_options.is_allocated= false;
96
98
  }
97
99
 
98
100
  result->con= con;
117
119
    return NULL;
118
120
  }
119
121
 
120
 
  result->options|= from->options & ~DRIZZLE_RESULT_ALLOCATED;
 
122
  result->options= from->options;
121
123
 
122
124
  drizzle_result_set_info(result, from->info);
123
125
  result->error_code= from->error_code;
163
165
    if (result->con->result_list == result)
164
166
      result->con->result_list= result->next;
165
167
  }
 
168
 
166
169
  if (result->prev)
167
170
    result->prev->next= result->next;
 
171
 
168
172
  if (result->next)
169
173
    result->next->prev= result->prev;
170
174
 
171
 
  if (result->options & DRIZZLE_RESULT_ALLOCATED)
 
175
  if (result->_options.is_allocated)
 
176
  {
172
177
    delete result;
 
178
  }
173
179
}
174
180
 
175
181
void drizzle_result_free_all(drizzle_con_st *con)