~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to storage/heap/hp_delete.c

  • Committer: Monty Taylor
  • Date: 2009-01-30 21:02:37 UTC
  • mto: (779.7.3 devel)
  • mto: This revision was merged to the branch mainline in revision 823.
  • Revision ID: mordred@inaugust.com-20090130210237-3n6ld8a9jc084jko
Commented out a test in subselect_sj - I think it might be a regression. Jay?

Show diffs side-by-side

added added

removed removed

Lines of Context:
17
17
 
18
18
#include "heapdef.h"
19
19
 
20
 
int heap_delete(HP_INFO *info, const uchar *record)
 
20
int heap_delete(HP_INFO *info, const unsigned char *record)
21
21
{
22
 
  uchar *pos;
 
22
  unsigned char *pos;
23
23
  HP_SHARE *share=info->s;
24
24
  HP_KEYDEF *keydef, *end, *p_lastinx;
25
 
  uint rec_length, chunk_count;
 
25
  uint32_t rec_length, chunk_count;
26
26
 
27
27
  test_active(info);
28
28
 
36
36
  pos=info->current_ptr;
37
37
 
38
38
  p_lastinx = share->keydef + info->lastinx;
39
 
  for (keydef = share->keydef, end = keydef + share->keys; keydef < end; 
 
39
  for (keydef = share->keydef, end = keydef + share->keys; keydef < end;
40
40
       keydef++)
41
41
  {
42
42
    if ((*keydef->delete_key)(info, keydef, record, pos, keydef == p_lastinx))
60
60
*/
61
61
 
62
62
int hp_rb_delete_key(HP_INFO *info, register HP_KEYDEF *keyinfo,
63
 
                   const uchar *record, uchar *recpos, int flag)
 
63
                   const unsigned char *record, unsigned char *recpos, int flag)
64
64
{
65
65
  heap_rb_param custom_arg;
66
 
  uint old_allocated;
 
66
  uint32_t old_allocated;
67
67
  int res;
68
68
 
69
 
  if (flag) 
 
69
  if (flag)
70
70
    info->last_pos= NULL; /* For heap_rnext/heap_rprev */
71
71
 
72
72
  custom_arg.keyseg= keyinfo->seg;
97
97
*/
98
98
 
99
99
int hp_delete_key(HP_INFO *info, register HP_KEYDEF *keyinfo,
100
 
                  const uchar *record, uchar *recpos, int flag)
 
100
                  const unsigned char *record, unsigned char *recpos, int flag)
101
101
{
102
102
  uint32_t blength,pos2,pos_hashnr,lastpos_hashnr;
103
103
  HASH_INFO *lastpos,*gpos,*pos,*pos3,*empty,*last_ptr;