Commit graph

3617 commits

Author SHA1 Message Date
Nirbhay Choubey
d5e7008bdd Bug#58139 : default-auth option not recognized in MySQL standard
command line clients.

Command line tools like mysqladmin and mysqldump did not recognize
default-auth and plugin-dir options.

Support for these options was found missing in these command line
tools.

Fixed by adding support for the same.
2010-12-07 17:37:07 +05:30
Davi Arnaut
1ab37fd3c0 Merge of mysql-5.1-bugteam into mysql-5.5-bugteam. 2010-11-30 17:06:53 -02:00
Bjorn Munch
d2fb19855e merge from 5.5-mtr 2010-11-27 11:52:17 +01:00
Davi Arnaut
0008e06489 Bug#51817: incorrect assumption: thd->query at 0x2ab2a8360360 is an invalid pointer
The problem is that the logic which checks if a pointer is
valid relies on a poor heuristic based on the start and end
addresses of the data segment and heap.

Apart from miscalculating the heap bounds, this approach also
suffers from the fact that memory can come from places other
than the heap. See Bug#58528 for a more detailed explanation.

On Linux, the solution is to access the process's memory
through /proc/self/task/<tid>/mem, which allows for retrieving
the contents of pages within the virtual address space of
the calling process. If a address range is not mapped, a
input/output error is returned.
2010-11-26 19:59:10 -02:00
Alexander Barkov
43cd08712c Merging from mysql-5.1-bugteam 2010-11-26 17:22:06 +03:00
Nirbhay Choubey
8629024b23 Bug #54899 : --one-database option cannot handle DROP/CREATE DATABASE commands
After dropping and recreating the database specified along with --one-database
option at command line, mysql client keeps filtering the statements even after
the execution of a 'USE' command on the same database.

--one-database option enables the filtering of statements when the current
database is not the one specified at the command line. However, when the same
database is dropped and recreated the variable (current_db) that holds the
inital database name gets altered. This bug exploits the fact that current_db
initially gets set to null value (0) when a 'use db_name' follows the recreation
of same database db_name (speficied at the command line) and hence skip_updates
gets set to 1, which inturn triggers the further filtering of statements.

Fixed by making get_current_db() a no-op function when one_database is set,
and hence, under that condition current_db will not get altered.
Note, however the value of current_db can change when we execute 'connect'
command with a differnet database to reconnect to the server, in which case,
the behavior of --one-database will be formulated using this new database.
2010-11-26 19:27:59 +05:30
Bjorn Munch
20851e4012 Bug #58412 mysqltest: allow quoting of strings in let and in if comparison
Stripping quotes in let was a bad idea, will not fix
Added code to strip quotes from rhs in comparisons
2010-11-26 10:57:01 +01:00
Davi Arnaut
f6deb00a56 WL#5665: Removal of the autotools-based build system
The autotools-based build system has been superseded and
is being removed in order to ease the maintenance burden on
developers tweaking and maintaining the build system.

In order to support tools that need to extract the server
version, a new file that (only) contains the server version,
called VERSION, is introduced. The file contents are human
and machine-readable. The format is:

MYSQL_VERSION_MAJOR=5
MYSQL_VERSION_MINOR=5
MYSQL_VERSION_PATCH=8
MYSQL_VERSION_EXTRA=-rc

The CMake based version extraction in cmake/mysql_version.cmake
is changed to extract the version from this file. The configure
to CMake wrapper is retained for backwards compatibility and to
support the BUILD/ scripts. Also, a new a makefile target
show-dist-name that prints the server version is introduced.
2010-11-20 12:47:50 -02:00
Bjorn Munch
b295a25109 merge from 5.1-mtr 2010-11-19 10:29:08 +01:00
Bjorn Munch
374c6447ca upmerge 58257 2010-11-18 16:41:35 +01:00
Bjorn Munch
d718af063e Bug #58257 mysqltest: in if(), ! $var with space is always false
Evaluation would start with the space and thus ignore the $
Added while() to skip past white space
2010-11-17 16:05:52 +01:00
Bjorn Munch
f45b6605a2 avoid compilation warning about incomplete switch 2010-11-19 12:35:53 +01:00
Bjorn Munch
0b260aca41 merge from 5.5-mtr 2010-11-19 11:26:43 +01:00
Bjorn Munch
f6b1d5a63e upmerge 58087 2010-11-17 11:18:52 +01:00
Bjorn Munch
9142f7462b Bug #58087 mysqltest re-evaluates 'let' expressions infinitely
Results from query is sent for evaluation
Break recursion by asking for ` to be ignored
2010-11-15 14:23:02 +01:00
Magnus Blåudd
87ab418119 Bug#58195 Make mysqltest poll for next epoch more often
- Speed up replicated NDB test by havin mysqltest poll every 100ms (instead
   of every second) in sync_master_with_slave. Default epoch
   timeout is 100ms, so that make sense.
2010-11-15 10:51:59 +01:00
Bjorn Munch
5e51571f7b merge from 5.5 2010-11-14 13:24:29 +01:00
Bjorn Munch
2ab2426104 merge from 5.1 up to rev 3471 2010-11-14 12:23:51 +01:00
Bjorn Munch
28f60d525a Bug #57276 mysqltest: add support for simple compares in if/while conditions
Added more parsing in do_block()
      Limitation: left operand must be variable
      Also changed var_set_int from 57036 to var_check_int
      Added tests to mysqltest.test
      Some tests can now be simplified but will take this later
      Updated after comments, now white space around operator not needed
2010-11-10 09:42:14 +01:00
Sven Sandberg
d520df90fc wL#5625: Deprecate mysqlbinlog options --base64-output=always and --base64-output
Adds deprecation warning for the mysqlbinlog options
--base64-output=always and --base64-output.
A warning is printed when the flags are used,
and also when running mysqlbinlog --help.
2010-10-29 16:56:58 +02:00
Bjorn Munch
8eb6992231 merge from 5.5-mtr 2010-10-26 08:30:02 +02:00
Bjorn Munch
16a55614cc merge from 5.1-mtr 2010-10-25 15:48:41 +02:00
Bjorn Munch
add465e5a1 merge from 5.5 2010-10-21 11:20:53 +02:00
Davi Arnaut
1e1985eba7 Merge of mysql-5.1-bugteam into mysql-5.5-bugteam. 2010-10-20 17:02:59 -02:00
Davi Arnaut
560ee2158d Bug#45288: pb2 returns a lot of compilation warnings
Fix assorted warnings that are generated in optimized builds.
Most of it is silencing variables that are set but unused.

This patch also introduces the MY_ASSERT_UNREACHABLE macro
which helps the compiler to deduce that a certain piece of
code is unreachable.
2010-10-20 16:21:40 -02:00
Bjorn Munch
2abe0d6e7e upmerge 52019 2010-10-20 12:17:19 +02:00
Bjorn Munch
441e3b2412 Fixed wrong feof check in read_line, see 52019 2010-10-20 11:41:51 +02:00
Bjorn Munch
daa70e0ab9 Fixed missing cast of arg to my_mbcharlen 2010-10-20 11:39:58 +02:00
Bjorn Munch
af056dc560 48863 followup: move an array declaration out from within if block 2010-10-20 11:30:50 +02:00
Bjorn Munch
ce786ab04d Bug #52019 main.mysqltest fails on new tests for lowercase_result
Limited to actual bug fix, fixing a while condition
Again confirmed on Linux PPC and on AIX 5.3
2010-10-20 11:22:08 +02:00
Davi Arnaut
69aea87d5f Merge of mysql-5.1-bugteam into mysql-5.5-bugteam. 2010-10-19 20:51:34 -02:00
Davi Arnaut
39e9bde2c0 Bug#45288: pb2 returns a lot of compilation warnings
Tag or remove unused arguments and variables.
2010-10-19 20:36:59 -02:00
Alexey Botchkov
6adb077efc Bug#35269 mysqlcheck behaves different depending on order of parameters
Issue an error if user specifies multiple commands to run.
        Also there was an unnoticed bug that DO_CHECK was actually 0 which lead
        to wrong actions in some cases.
        The mysqlcheck.test contained commands with the suspicious meaning
        for the above reason. Extra commands removed from there.

per-file commands:
  client/mysqlcheck.c
Bug#35269      mysqlcheck behaves different depending on order of parameters
        Drop with an error if multiple commands.
  mysql-test/r/mysqlcheck.result
Bug#35269      mysqlcheck behaves different depending on order of parameters
        result completed.
  mysql-test/t/mysqlcheck.test
Bug#35269      mysqlcheck behaves different depending on order of parameters
        testcase added.
        not-working commands removed from some mysqlcheck calls.
2010-10-08 12:09:47 +05:00
Alexander Nozdrin
f79f6e0c34 Fix for Bug#57094 (Copyright notice incorrect?).
The fix is to:
  - introduce ORACLE_WELCOME_COPYRIGHT_NOTICE define to have a single place
    to specify copyright notice;
  - replace custom copyright notices with ORACLE_WELCOME_COPYRIGHT_NOTICE
    in programs.
2010-10-06 19:06:13 +04:00
Georgi Kodinov
dd2e3db48f merge 2010-10-04 15:42:16 +03:00
Bjorn Munch
299f0f201c Follow-up to 54861, cannot assume pthread_t is integral type 2010-10-04 12:01:16 +02:00
Bjorn Munch
e688b6c299 merge from 5.5-mtr 2010-10-04 10:40:28 +02:00
Bjorn Munch
687696a97a merge from 5.1-mtr 2010-10-03 19:37:58 +02:00
Bjorn Munch
53462869d3 upmerge 20304 2010-10-01 15:55:49 +02:00
Mattias Jonsson
1045f4526f merge 2010-10-01 15:25:13 +02:00
Bjorn Munch
ad7521df31 Bug #20304 mysqltest: reap with no preceding statement hangs forever
Added sanity check, similar to the one preventing send without reap
2010-10-01 11:00:18 +02:00
Bjorn Munch
32da790381 upmerge 52828 2010-09-30 12:53:36 +02:00
Bjorn Munch
87234b74ca Bug #52828 Tests that use perl fail when perl is not in path
Trying to run perl fails, just like it does when perl is started but fails
Trap the case that perl was not found/could not be started, and skip test
Also force a restart of servers since test may already have done something
mtr now also appends path of current perl to PATH to aid mysqltest
2010-09-30 12:42:37 +02:00
Bjorn Munch
1a75a23ce1 merge from 5.1 2010-09-29 12:56:10 +02:00
Alexander Nozdrin
a79093cd94 Auto-merge from mysql-5.5-merge. 2010-09-28 19:15:58 +04:00
Bjorn Munch
cf362a41b9 upmerge 56125,56921 2010-09-28 16:00:11 +02:00
Bjorn Munch
3a404d4966 Bug #57036 Add checks in mysqltest that variables treated as ints are in fact ints
Adds boolean flag is_int and a separete function to check for int value
Added tests to mysqltest.test
2010-09-27 14:36:16 +02:00
Konstantin Osipov
5b06699029 Merge 5.5 -> 5.5-merge. 2010-09-24 17:18:45 +04:00
Bjorn Munch
80d666bc21 Bug #56921 It should be possible to log connection statements in mysqltest
Added --enable-connect-log, somewhet similar to --enable-query-log
If query log is disabled, disable connect log too
Also some related cleanup in mysqltest.test: removing duplicate test loop
2010-09-22 10:57:10 +02:00
Georgi Kodinov
dc0b8f7ada merge of mysql-5.5 into mysql-5.5-wl1054 2010-09-20 17:17:32 +03:00