List:Internals« Previous MessageNext Message »
From:ramil Date:September 5 2005 11:41am
Subject:bk commit into 4.1 tree (ramil:1.2408)
View as plain text  
Below is the list of changes that have just been committed into a local
4.1 repository of ram. When ram does a push these changes will
be propagated to the main repository and, within 24 hours after the
push, to the public repository.
For information on how to access the public repository
see http://dev.mysql.com/doc/mysql/en/installing-source-tree.html

ChangeSet
  1.2408 05/09/05 16:41:01 ramil@stripped +2 -0
  Merge rkalimullin@stripped:/home/bk/mysql-4.1
  into  mysql.com:/usr/home/ram/work/4.1.b4214

  myisam/myisampack.c
    1.42 05/09/05 16:40:55 ramil@stripped +0 -0
    Auto merged

  myisam/mi_check.c
    1.149 05/09/05 16:40:55 ramil@stripped +0 -0
    Auto merged

# This is a BitKeeper patch.  What follows are the unified diffs for the
# set of deltas contained in the patch.  The rest of the patch, the part
# that BitKeeper cares about, is below these diffs.
# User:	ramil
# Host:	gw.mysql.r18.ru
# Root:	/usr/home/ram/work/4.1.b4214/RESYNC

--- 1.148/myisam/mi_check.c	2005-08-09 21:29:38 +05:00
+++ 1.149/myisam/mi_check.c	2005-09-05 16:40:55 +05:00
@@ -3193,9 +3193,11 @@
       break;
     case COMPRESSED_RECORD:
       reclength=info->packed_length;
-      length=save_pack_length(block_buff,reclength);
+      length= save_pack_length((uint) share->pack.version, block_buff,
+                               reclength);
       if (info->s->base.blobs)
-	length+=save_pack_length(block_buff+length,info->blob_length);
+	length+= save_pack_length((uint) share->pack.version,
+	                          block_buff + length, info->blob_length);
       if (my_b_write(&info->rec_cache,block_buff,length) ||
 	  my_b_write(&info->rec_cache,(byte*) sort_param->rec_buff,reclength))
       {

--- 1.41/myisam/myisampack.c	2005-08-25 14:08:20 +05:00
+++ 1.42/myisam/myisampack.c	2005-09-05 16:40:55 +05:00
@@ -1675,6 +1675,7 @@
   HUFF_COUNTS *count,*end_count;
   HUFF_TREE *tree;
   MI_INFO *isam_file=mrg->file[0];
+  uint pack_version= (uint) isam_file->s->pack.version;
   DBUG_ENTER("compress_isam_file");
 
   if (!(record=(byte*) my_alloca(isam_file->s->base.reclength)))
@@ -1702,23 +1703,10 @@
 	  huff_counts[i].tree->height+huff_counts[i].length_bits;
   }
   max_calc_length/=8;
-  if (max_calc_length < 254)
-    pack_ref_length=1;
-  else if (max_calc_length <= 65535)
-    pack_ref_length=3;
-  else
-    pack_ref_length=4;
+  pack_ref_length= calc_pack_length(pack_version, max_calc_length);
   record_count=0;
-  pack_blob_length=0;
-  if (isam_file->s->base.blobs)
-  {
-    if (mrg->max_blob_length < 254)
-      pack_blob_length=1;
-    else if (mrg->max_blob_length <= 65535)
-      pack_blob_length=3;
-    else
-      pack_blob_length=4;
-  }
+  pack_blob_length= isam_file->s->base.blobs ?
+                    calc_pack_length(pack_version, mrg->max_blob_length) : 0;
   max_pack_length=pack_ref_length+pack_blob_length;
 
   mrg_reset(mrg);
@@ -1874,9 +1862,10 @@
       }
       flush_bits();
       length=(ulong) (file_buffer.pos-record_pos)-max_pack_length;
-      pack_length=save_pack_length(record_pos,length);
+      pack_length= save_pack_length(pack_version, record_pos, length);
       if (pack_blob_length)
-	pack_length+=save_pack_length(record_pos+pack_length,tot_blob_length);
+	pack_length+= save_pack_length(pack_version, record_pos + pack_length,
+	                               tot_blob_length);
 
       /* Correct file buffer if the header was smaller */
       if (pack_length != max_pack_length)
Thread
bk commit into 4.1 tree (ramil:1.2408)ramil5 Sep