MySQL Lists are EOL. Please join:

List:Commits« Previous MessageNext Message »
From:tim Date:August 24 2006 12:02am
Subject:bk commit into 4.1 tree (tsmith:1.2537) BUG#21531
View as plain text  
Below is the list of changes that have just been committed into a local
4.1 repository of tim. When tim 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@stripped, 2006-08-23 18:02:31-06:00, tsmith@stripped +4 -0
  Bug #21531: EXPORT_SET() doesn't accept args with coercible character sets
  
  - Fix typo in Item_func_export_set::fix_length_and_dec() which caused character set aggregation to fail
  - Remove default argument from last arg of agg_arg_charsets() function, to reduce potential errors

  mysql-test/r/func_misc.result@stripped, 2006-08-23 18:02:28-06:00, tsmith@stripped +4 -0
    Test EXPORT_SET() with charset coersion (bug #21531)

  mysql-test/t/func_misc.test@stripped, 2006-08-23 18:02:28-06:00, tsmith@stripped +6 -1
    Test EXPORT_SET() with charset coersion (bug #21531)

  sql/item_func.h@stripped, 2006-08-23 18:02:28-06:00, tsmith@stripped +1 -2
    Remove default argument from last arg of agg_arg_charsets() function, to reduce potential errors.

  sql/item_strfunc.cc@stripped, 2006-08-23 18:02:28-06:00, tsmith@stripped +2 -2
    Fix typo in Item_func_export_set::fix_length_and_dec() which caused character set aggregation to fail.

# 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:	tsmith
# Host:	siva.hindu.god
# Root:	/usr/home/tim/m/bk/b21531-41

--- 1.129/sql/item_func.h	2006-08-23 18:02:35 -06:00
+++ 1.130/sql/item_func.h	2006-08-23 18:02:35 -06:00
@@ -156,8 +156,7 @@ public:
     return agg_item_collations_for_comparison(c, func_name(),
                                               items, nitems, flags);
   }
-  bool agg_arg_charsets(DTCollation &c, Item **items, uint nitems,
-                        uint flags= 0)
+  bool agg_arg_charsets(DTCollation &c, Item **items, uint nitems, uint flags)
   {
     return agg_item_charsets(c, func_name(), items, nitems, flags);
   }

--- 1.247/sql/item_strfunc.cc	2006-08-23 18:02:35 -06:00
+++ 1.248/sql/item_strfunc.cc	2006-08-23 18:02:35 -06:00
@@ -2624,8 +2624,8 @@ void Item_func_export_set::fix_length_an
   uint sep_length=(arg_count > 3 ? args[3]->max_length : 1);
   max_length=length*64+sep_length*63;
 
-  if (agg_arg_charsets(collation, args+1, min(4,arg_count)-1),
-                       MY_COLL_ALLOW_CONV)
+  if (agg_arg_charsets(collation, args+1, min(4,arg_count)-1,
+                       MY_COLL_ALLOW_CONV))
     return;
 }
 

--- 1.19/mysql-test/r/func_misc.result	2006-08-23 18:02:35 -06:00
+++ 1.20/mysql-test/r/func_misc.result	2006-08-23 18:02:35 -06:00
@@ -93,3 +93,7 @@ SELECT IS_USED_LOCK('bug16501');
 IS_USED_LOCK('bug16501')
 NULL
 DROP TABLE t1;
+select export_set(3, _latin1'foo', _utf8'bar', ',', 4);
+export_set(3, _latin1'foo', _utf8'bar', ',', 4)
+foo,foo,bar,bar
+End of 4.1 tests

--- 1.15/mysql-test/t/func_misc.test	2006-08-23 18:02:35 -06:00
+++ 1.16/mysql-test/t/func_misc.test	2006-08-23 18:02:35 -06:00
@@ -83,4 +83,9 @@ connection default;
 
 DROP TABLE t1;
 
-# End of 4.1 tests
+#
+# Bug #21531: EXPORT_SET() doesn't accept args with coercible character sets
+#
+select export_set(3, _latin1'foo', _utf8'bar', ',', 4);
+
+--echo End of 4.1 tests
Thread
bk commit into 4.1 tree (tsmith:1.2537) BUG#21531tim24 Aug