List:Commits« Previous MessageNext Message »
From:eugene Date:June 20 2006 9:14pm
Subject:bk commit into 5.0 tree (evgen:1.2195)
View as plain text  
Below is the list of changes that have just been committed into a local
5.0 repository of evgen. When evgen 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.2195 06/06/21 01:14:53 evgen@stripped +5 -0
  field.cc, field.h:
    Additional fix for #16377 for bigendian platforms
  sql_select.cc, select.result, select.test:
    After merge fix

  sql/field.cc
    1.311 06/06/21 01:06:52 evgen@stripped +22 -22
    Additional fix for #16377 for bigendian platforms

  sql/field.h
    1.182 06/06/21 01:05:31 evgen@stripped +1 -1
    Additional fix for #16377 for bigendian platforms

  sql/sql_select.cc
    1.424 06/06/21 01:04:55 evgen@stripped +1 -1
    After merge fix

  mysql-test/r/select.result
    1.130 06/06/21 01:04:31 evgen@stripped +6 -6
    After merge fix

  mysql-test/t/select.test
    1.106 06/06/21 01:04:14 evgen@stripped +1 -1
    After merge fix

# 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:	evgen
# Host:	moonbone.local
# Root:	/work/tmp_merge-5.0-opt-mysql

--- 1.310/sql/field.cc	2006-06-16 05:39:14 +04:00
+++ 1.311/sql/field.cc	2006-06-21 01:06:52 +04:00
@@ -4566,7 +4566,7 @@
   }
 
 #ifdef WORDS_BIGENDIAN
-  if (table->s->db_low_byte_first)
+  if (table && table->s->db_low_byte_first)
   {
     int4store(ptr,tmp);
   }
@@ -4632,7 +4632,7 @@
                          nr, MYSQL_TIMESTAMP_DATETIME, 1);
 
 #ifdef WORDS_BIGENDIAN
-  if (table->s->db_low_byte_first)
+  if (table && table->s->db_low_byte_first)
   {
     int4store(ptr,timestamp);
   }
@@ -4656,7 +4656,7 @@
   THD  *thd= table ? table->in_use : current_thd;
 
 #ifdef WORDS_BIGENDIAN
-  if (table->s->db_low_byte_first)
+  if (table && table->s->db_low_byte_first)
     temp=uint4korr(ptr);
   else
 #endif
@@ -4686,7 +4686,7 @@
   val_buffer->length(field_length);
 
 #ifdef WORDS_BIGENDIAN
-  if (table->s->db_low_byte_first)
+  if (table && table->s->db_low_byte_first)
     temp=uint4korr(ptr);
   else
 #endif
@@ -4751,7 +4751,7 @@
   long temp;
   THD *thd= table ? table->in_use : current_thd;
 #ifdef WORDS_BIGENDIAN
-  if (table->s->db_low_byte_first)
+  if (table && table->s->db_low_byte_first)
     temp=uint4korr(ptr);
   else
 #endif
@@ -4788,7 +4788,7 @@
 {
   int32 a,b;
 #ifdef WORDS_BIGENDIAN
-  if (table->s->db_low_byte_first)
+  if (table && table->s->db_low_byte_first)
   {
     a=sint4korr(a_ptr);
     b=sint4korr(b_ptr);
@@ -4806,7 +4806,7 @@
 void Field_timestamp::sort_string(char *to,uint length __attribute__((unused)))
 {
 #ifdef WORDS_BIGENDIAN
-  if (!table->s->db_low_byte_first)
+  if (!table || !table->s->db_low_byte_first)
   {
     to[0] = ptr[0];
     to[1] = ptr[1];
@@ -4836,7 +4836,7 @@
   long tmp= (long) thd->query_start();
   set_notnull();
 #ifdef WORDS_BIGENDIAN
-  if (table->s->db_low_byte_first)
+  if (table && table->s->db_low_byte_first)
   {
     int4store(ptr,tmp);
   }
@@ -5238,7 +5238,7 @@
                          from, len, MYSQL_TIMESTAMP_DATE, 1);
 
 #ifdef WORDS_BIGENDIAN
-  if (table->s->db_low_byte_first)
+  if (table && table->s->db_low_byte_first)
   {
     int4store(ptr,tmp);
   }
@@ -5299,7 +5299,7 @@
                          MYSQL_TIMESTAMP_DATETIME, 1);
 
 #ifdef WORDS_BIGENDIAN
-  if (table->s->db_low_byte_first)
+  if (table && table->s->db_low_byte_first)
   {
     int4store(ptr, nr);
   }
@@ -5325,7 +5325,7 @@
 {
   int32 j;
 #ifdef WORDS_BIGENDIAN
-  if (table->s->db_low_byte_first)
+  if (table && table->s->db_low_byte_first)
     j=sint4korr(ptr);
   else
 #endif
@@ -5338,7 +5338,7 @@
 {
   int32 j;
 #ifdef WORDS_BIGENDIAN
-  if (table->s->db_low_byte_first)
+  if (table && table->s->db_low_byte_first)
     j=sint4korr(ptr);
   else
 #endif
@@ -5354,7 +5354,7 @@
   val_buffer->alloc(field_length);
   int32 tmp;
 #ifdef WORDS_BIGENDIAN
-  if (table->s->db_low_byte_first)
+  if (table && table->s->db_low_byte_first)
     tmp=sint4korr(ptr);
   else
 #endif
@@ -5372,7 +5372,7 @@
 {
   int32 a,b;
 #ifdef WORDS_BIGENDIAN
-  if (table->s->db_low_byte_first)
+  if (table && table->s->db_low_byte_first)
   {
     a=sint4korr(a_ptr);
     b=sint4korr(b_ptr);
@@ -5390,7 +5390,7 @@
 void Field_date::sort_string(char *to,uint length __attribute__((unused)))
 {
 #ifdef WORDS_BIGENDIAN
-  if (!table->s->db_low_byte_first)
+  if (!table || !table->s->db_low_byte_first)
   {
     to[0] = ptr[0];
     to[1] = ptr[1];
@@ -5630,7 +5630,7 @@
                          from, len, MYSQL_TIMESTAMP_DATETIME, 1);
 
 #ifdef WORDS_BIGENDIAN
-  if (table->s->db_low_byte_first)
+  if (table && table->s->db_low_byte_first)
   {
     int8store(ptr,tmp);
   }
@@ -5683,7 +5683,7 @@
                          MYSQL_TIMESTAMP_DATETIME, 1);
 
 #ifdef WORDS_BIGENDIAN
-  if (table->s->db_low_byte_first)
+  if (table && table->s->db_low_byte_first)
   {
     int8store(ptr,nr);
   }
@@ -5712,7 +5712,7 @@
     set_warning(MYSQL_ERROR::WARN_LEVEL_WARN, WARN_DATA_TRUNCATED, 1);
   }
 #ifdef WORDS_BIGENDIAN
-  if (table->s->db_low_byte_first)
+  if (table && table->s->db_low_byte_first)
   {
     int8store(ptr,tmp);
   }
@@ -5739,7 +5739,7 @@
 {
   longlong j;
 #ifdef WORDS_BIGENDIAN
-  if (table->s->db_low_byte_first)
+  if (table && table->s->db_low_byte_first)
     j=sint8korr(ptr);
   else
 #endif
@@ -5759,7 +5759,7 @@
   int part3;
 
 #ifdef WORDS_BIGENDIAN
-  if (table->s->db_low_byte_first)
+  if (table && table->s->db_low_byte_first)
     tmp=sint8korr(ptr);
   else
 #endif
@@ -5824,7 +5824,7 @@
 {
   longlong a,b;
 #ifdef WORDS_BIGENDIAN
-  if (table->s->db_low_byte_first)
+  if (table && table->s->db_low_byte_first)
   {
     a=sint8korr(a_ptr);
     b=sint8korr(b_ptr);
@@ -5842,7 +5842,7 @@
 void Field_datetime::sort_string(char *to,uint length __attribute__((unused)))
 {
 #ifdef WORDS_BIGENDIAN
-  if (!table->s->db_low_byte_first)
+  if (!table || !table->s->db_low_byte_first)
   {
     to[0] = ptr[0];
     to[1] = ptr[1];

--- 1.181/sql/field.h	2006-06-14 16:57:17 +04:00
+++ 1.182/sql/field.h	2006-06-21 01:05:31 +04:00
@@ -813,7 +813,7 @@
     if ((*null_value= is_null()))
       return 0;
 #ifdef WORDS_BIGENDIAN
-    if (table->s->db_low_byte_first)
+    if (table && table->s->db_low_byte_first)
       return sint4korr(ptr);
 #endif
     long tmp;

--- 1.423/sql/sql_select.cc	2006-06-20 22:22:12 +04:00
+++ 1.424/sql/sql_select.cc	2006-06-21 01:04:55 +04:00
@@ -8817,7 +8817,7 @@
   }
   else
   {
-    set_if_smaller(table->max_rows, rows_limit);
+    set_if_smaller(table->s->max_rows, rows_limit);
     param->end_write_records= rows_limit;
   }
 

--- 1.129/mysql-test/r/select.result	2006-06-20 23:22:48 +04:00
+++ 1.130/mysql-test/r/select.result	2006-06-21 01:04:31 +04:00
@@ -2730,6 +2730,12 @@
 EXPLAIN SELECT * FROM t1 FORCE INDEX (a);
 ERROR HY000: Key 'a' doesn't exist in table 't1'
 DROP TABLE t1;
+CREATE TABLE t1 (i BIGINT UNSIGNED NOT NULL);
+INSERT INTO t1 VALUES (10);
+SELECT i='1e+01',i=1e+01, i in (1e+01,1e+01), i in ('1e+01','1e+01') FROM t1;
+i='1e+01'	i=1e+01	i in (1e+01,1e+01)	i in ('1e+01','1e+01')
+0	1	1	1
+DROP TABLE t1;
 CREATE TABLE t1 ( 
 K2C4 varchar(4) character set latin1 collate latin1_bin NOT NULL default '', 
 K4N4 varchar(4) character set latin1 collate latin1_bin NOT NULL default '0000', 
@@ -3389,9 +3395,3 @@
 1	0	1	1	0	1	NULL
 2	0	1	NULL	NULL	NULL	NULL
 drop table t1,t2;
-CREATE TABLE t1 (i BIGINT UNSIGNED NOT NULL);
-INSERT INTO t1 VALUES (10);
-SELECT i='1e+01',i=1e+01, i in (1e+01), i in ('1e+01') FROM t1;
-i='1e+01'	i=1e+01	i in (1e+01)	i in ('1e+01')
-0	1	1	1
-DROP TABLE t1;

--- 1.105/mysql-test/t/select.test	2006-06-20 23:11:15 +04:00
+++ 1.106/mysql-test/t/select.test	2006-06-21 01:04:14 +04:00
@@ -2301,7 +2301,7 @@
 #
 CREATE TABLE t1 (i BIGINT UNSIGNED NOT NULL);
 INSERT INTO t1 VALUES (10);
-SELECT i='1e+01',i=1e+01, i in (1e+01), i in ('1e+01') FROM t1;
+SELECT i='1e+01',i=1e+01, i in (1e+01,1e+01), i in ('1e+01','1e+01') FROM t1;
 DROP TABLE t1;
 
 # End of 4.1 tests
Thread
bk commit into 5.0 tree (evgen:1.2195)eugene20 Jun