From 3ca1852cbaac852f778af0e70278cf3a010f4403 Mon Sep 17 00:00:00 2001 From: unknown Date: Tue, 25 Apr 2006 14:34:19 +0500 Subject: [PATCH 1/3] Fix for bug #18501: Server crashes with monthname(). mysql-test/r/func_time.result: Fix for bug #18501: Server crashes with monthname(). - test case mysql-test/t/func_time.test: Fix for bug #18501: Server crashes with monthname(). - test case sql/item_timefunc.cc: Fix for bug #18501: Server crashes with monthname(). - check null_value as well. --- mysql-test/r/func_time.result | 4 ++++ mysql-test/t/func_time.test | 7 +++++++ sql/item_timefunc.cc | 4 ++-- 3 files changed, 13 insertions(+), 2 deletions(-) diff --git a/mysql-test/r/func_time.result b/mysql-test/r/func_time.result index fc872285acb..02f3d2f7273 100644 --- a/mysql-test/r/func_time.result +++ b/mysql-test/r/func_time.result @@ -626,3 +626,7 @@ last_day('2005-01-00') NULL Warnings: Warning 1292 Truncated incorrect datetime value: '2005-01-00' +select monthname(str_to_date(null, '%m')), monthname(str_to_date(null, '%m')), +monthname(str_to_date(1, '%m')), monthname(str_to_date(0, '%m')); +monthname(str_to_date(null, '%m')) monthname(str_to_date(null, '%m')) monthname(str_to_date(1, '%m')) monthname(str_to_date(0, '%m')) +NULL NULL January NULL diff --git a/mysql-test/t/func_time.test b/mysql-test/t/func_time.test index 68a33afd85c..01e4e47d318 100644 --- a/mysql-test/t/func_time.test +++ b/mysql-test/t/func_time.test @@ -315,4 +315,11 @@ select last_day('2005-00-00'); select last_day('2005-00-01'); select last_day('2005-01-00'); +# +# Bug #18501: monthname and NULLs +# + +select monthname(str_to_date(null, '%m')), monthname(str_to_date(null, '%m')), + monthname(str_to_date(1, '%m')), monthname(str_to_date(0, '%m')); + # End of 4.1 tests diff --git a/sql/item_timefunc.cc b/sql/item_timefunc.cc index f3d6858755c..ffd8c79dca8 100644 --- a/sql/item_timefunc.cc +++ b/sql/item_timefunc.cc @@ -905,9 +905,9 @@ String* Item_func_monthname::val_str(String* str) { DBUG_ASSERT(fixed == 1); const char *month_name; - uint month=(uint) Item_func_month::val_int(); + uint month= (uint) val_int(); - if (!month) // This is also true for NULL + if (null_value || !month) { null_value=1; return (String*) 0; From 1bdb7f7789f4c1b02a97210e3818d49f6e064bc2 Mon Sep 17 00:00:00 2001 From: unknown Date: Tue, 9 May 2006 11:55:41 +0200 Subject: [PATCH 2/3] bug #19623 UniqueHashIndexes resource leak: allocate array pool based on MaxNoOfTables --- ndb/src/kernel/blocks/dbtc/DbtcInit.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ndb/src/kernel/blocks/dbtc/DbtcInit.cpp b/ndb/src/kernel/blocks/dbtc/DbtcInit.cpp index f99b4bf15af..2b1f079ea17 100644 --- a/ndb/src/kernel/blocks/dbtc/DbtcInit.cpp +++ b/ndb/src/kernel/blocks/dbtc/DbtcInit.cpp @@ -190,7 +190,7 @@ Dbtc::Dbtc(const class Configuration & conf): ndb_mgm_get_int_parameter(p, CFG_DB_TRANS_BUFFER_MEM, &transactionBufferMemory); - ndb_mgm_get_int_parameter(p, CFG_DB_NO_UNIQUE_HASH_INDEXES, + ndb_mgm_get_int_parameter(p, CFG_DICT_TABLE, &maxNoOfIndexes); ndb_mgm_get_int_parameter(p, CFG_DB_NO_INDEX_OPS, &maxNoOfConcurrentIndexOperations); From bc1815aa3d8a700f28a139a63fdbee684e482f0d Mon Sep 17 00:00:00 2001 From: unknown Date: Wed, 10 May 2006 21:53:01 +0200 Subject: [PATCH 3/3] mysql.spec.sh: Compile in all character sets in Max (bug#14918) support-files/mysql.spec.sh: Compile in all character sets in Max (bug#14918) --- support-files/mysql.spec.sh | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/support-files/mysql.spec.sh b/support-files/mysql.spec.sh index efe42a035e6..737a0d3899d 100644 --- a/support-files/mysql.spec.sh +++ b/support-files/mysql.spec.sh @@ -239,7 +239,6 @@ sh -c "PATH=\"${MYSQL_BUILD_PATH:-$PATH}\" \ --with-mysqld-user=%{mysqld_user} \ --with-unix-socket-path=/var/lib/mysql/mysql.sock \ --prefix=/ \ - --with-extra-charsets=complex \ --exec-prefix=%{_exec_prefix} \ --libexecdir=%{_sbindir} \ --libdir=%{_libdir} \ @@ -297,6 +296,7 @@ then fi BuildMySQL "--enable-shared \ + --with-extra-charsets=all \ --with-berkeley-db \ --with-innodb \ --with-ndbcluster \ @@ -361,6 +361,7 @@ BuildMySQL "--disable-shared \ %else --with-zlib-dir=bundled \ %endif + --with-extra-charsets=complex \ --with-comment=\"MySQL Community Edition - Standard (GPL)\" \ --with-server-suffix='%{server_suffix}' \ --without-embedded-server \ @@ -708,6 +709,12 @@ fi # itself - note that they must be ordered by date (important when # merging BK trees) %changelog +* Wed May 10 2006 Kent Boortz + +- Use character set "all" for the "max", to make Cluster nodes + independent on the character set directory, and the problem that + two RPM sub packages both wants to install this directory. + * Mon May 01 2006 Kent Boortz - Use "./libtool --mode=execute" instead of searching for the