Commit graph

3256 commits

Author SHA1 Message Date
Alexander Nozdrin
eca91c6f55 Automerge from mysql-next-mr. 2009-10-23 00:24:32 +04:00
Alexander Nozdrin
cec638b590 Automerge from mysql-next-mr. 2009-10-22 22:06:01 +04:00
Bjorn Munch
23e557d48a new merge from next-mr 2009-10-22 09:36:39 +02:00
Alexander Barkov
344ddc85fa Merging mysql-next-mr-merge to mysql-next-mr. 2009-10-21 15:48:22 +05:00
Bjorn Munch
b738a5e57e merge from next-mr 2009-10-21 12:18:33 +02:00
Alexander Nozdrin
3fd2f50b6c Merge from mysql-trunk-merge. 2009-10-19 17:36:19 +04:00
Bjorn Munch
423dacf3c6 merge from next-mr 2009-10-18 10:08:07 +02:00
Sergey Glukhov
7741d9b50d WL#751 Error message construction, backport 2009-10-15 17:23:43 +05:00
Georgi Kodinov
9449be5868 merge 2009-10-14 17:36:11 +03:00
Alexander Nozdrin
ca08f10ccd Manual merge from mysql-trunk-merge. 2009-10-14 12:25:39 +04:00
Alexander Nozdrin
a9f2b3484a Backporting of Bug#40128 from 6.0 to next-mr.
Original revision in 6.0:
------------------------------------------------------------
revno: 2599.108.1
committer: Alexander Nozdrin <alik@sun.com>
branch nick: 6.0-rpl-bug40128
timestamp: Wed 2009-01-21 15:33:42 +0300
message:
  Fix for Bug#40128: drop-no_root fails under windows in 6.0-rpl.
  
  The problem was that directories with no permission (000) files
  are deleted differently on UNIX and on Windows.
  
  On UNIX, 000-permission file is deleted perfectly, but other files
  are left in the directory.
  
  On Windows, 000-permission file is not deleted, but other files
  are deleted.
  
  Also, the fix needed a change in mysqltest.c: 'chmod' directive
  should return a positive error code (in order to be handled).
  It's decided to return a constant '1' for all error codes
  just to be OS-independent.
------------------------------------------------------------
2009-10-09 18:52:49 +04:00
Alexander Nozdrin
0845f51f4f Pull from mysql-next-mr. 2009-10-09 13:50:49 +04:00
Kent Boortz
60132409f8 "MySQL Network" => "MySQL Enterprise" 2009-10-08 22:55:28 +02:00
Frazer Clement
5f8cfacf6c Merge 5.0-bugteam-> 5.1-bugteam 2009-10-08 16:36:36 +01:00
Frazer Clement
844eb557e6 Fix compile break from bug#39663 fix 2009-10-08 16:23:15 +01:00
Bjorn Munch
79a1ba30e1 merge from mtr-51 2009-10-08 11:34:42 +02:00
Bjorn Munch
9a3d3f4724 Bug #47218 mysqltest ignores "error" command inside if inside loop
This was affected by same problem as append_file etc.
Added Q_ERROR to special handling, and added small test
2009-10-08 11:30:03 +02:00
Alexander Nozdrin
f4d27e81bb Merge from mysql-next-mr. 2009-10-08 11:42:38 +04:00
Alexander Nozdrin
83177656d9 A backport of a patch for Bug#35297.
Original revision in mysql-6.0-codebase is:

revno: 2617.31.14
committer: Konstantin Osipov <kostja@sun.com>
branch nick: mysql-6.0-runtime
timestamp: Sat 2009-03-28 11:42:55 +0300
message:
  Bug#35297 SHOW CREATE EVENT does not show the DEFINER:
  update test result after a merge from now.
2009-10-08 00:57:03 +04:00
Frazer Clement
bbda071ed5 Merge 5.0-bugteam->5.1 bugteam 2009-10-05 13:57:59 +01:00
Frazer Clement
166d08c7eb Bug#39663 mysqltest: --enable_info, affected_rows and ps-protocol broken 2009-10-05 13:57:00 +01:00
Georgi Kodinov
db35fb7961 automerge 2009-10-04 12:15:05 +03:00
Joerg Bruehe
de0285a2e5 Merge "trunk-build" up into "next-mr". 2009-09-30 22:31:22 +02:00
Vladislav Vaintroub
2801599323 Backport http://lists.mysql.com/commits/57778
2677 Vladislav Vaintroub	2008-11-04
CMakeLists.txt files cleanup
- remove SAFEMALLOC and SAFE_MUTEX definitions that were 
present in *each* CMakeLists.txt. Instead, put them into top level 
CMakeLists.txt, but disable on Windows, because
a) SAFEMALLOC does not add any functionality that is not already
present in Debug C runtime ( and 2 safe malloc one on top of the other 
only unnecessarily slows down the server) 
      
b)SAFE_MUTEX does not work on Windows  and have been
explicitely  disabled on Windows with #undef previously.  Fortunately,
ntdll does  pretty good  job identifying l problems with 
CRITICAL_SECTIONs.
DebugBreak()s on using uninited critical section, unlocking unowned 
critical section)
      
-Also, remove occationally used -D_DEBUG (added by compiler 
anyway)
2009-09-30 15:35:01 +02:00
Guilhem Bichot
b3886f46da Fix for BUG#42980 "Client doesn't set NUM_FLAG for DECIMAL and TIMESTAMP":
DECIMAL and TIMESTAMP used to have NUM_FLAG, but NEWDECIMAL was forgotten.
It's correct that TIMESTAMP does not have the flag nowadays (manual will be updated, connectors
developers will be notified).
2009-09-30 12:25:50 +02:00
f4b6aeaf5b Bug #46998 mysqlbinlog can't output BEGIN even if the database is included in a transaction
The 'BEGIN/COMMIT/ROLLBACK' log event could be filtered out if the
database is not selected by --database option of mysqlbinlog command.
This can result in problem if there are some statements in the
transaction are not filtered out.

To fix the problem, mysqlbinlog will output 'BEGIN/ROLLBACK/COMMIT' 
in regardless of the database filtering rules.
2009-09-30 10:31:25 +08:00
869c011218 Bug #46998 mysqlbinlog can't output BEGIN even if the database is included in a transaction
The 'BEGIN/COMMIT/ROLLBACK' log event could be filtered out if the
database is not selected by --database option of mysqlbinlog command.
This can result in problem if there are some statements in the
transaction are not filtered out.

To fix the problem, mysqlbinlog will output 'BEGIN/ROLLBACK/COMMIT' 
in regardless of the database filtering rules.
2009-09-30 10:01:52 +08:00
Vladislav Vaintroub
46d04ebdef Backport of the patch
http://lists.mysql.com/commits/57725

Vladislav Vaintroub	2008-11-03
Cleanup CMakeLists.txt(s) - remove winsock2 (ws2_32) from 
TARGET_LINK_LIBRARIES. 
      
Every exe or dll linked with mysys needs ws2_32, because
mysys uses winsock function WSAStartup in my_init().
However, there is no need to explicitely add ws2_32 to
the list of TARGET_LINK_LIBRARIES multiple times. 
Visual Studio comes with a handy pragma that tells linker
to add library. So patch replaces bunch of ws2_32 in 
CMakeLists with  single pragma comment(lib,"ws2_32")
in my_init.c
      
Additionally, reference to non-existing "debug" library
has been removed from TARGET_LINK_LIBRARIES. The correct
name of the library is "dbug".
2009-09-30 03:39:37 +02:00
Vladislav Vaintroub
e6090f10bb Windows improvements : manual backport of
htttp://lists.mysql.com/commits/50957?f=plain
      
Always use TLS functions instead of __declspec(thread) to access 
thread local storage variables.
The change removes the necessity to recomplile the same source
files twice -  with USE_TLS for DLLs and without USE_TLS for EXEs.
Real benefit of this change is better readability and maintainability
of TLS functions within MySQL.
              
There is a performance loss using TlsXXX functions compared to __declspec 
but the difference is negligible in practice. In a sysbench-like benchmark 
I ran with with TlsGetValue, pthread_[get|set]_specific was called 600000000 
times and took 0.17sec of total 35min CPU time, or 0.008%.
2009-09-30 03:22:57 +02:00
Joerg Bruehe
650e68b7dc Merge 5.1-build up into 5.4-build ("trunk-build"). 2009-09-28 11:39:36 +02:00
Joerg Bruehe
1d9c5686c3 Upmerge 5.0-build -> 5.1-build. 2009-09-28 11:07:31 +02:00
90d4b21d1d BUG#43579 mysql_upgrade tries to alter log tables on replicated database
All statements executed by mysql_upgrade are binlogged and then are replicated to slave.
This will result in some errors. The report of this bug has demonstrated some examples.

Master and slave should be upgraded separately. All statements executed by
mysql_upgrade will not be binlogged. 
--write-binlog and --skip-write-binlog options are added into mysql_upgrade. 
These options control whether sql statements are binlogged or not.
2009-09-28 14:24:19 +08:00
Vladislav Vaintroub
47fedb97b4 merge 2009-09-23 22:15:22 +02:00
Staale Smedseng
8b9843408d Bug #43414 Parenthesis (and other) warnings compiling MySQL
with gcc 4.3.2

Cleaning up warnings not present in 5.0.
2009-09-23 15:21:29 +02:00
Georgi Kodinov
bafc15748b automerge 2009-09-23 11:31:18 +03:00
Bjorn Munch
9d9ee64637 new merge from trunk 2009-09-18 16:44:11 +02:00
Georgi Kodinov
5d68d4a534 automerge 2009-09-18 16:35:40 +03:00
Magnus Blåudd
f66231be11 Merge bug#42850 to 5.0 2009-09-28 14:40:20 +02:00
Joerg Bruehe
67bcf54df6 Fix bug#46980
Option "--without-server" still not working in 5.1

The general approach is to make sure that source files
which require thread support are only compiled if the build
really needs thread support,
which means when the server is built or a thread-safe client
library.

This required several changes:
- Make sure the subdirectories "storage/" and "plugin/" are
  only processed if the server is built, not ifclient-only.
- Make the compilation of some modules which inherently
  require threading depend on thread supportin the build.
- Separate the handling of threading in "configure.in" from
  that of server issues, threading is also needed in a
  non-server build of a thread-safe client library.

Also, "libdbug" must get built even in a client-only build,
so "dbug/" must be in the list of client directories.

In addition, calls to thread functions in source files which
can be built without thread support must use the wrapper
functions which handle the non-threaded build.
So the modules "client/mysqlimport.c" and "client/mysqlslap.c"
must call "my_thread_end()" only via "mysql_thread_end()".
2009-09-17 18:34:24 +02:00
Vladislav Vaintroub
4e92af9f43 This is the downport of
Bug#24509 - 2048 file descriptor limit on windows needs increasing, also 
WL#3049 - improved Windows I/O
                        
The patch replaces the use of the POSIX I/O interfaces in mysys on Windows with 
the Win32 API calls (CreateFile, WriteFile, etc). The Windows HANDLE for the open 
file is stored in the my_file_info struct, along with a flag for append mode 
because the Windows API does not support opening files in append mode in all cases)
The default max open files has been increased to 16384 and can be increased further
by setting --max-open-files=<value> during the server start.
                              
Another major change in this patch that almost all Windows specific file IO code
has been moved to a new file my_winfile.c, greatly reducing the amount of code 
in #ifdef blocks within mysys, thus improving readability.
                               
                                    
Minor enhancements:
- my_(f)stat() is changed to use __stati64 structure with  64 file size
and timestamps. It will return correct file size now (C runtime implementation
used to report outdated information)
- my_lock on Windows is prepared to handle additional timeout parameter
- after review : changed __WIN__ to _WIN32 in the new and changed code.
2009-09-11 22:26:35 +02:00
Alexander Nozdrin
96c8843514 A patch for Bug#45118 (mysqld.exe crashed in debug mode
on Windows in dbug.c) -- part 2: a patch for the DBUG subsystem
to detect misuse of DBUG_ENTER / DBUG_RETURN macros.
5.1 version.
2009-09-10 11:40:57 +04:00
hery
c07381bae2 change c++ comment to c comment 2009-09-09 20:52:17 +02:00
Bjorn Munch
b5dd609a55 initial merge from 5.1-mtr 2009-09-04 15:20:58 +02:00
Satya B
81053daf97 Addition to Fix for BUG#46591 - .frm file isn't sync'd with sync_frm enabled
for CREATE TABLE...LIKE...

Add my_sync.c to mysqltest sources list in CMakeLists.txt
2009-09-04 11:19:44 +05:30
Satya B
4a9e7e8e25 Fix for BUG#46591 - .frm file isn't sync'd with sync_frm enabled for
CREATE TABLE...LIKE...
      
The mysql server option 'sync_frm' is ignored when table is created with 
syntax CREATE TABLE .. LIKE.. 
      
Fixed by adding the MY_SYNC flag and calling my_sync() from my_copy() when
the flag is set.

In mysql_create_table(), when the 'sync_frm' is set, MY_SYNC flag is passed 
to my_copy(). 
      
Note: TestCase is not attached and can be tested manually using debugger.
2009-09-03 16:02:03 +05:30
Bjorn Munch
39fca129fb second merge from main, with adaptions 2009-09-02 23:29:11 +02:00
Bjorn Munch
588e9930b4 first merge from main 2009-09-02 18:58:17 +02:00
Bjorn Munch
d65168fdda Bug #32296 mysqltest fails to parse "append_file" inside a "while", it works inside
a "if"
Bug #41913 mysqltest cannot source files from if inside while
Some commands require additional processing which only works first time
Keep content for write_file or append_file with the st_command struct
Add tests for those cases to mysqltest.test
2009-09-02 11:17:33 +02:00
Bjorn Munch
5703baad97 merge 2009-09-01 19:31:28 +02:00
Tatiana A. Nurnberg
e8d45e1be7 manual merge 2009-08-31 12:40:33 -07:00