~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to plugin/heap/hp_create.cc

  • Committer: Monty Taylor
  • Date: 2010-02-11 01:35:55 UTC
  • mfrom: (1289 staging)
  • mto: This revision was merged to the branch mainline in revision 1293.
  • Revision ID: mordred@inaugust.com-20100211013555-f9okqsgi91mwm4xu
Merged up with trunk.

Show diffs side-by-side

added added

removed removed

Lines of Context:
22
22
#include <algorithm>
23
23
 
24
24
using namespace std;
 
25
using namespace drizzled;
25
26
 
26
27
static int keys_compare(heap_rb_param *param, unsigned char *key1, unsigned char *key2);
27
28
static void init_block(HP_BLOCK *block,uint32_t chunk_length, uint32_t min_records,
405
406
  if (records_in_block < 10 && max_records)
406
407
    records_in_block= 10;
407
408
  if (!records_in_block || records_in_block*recbuffer >
408
 
      (my_default_record_cache_size-sizeof(HP_PTRS)*HP_MAX_LEVELS))
409
 
    records_in_block= (my_default_record_cache_size - sizeof(HP_PTRS) *
 
409
      (internal::my_default_record_cache_size-sizeof(HP_PTRS)*HP_MAX_LEVELS))
 
410
    records_in_block= (internal::my_default_record_cache_size - sizeof(HP_PTRS) *
410
411
                      HP_MAX_LEVELS) / recbuffer + 1;
411
412
  block->records_in_block= records_in_block;
412
413
  block->recbuffer= recbuffer;