Commit c26ffedb authored by unknown's avatar unknown
Browse files

Merge mysql.com:/home/svoj/devel/bk/mysql-5.0

into  mysql.com:/home/svoj/devel/mysql/merge/mysql-5.0-engines


mysql-test/r/symlink.result:
  Auto merged
mysql-test/t/symlink.test:
  Auto merged
sql/table.cc:
  Auto merged
mysql-test/r/myisam.result:
  Manually merged.
mysql-test/t/myisam.test:
  Manually merged.
parents 3f064efb 6bb5fd6b
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -121,6 +121,7 @@ typedef struct st_thr_lock {
  void (*get_status)(void*, int);	/* When one gets a lock */
  void (*copy_status)(void*,void*);
  void (*update_status)(void*);		/* Before release of write */
  void (*restore_status)(void*);         /* Before release of read */
  my_bool (*check_status)(void *);
} THR_LOCK;

+7 −6
Original line number Diff line number Diff line
@@ -815,18 +815,19 @@ uint mi_get_pointer_length(ulonglong file_length, uint def)
  if (file_length)				/* If not default */
  {
#ifdef NOT_YET_READY_FOR_8_BYTE_POINTERS
    if (file_length >= (longlong) 1 << 56)
    if (file_length >= ULL(1) << 56)
      def=8;
    else
#endif
    if (file_length >= (longlong) 1 << 48)
    if (file_length >= ULL(1) << 48)
      def=7;
    if (file_length >= (longlong) 1 << 40)
    else if (file_length >= ULL(1) << 40)
      def=6;
    else if (file_length >= (longlong) 1 << 32)
    else if (file_length >= ULL(1) << 32)
      def=5;
    else if (file_length >= (1L << 24))
    else if (file_length >= ULL(1) << 24)
      def=4;
    else if (file_length >= (1L << 16))
    else if (file_length >= ULL(1) << 16)
      def=3;
    else
      def=2;
+2 −2
Original line number Diff line number Diff line
@@ -80,7 +80,7 @@ int _mi_write_blob_record(MI_INFO *info, const byte *record)
#endif
  if (!(rec_buff=(byte*) my_alloca(reclength)))
  {
    my_errno=ENOMEM;
    my_errno= HA_ERR_OUT_OF_MEM; /* purecov: inspected */
    return(-1);
  }
  reclength2= _mi_rec_pack(info,rec_buff+ALIGN_SIZE(MI_MAX_DYN_BLOCK_HEADER),
@@ -114,7 +114,7 @@ int _mi_update_blob_record(MI_INFO *info, my_off_t pos, const byte *record)
#endif
  if (!(rec_buff=(byte*) my_alloca(reclength)))
  {
    my_errno=ENOMEM;
    my_errno= HA_ERR_OUT_OF_MEM; /* purecov: inspected */
    return(-1);
  }
  reclength=_mi_rec_pack(info,rec_buff+ALIGN_SIZE(MI_MAX_DYN_BLOCK_HEADER),
+9 −0
Original line number Diff line number Diff line
@@ -325,6 +325,15 @@ void mi_update_status(void* param)
  }
}


void mi_restore_status(void *param)
{
  MI_INFO *info= (MI_INFO*) param;
  info->state= &info->s->state.state;
  info->append_insert_at_end= 0;
}


void mi_copy_status(void* to,void *from)
{
  ((MI_INFO*) to)->state= &((MI_INFO*) from)->save_state;
+15 −1
Original line number Diff line number Diff line
@@ -322,7 +322,13 @@ MI_INFO *mi_open(const char *name, int mode, uint open_flags)
	for (j=0 ; j < share->keyinfo[i].keysegs; j++,pos++)
	{
	  disk_pos=mi_keyseg_read(disk_pos, pos);

          if (pos->flag & HA_BLOB_PART &&
              ! (share->options & (HA_OPTION_COMPRESS_RECORD |
                                   HA_OPTION_PACK_RECORD)))
          {
            my_errno= HA_ERR_CRASHED;
            goto err;
          }
	  if (pos->type == HA_KEYTYPE_TEXT ||
              pos->type == HA_KEYTYPE_VARTEXT1 ||
              pos->type == HA_KEYTYPE_VARTEXT2)
@@ -440,6 +446,13 @@ MI_INFO *mi_open(const char *name, int mode, uint open_flags)
      offset+=share->rec[i].length;
    }
    share->rec[i].type=(int) FIELD_LAST;	/* End marker */
    if (offset > share->base.reclength)
    {
      /* purecov: begin inspected */
      my_errno= HA_ERR_CRASHED;
      goto err;
      /* purecov: end */
    }

    if (! lock_error)
    {
@@ -504,6 +517,7 @@ MI_INFO *mi_open(const char *name, int mode, uint open_flags)
	share->lock.get_status=mi_get_status;
	share->lock.copy_status=mi_copy_status;
	share->lock.update_status=mi_update_status;
        share->lock.restore_status= mi_restore_status;
	share->lock.check_status=mi_check_status;
      }
    }
Loading