~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to storage/heap/ha_heap.cc

  • Committer: Jay Pipes
  • Date: 2008-07-16 16:14:22 UTC
  • mto: This revision was merged to the branch mainline in revision 182.
  • Revision ID: jay@mysql.com-20080716161422-fy1bl8o5q7m8kglq
Removed all DBUG symbols from heap storage engine

Show diffs side-by-side

added added

removed removed

Lines of Context:
274
274
                            key_part_map keypart_map,
275
275
                            enum ha_rkey_function find_flag)
276
276
{
277
 
  DBUG_ASSERT(inited==INDEX);
 
277
  assert(inited==INDEX);
278
278
  ha_statistic_increment(&SSV::ha_read_key_count);
279
279
  int error = heap_rkey(file,buf,active_index, key, keypart_map, find_flag);
280
280
  table->status = error ? STATUS_NOT_FOUND : 0;
284
284
int ha_heap::index_read_last_map(uchar *buf, const uchar *key,
285
285
                                 key_part_map keypart_map)
286
286
{
287
 
  DBUG_ASSERT(inited==INDEX);
 
287
  assert(inited==INDEX);
288
288
  ha_statistic_increment(&SSV::ha_read_key_count);
289
289
  int error= heap_rkey(file, buf, active_index, key, keypart_map,
290
290
                       HA_READ_PREFIX_LAST);
304
304
 
305
305
int ha_heap::index_next(uchar * buf)
306
306
{
307
 
  DBUG_ASSERT(inited==INDEX);
 
307
  assert(inited==INDEX);
308
308
  ha_statistic_increment(&SSV::ha_read_next_count);
309
309
  int error=heap_rnext(file,buf);
310
310
  table->status=error ? STATUS_NOT_FOUND: 0;
313
313
 
314
314
int ha_heap::index_prev(uchar * buf)
315
315
{
316
 
  DBUG_ASSERT(inited==INDEX);
 
316
  assert(inited==INDEX);
317
317
  ha_statistic_increment(&SSV::ha_read_prev_count);
318
318
  int error=heap_rprev(file,buf);
319
319
  table->status=error ? STATUS_NOT_FOUND: 0;
322
322
 
323
323
int ha_heap::index_first(uchar * buf)
324
324
{
325
 
  DBUG_ASSERT(inited==INDEX);
 
325
  assert(inited==INDEX);
326
326
  ha_statistic_increment(&SSV::ha_read_first_count);
327
327
  int error=heap_rfirst(file, buf, active_index);
328
328
  table->status=error ? STATUS_NOT_FOUND: 0;
331
331
 
332
332
int ha_heap::index_last(uchar * buf)
333
333
{
334
 
  DBUG_ASSERT(inited==INDEX);
 
334
  assert(inited==INDEX);
335
335
  ha_statistic_increment(&SSV::ha_read_last_count);
336
336
  int error=heap_rlast(file, buf, active_index);
337
337
  table->status=error ? STATUS_NOT_FOUND: 0;
586
586
    return stats.records;
587
587
 
588
588
  /* Assert that info() did run. We need current statistics here. */
589
 
  DBUG_ASSERT(key_stat_version == file->s->key_stat_version);
 
589
  assert(key_stat_version == file->s->key_stat_version);
590
590
  return key->rec_per_key[key->key_parts-1];
591
591
}
592
592
 
632
632
      mem_per_row+=sizeof(TREE_ELEMENT)+pos->key_length+sizeof(char*);
633
633
      break;
634
634
    default:
635
 
      DBUG_ASSERT(0); // cannot happen
 
635
      assert(0); // cannot happen
636
636
    }
637
637
 
638
638
    for (; key_part != key_part_end; key_part++, seg++)
705
705
                              share->max_rows : max_rows),
706
706
                     (ulong) share->min_rows, &hp_create_info, &internal_share);
707
707
  my_free((uchar*) keydef, MYF(0));
708
 
  DBUG_ASSERT(file == 0);
 
708
  assert(file == 0);
709
709
  return (error);
710
710
}
711
711