#At file:///home/ram/mysql/mysql-next-mr-bugfixing/ based on revid:magne.mahre@stripped
3361 Ramil Kalimullin 2010-11-04 [merge]
Auto merge from mysql-trunk-bugfixing.
removed:
win/build-nmake-x64.bat
win/build-nmake.bat
win/build-vs71.bat
win/build-vs8.bat
win/build-vs8_x64.bat
win/build-vs9.bat
win/build-vs9_x64.bat
modified:
.bzrignore
mysql-test/r/errors.result
mysql-test/t/errors.test
sql/item.cc
sql/mysqld.cc
sql/rpl_handler.cc
win/README
=== modified file '.bzrignore'
--- a/.bzrignore 2010-08-20 09:15:16 +0000
+++ b/.bzrignore 2010-11-04 13:02:10 +0000
@@ -10,15 +10,19 @@
*.core
*.d
*.da
+*.dll
*.exe
+*.exp
*.gcda
*.gcno
*.gcov
*.idb
+*.ilk
*.la
*.lai
*.lib
*.lo
+*.manifest
*.map
*.o
*.obj
@@ -149,6 +153,7 @@ Makefile
Makefile.in
Makefile.in'
PENDING/*
+scripts/scripts
TAGS
VC++Files/client/mysql_amd64.dsp
ac_available_languages_fragment
@@ -1983,6 +1988,7 @@ sql-bench/test-transactions
sql-bench/test-wisconsin
sql/*.cpp
sql/*.ds?
+sql/*.def
sql/*.vcproj
sql/.deps/client.Po
sql/.deps/derror.Po
@@ -2118,6 +2124,7 @@ sql/.libs/udf_example.lai
sql/.libs/udf_example.so.0
sql/.libs/udf_example.so.0.0.0
sql/client.c
+sql/cmake_dummy.cc
sql/Doxyfile
sql/cscope.out
sql/f.c
@@ -3049,6 +3056,7 @@ vio/viotest.cpp
win/configure.data
win/vs71cache.txt
win/vs8cache.txt
+win/nmake_cache.txt
ylwrap
zlib/*.ds?
zlib/*.vcproj
=== modified file 'mysql-test/r/errors.result'
--- a/mysql-test/r/errors.result 2010-05-27 16:01:43 +0000
+++ b/mysql-test/r/errors.result 2010-11-04 12:36:36 +0000
@@ -134,3 +134,15 @@ INSERT INTO t1 VALUES ('abc\0\0');
INSERT INTO t1 VALUES ('abc\0\0');
ERROR 23000: Duplicate entry 'abc\x00\x00' for key 'PRIMARY'
DROP TABLE t1;
+#
+# Bug#57882: Item_func_conv_charset::val_str(String*):
+# Assertion `fixed == 1' failed
+#
+SELECT (CONVERT('0' USING latin1) IN (CHAR(COT('v') USING utf8),''));
+ERROR 22003: DOUBLE value is out of range in 'cot('v')'
+SET NAMES utf8 COLLATE utf8_latvian_ci ;
+SELECT UPDATEXML(-73 * -2465717823867977728,@@global.auto_increment_increment,null);
+ERROR 22003: BIGINT value is out of range in '(-(73) * -(2465717823867977728))'
+#
+# End Bug#57882
+#
=== modified file 'mysql-test/t/errors.test'
--- a/mysql-test/t/errors.test 2010-05-27 16:01:43 +0000
+++ b/mysql-test/t/errors.test 2010-11-04 12:36:36 +0000
@@ -155,3 +155,19 @@ INSERT INTO t1 VALUES ('abc\0\0');
--error ER_DUP_ENTRY
INSERT INTO t1 VALUES ('abc\0\0');
DROP TABLE t1;
+
+--echo #
+--echo # Bug#57882: Item_func_conv_charset::val_str(String*):
+--echo # Assertion `fixed == 1' failed
+--echo #
+
+--error ER_DATA_OUT_OF_RANGE
+SELECT (CONVERT('0' USING latin1) IN (CHAR(COT('v') USING utf8),''));
+
+SET NAMES utf8 COLLATE utf8_latvian_ci ;
+--error ER_DATA_OUT_OF_RANGE
+SELECT UPDATEXML(-73 * -2465717823867977728,@@global.auto_increment_increment,null);
+
+--echo #
+--echo # End Bug#57882
+--echo #
=== modified file 'sql/item.cc'
--- a/sql/item.cc 2010-10-26 09:10:59 +0000
+++ b/sql/item.cc 2010-11-04 13:02:10 +0000
@@ -1875,11 +1875,12 @@ bool agg_item_set_converter(DTCollation
*arg= conv;
else
thd->change_item_tree(arg, conv);
- /*
- We do not check conv->fixed, because Item_func_conv_charset which can
- be return by safe_charset_converter can't be fixed at creation
- */
- conv->fix_fields(thd, arg);
+
+ if (conv->fix_fields(thd, arg))
+ {
+ res= TRUE;
+ break; // we cannot return here, we need to restore "arena".
+ }
}
if (arena)
thd->restore_active_arena(arena, &backup);
=== modified file 'sql/mysqld.cc'
--- a/sql/mysqld.cc 2010-11-02 11:53:54 +0000
+++ b/sql/mysqld.cc 2010-11-04 13:02:10 +0000
@@ -3938,12 +3938,12 @@ static int init_server_components()
unireg_abort(1);
}
- /* initialize delegates for extension observers */
+ /*
+ initialize delegates for extension observers, errors have already
+ been reported in the function
+ */
if (delegates_init())
- {
- sql_print_error("Initialize extension delegates failed");
unireg_abort(1);
- }
/* need to configure logging before initializing storage engines */
if (opt_log_slave_updates && !opt_bin_log)
=== modified file 'sql/rpl_handler.cc'
--- a/sql/rpl_handler.cc 2010-07-27 14:14:21 +0000
+++ b/sql/rpl_handler.cc 2010-11-04 13:02:10 +0000
@@ -104,12 +104,20 @@ int delegates_init()
transaction_delegate= new (place_trans_mem) Trans_delegate;
if (!transaction_delegate->is_inited())
+ {
+ sql_print_error("Initialization of transaction delegates failed. "
+ "Please report a bug.");
return 1;
+ }
binlog_storage_delegate= new (place_storage_mem) Binlog_storage_delegate;
if (!binlog_storage_delegate->is_inited())
+ {
+ sql_print_error("Initialization binlog storage delegates failed. "
+ "Please report a bug.");
return 1;
+ }
#ifdef HAVE_REPLICATION
void *place_transmit_mem= transmit_mem.data;
@@ -118,16 +126,29 @@ int delegates_init()
binlog_transmit_delegate= new (place_transmit_mem) Binlog_transmit_delegate;
if (!binlog_transmit_delegate->is_inited())
+ {
+ sql_print_error("Initialization of binlog transmit delegates failed. "
+ "Please report a bug.");
return 1;
+ }
binlog_relay_io_delegate= new (place_relay_io_mem) Binlog_relay_IO_delegate;
if (!binlog_relay_io_delegate->is_inited())
+ {
+ sql_print_error("Initialization binlog relay IO delegates failed. "
+ "Please report a bug.");
return 1;
+ }
#endif
if (pthread_key_create(&RPL_TRANS_BINLOG_INFO, NULL))
+ {
+ sql_print_error("Error while creating pthread specific data key for replication. "
+ "Please report a bug.");
return 1;
+ }
+
return 0;
}
=== modified file 'win/README'
--- a/win/README 2009-03-06 18:25:38 +0000
+++ b/win/README 2010-11-04 10:11:43 +0000
@@ -10,7 +10,8 @@ or ealier.
The Windows build system uses a tool named CMake to generate build files for
a variety of project systems. This tool is combined with a set of jscript
-files to enable building of MySQL for Windows directly out of a bk clone.
+files to enable building of MySQL for Windows directly out of a bzr clone.
+For relevant information, please refer to http://forge.mysql.com/wiki/CMake
The steps required are below.
Step 1:
@@ -41,56 +42,67 @@ before you start the build)
Step 4
------
-Clone your bk tree to any location you like.
+One of the nice CMake features is "out-of-source" build support, which
+means not building in the source directory, but in dedicated build
+directory. This keeps the source directory clean and allows for more than
+single build tree for the same source tree (e.g debug and release, 32 and
+64 bit etc). We'll create subdirectory "bld" in the source directory for
+this purpose. Clone your bzr tree to any location you like.
Step 5
------
-From the root of your installation directory, execute the command:
+From the root of your installation directory use cmake . -L to see the
+various configuration parameters.
-win\configure <options>
-
-The options right now are:
-
- WITH_INNOBASE_STORAGE_ENGINE Enable particular storage engines
- WITH_PARTITION_STORAGE_ENGINE
- WITH_ARCHIVE_STORAGE_ENGINE
- WITH_BLACKHOLE_STORAGE_ENGINE
- WITH_EXAMPLE_STORAGE_ENGINE
- WITH_FEDERATED_STORAGE_ENGINE
- __NT__ Enable named pipe support
- WITHOUT_ATOMICS Do not use atomic instructions
- MYSQL_SERVER_SUFFIX=<suffix> Server suffix, default none
- COMPILATION_COMMENT=<comment> Server comment, default "Source distribution"
- MYSQL_TCP_PORT=<port> Server port, default 3306
- CYBOZU Default character set is UTF8
- EMBED_MANIFESTS Embed custom manifests into final exes, otherwise VS
- default will be used. (Note - This option should only be
- used by MySQL AB.)
- WITH_EMBEDDED_SERVER Configure solution to produce libmysqld.dll
- and the static mysqlserver.lib
-
So the command line could look like:
-win\configure WITH_INNOBASE_STORAGE_ENGINE WITH_PARTITION_STORAGE_ENGINE MYSQL_SERVER_SUFFIX=-pro
+cmake .. -G "target" -DWITH_INNOBASE_STORAGE_ENGINE=1
+
+The recommended way of configuring would be to use -DBUILD_CONFIG=mysql_release
+to build binaries exactly the same as the official MySQL releases.
Step 6
------
-From the root of your installation directory/bk clone, execute one of
-the batch files to generate the type of project files you desire.
-
-For Visual Studio 8 (or Visual C++ 2005 express edition), do win\build-vs8.
-For Visual Studio 7.1, do win\build-vs71.
-
-We will support building with nmake in the near future.
-
+From the root of your installation directory/bzr clone, you can
+use cmake to compile the sources. Use cmake --help when necessary.
+Before you start building the sources, please remove the old build area
+created from an earlier run and start afresh.
+
+C:\> del bld
+C:\> md bld
+C:\> cd bld
+C:\> cmake .. -G "target name" -DBUILD_CONFIG=mysql_release
+
+
+For Example:
+To generate the Win64 project files using Visual Studio 9, you would run
+cmake .. -G "Visual Studio 9 2008 Win64"
+
+Other target names supported using CMake 2.6 patch 4 are:
+
+ Visual Studio 7 "Visual Studio 7 .NET 2003"
+ Visual Studio 8 "Visual Studio 8 2005"
+ Visual Studio 8 (64 bit) "Visual Studio 8 2005 Win64"
+ Visual Studio 9 "Visual Studio 9 2008"
+ Visual Studio 9 (64 bit) "Visual Studio 9 2008 Win64"
+
+For generating project files using Visual Studio 10, you need CMake 2.8
+or higher and corresponding target names are
+ Visual Studio 10 "Visual Studio 10"
+ Visual Studio 10 (64 bit) "Visual Studio 10 Win64"
+
Step 7
------
-From the root of your bk clone, start your build.
+From the root of your bzr clone, start your build.
For Visual Studio, execute mysql.sln. This will start the IDE
and you can click the build solution menu option.
+Alternatively, you could start the build from command line as follows
+
+devenv mysql.sln /build relwithdebinfo
+
Current issues
--------------
1. After changing configuration (eg. adding or removing a storage engine), it
=== removed file 'win/build-nmake-x64.bat'
--- a/win/build-nmake-x64.bat 2007-09-05 21:30:38 +0000
+++ b/win/build-nmake-x64.bat 1970-01-01 00:00:00 +0000
@@ -1,21 +0,0 @@
-@echo off
-
-REM Copyright (C) 2006 MySQL AB
-REM
-REM This program is free software; you can redistribute it and/or modify
-REM it under the terms of the GNU General Public License as published by
-REM the Free Software Foundation; version 2 of the License.
-REM
-REM This program is distributed in the hope that it will be useful,
-REM but WITHOUT ANY WARRANTY; without even the implied warranty of
-REM MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-REM GNU General Public License for more details.
-REM
-REM You should have received a copy of the GNU General Public License
-REM along with this program; if not, write to the Free Software
-REM Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
-
-if exist cmakecache.txt del cmakecache.txt
-copy win\nmake_x64_cache.txt cmakecache.txt
-cmake -G "NMake Makefiles"
-copy cmakecache.txt win\nmake_x64_cache.txt
=== removed file 'win/build-nmake.bat'
--- a/win/build-nmake.bat 2007-09-05 21:30:38 +0000
+++ b/win/build-nmake.bat 1970-01-01 00:00:00 +0000
@@ -1,21 +0,0 @@
-@echo off
-
-REM Copyright (C) 2006 MySQL AB
-REM
-REM This program is free software; you can redistribute it and/or modify
-REM it under the terms of the GNU General Public License as published by
-REM the Free Software Foundation; version 2 of the License.
-REM
-REM This program is distributed in the hope that it will be useful,
-REM but WITHOUT ANY WARRANTY; without even the implied warranty of
-REM MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-REM GNU General Public License for more details.
-REM
-REM You should have received a copy of the GNU General Public License
-REM along with this program; if not, write to the Free Software
-REM Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
-
-if exist cmakecache.txt del cmakecache.txt
-copy win\nmake_cache.txt cmakecache.txt
-cmake -G "NMake Makefiles"
-copy cmakecache.txt win\nmake_cache.txt
=== removed file 'win/build-vs71.bat'
--- a/win/build-vs71.bat 2007-03-20 14:42:34 +0000
+++ b/win/build-vs71.bat 1970-01-01 00:00:00 +0000
@@ -1,22 +0,0 @@
-@echo off
-
-REM Copyright (C) 2006 MySQL AB
-REM
-REM This program is free software; you can redistribute it and/or modify
-REM it under the terms of the GNU General Public License as published by
-REM the Free Software Foundation; version 2 of the License.
-REM
-REM This program is distributed in the hope that it will be useful,
-REM but WITHOUT ANY WARRANTY; without even the implied warranty of
-REM MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-REM GNU General Public License for more details.
-REM
-REM You should have received a copy of the GNU General Public License
-REM along with this program; if not, write to the Free Software
-REM Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
-
-if exist cmakecache.txt del cmakecache.txt
-copy win\vs71cache.txt cmakecache.txt
-cmake -G "Visual Studio 7 .NET 2003"
-copy cmakecache.txt win\vs71cache.txt
-
=== removed file 'win/build-vs8.bat'
--- a/win/build-vs8.bat 2007-03-20 14:42:34 +0000
+++ b/win/build-vs8.bat 1970-01-01 00:00:00 +0000
@@ -1,21 +0,0 @@
-@echo off
-
-REM Copyright (C) 2006 MySQL AB
-REM
-REM This program is free software; you can redistribute it and/or modify
-REM it under the terms of the GNU General Public License as published by
-REM the Free Software Foundation; version 2 of the License.
-REM
-REM This program is distributed in the hope that it will be useful,
-REM but WITHOUT ANY WARRANTY; without even the implied warranty of
-REM MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-REM GNU General Public License for more details.
-REM
-REM You should have received a copy of the GNU General Public License
-REM along with this program; if not, write to the Free Software
-REM Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
-
-if exist cmakecache.txt del cmakecache.txt
-copy win\vs8cache.txt cmakecache.txt
-cmake -G "Visual Studio 8 2005"
-copy cmakecache.txt win\vs8cache.txt
=== removed file 'win/build-vs8_x64.bat'
--- a/win/build-vs8_x64.bat 2006-12-31 00:02:27 +0000
+++ b/win/build-vs8_x64.bat 1970-01-01 00:00:00 +0000
@@ -1,21 +0,0 @@
-@echo off
-
-REM Copyright (C) 2006 MySQL AB
-REM
-REM This program is free software; you can redistribute it and/or modify
-REM it under the terms of the GNU General Public License as published by
-REM the Free Software Foundation; version 2 of the License.
-REM
-REM This program is distributed in the hope that it will be useful,
-REM but WITHOUT ANY WARRANTY; without even the implied warranty of
-REM MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-REM GNU General Public License for more details.
-REM
-REM You should have received a copy of the GNU General Public License
-REM along with this program; if not, write to the Free Software
-REM Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
-
-if exist cmakecache.txt del cmakecache.txt
-copy win\vs8cache.txt cmakecache.txt
-cmake -G "Visual Studio 8 2005 Win64"
-copy cmakecache.txt win\vs8cache.txt
=== removed file 'win/build-vs9.bat'
--- a/win/build-vs9.bat 2008-08-21 17:11:17 +0000
+++ b/win/build-vs9.bat 1970-01-01 00:00:00 +0000
@@ -1,18 +0,0 @@
-@echo off
-
-REM Copyright (C) 2006 MySQL AB
-REM
-REM This program is free software; you can redistribute it and/or modify
-REM it under the terms of the GNU General Public License as published by
-REM the Free Software Foundation; version 2 of the License.
-REM
-REM This program is distributed in the hope that it will be useful,
-REM but WITHOUT ANY WARRANTY; without even the implied warranty of
-REM MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-REM GNU General Public License for more details.
-REM
-REM You should have received a copy of the GNU General Public License
-REM along with this program; if not, write to the Free Software
-REM Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
-cmake -G "Visual Studio 9 2008"
-
=== removed file 'win/build-vs9_x64.bat'
--- a/win/build-vs9_x64.bat 2008-08-21 17:11:17 +0000
+++ b/win/build-vs9_x64.bat 1970-01-01 00:00:00 +0000
@@ -1,18 +0,0 @@
-@echo off
-
-REM Copyright (C) 2006 MySQL AB
-REM
-REM This program is free software; you can redistribute it and/or modify
-REM it under the terms of the GNU General Public License as published by
-REM the Free Software Foundation; version 2 of the License.
-REM
-REM This program is distributed in the hope that it will be useful,
-REM but WITHOUT ANY WARRANTY; without even the implied warranty of
-REM MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-REM GNU General Public License for more details.
-REM
-REM You should have received a copy of the GNU General Public License
-REM along with this program; if not, write to the Free Software
-REM Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
-cmake -G "Visual Studio 9 2008 Win64"
-
No bundle (reason: revision is a merge).
| Thread |
|---|
| • bzr commit into mysql-next-mr-bugfixing branch (ramil:3361) | Ramil Kalimullin | 4 Nov |