Commit graph

167402 commits

Author SHA1 Message Date
Sergei Petrunia
93d5cdf03f MDEV-9946: main.xtradb_mrr fails sporadically
Make the testcase stable by adding FORCE INDEX
2016-08-04 13:14:45 +03:00
Sergei Golubchik
c0cb84bb2f Merge branch 'bb-5.5-serg' into 5.5 2016-08-04 10:57:55 +02:00
Sergey Vojtovich
eb32dfd809 MDEV-10365 - Race condition in error handling of INSERT DELAYED
Shared variables of Delayed_insert may be updated without mutex protection
when delayed insert thread gets an error.

Re-acquire mutex earlier, so that shared variables are protected.
2016-08-04 10:55:59 +04:00
Sergei Golubchik
470f2598cc MDEV-10465 general_log_file can be abused
This issue was discovered by
Dawid Golunski (http://legalhackers.com)
2016-08-03 20:56:24 +02:00
Sergei Golubchik
0214115c7f trivial cleanup 2016-08-03 20:53:10 +02:00
Sergei Golubchik
03dec1aa49 MDEV-10350 "./mtr --report-features" doesn't work
removed
2016-08-03 20:53:04 +02:00
Sergei Golubchik
9d2f892999 MDEV-7329 plugins.pam_cleartext fails sporadically in buildbot
wait until the failed connection thread completely dies
before uninstalling pam plugin
2016-08-03 20:52:58 +02:00
Sergei Golubchik
75891eda11 improve pam_cleartext.test a bit 2016-08-03 20:52:50 +02:00
Sergei Golubchik
5265243cc4 Merge branch 'merge/merge-xtradb-5.5' into 5.5 2016-08-03 20:44:08 +02:00
Sergei Golubchik
e316c46f43 5.5.50-38.0 2016-08-03 20:43:29 +02:00
Sergei Golubchik
19fe10c3e9 MDEV-6581 Writing to TEMPORARY TABLE not possible in read-only
don't mark transactions read-write if no real storage engine is affected (only binlog writes).
2016-08-03 20:39:47 +02:00
Sergei Golubchik
a350e53b61 Merge branch 'mysql/5.5' into 5.5
without a fix for Bug#12818255 (MDEV-6581)
2016-08-03 20:38:25 +02:00
Vladislav Vaintroub
511313b9d6 MDEV-10010 - potential deadlock on windows due to recursive
SRWLock acquisition

Backport patch from 10.1
2016-08-03 13:42:46 +00:00
Vladislav Vaintroub
141f88d1d5 MDEV-10357 my_context_continue() does not store current fiber on Windows
Make sure current fiber is saved in my_context::app_fiber
in both my_context_spawn() and my_context_continue()
2016-08-03 12:41:38 +00:00
Alexander Barkov
ecb7ce7844 MDEV-10467 Assertion `nr >= 0.0' failed in Item_sum_std::val_real()
Backporting MDEV-5781 from 10.0.
2016-08-03 15:55:48 +04:00
Jan Lindström
35c9c85634 MDEV-10217: innodb.innodb_bug59641 fails sporadically in buildbot: InnoDB: Failing assertion: current_rec != insert_rec in file page0cur.c line 1052
Added record printout when current_rec == insert_rec with lengths for
debug builds.
2016-08-03 13:46:01 +03:00
Vladislav Vaintroub
6b71a6d2d9 MDEV-10383 Named pipes : multiple servers can listen on the same pipename
Use FILE_FLAG_FIRST_PIPE_INSTANCE with the first CreateNamedPipe()
call to make sure the pipe does not already exist.
2016-08-02 18:52:51 +02:00
Oleksandr Byelkin
5fdb3cfcd4 MDEV-10419: crash in mariadb 10.1.16-MariaDB-1~trusty
Fixed initialization and usage of THD reference in subselect engines.
2016-07-30 20:13:03 +02:00
Sergei Petrunia
c6aaa2adbe MDEV-10228: update test results 2016-07-30 10:53:01 +03:00
Sergei Petrunia
15ef38d2ea MDEV-10228: Delete missing rows with OR conditions
Fix get_quick_keys(): When building range tree from a condition
in form

  keypart1=const AND (keypart2 < 0 OR keypart2>=0)

the SEL_ARG for keypart2 represents an interval (-inf, +inf).
However, the logic that sets UNIQUE_RANGE flag fails to recognize
this, and sets UNIQUE_RANGE flag if (keypart1, keypart2) covered
a unique key.
As a result, range access executor assumes the interval can have
at most one row and only reads the first row from it.
2016-07-27 00:38:51 +03:00
Sergey Vojtovich
1b5da2ca49 MDEV-10316 - main.type_date fails around midnight sporadically
A better fix for MySQL Bug#41776: use hard timestamp rather than unreliable
sleep.
2016-07-21 15:44:58 +04:00
Elena Stepanova
5cf49cdf92 MDEV-10248 Cannot Remove Test Tables
While dropping the test database, use IF EXISTS to avoid bogus errors
2016-07-15 23:51:30 +03:00
Sergei Golubchik
4e19aa3864 MDEV-10318 unset params in --ps --embedded
add a test case
2016-07-12 12:13:31 +02:00
Vladislav Vaintroub
97ded96a33 MDEV-10318 : Fix crash in embedded, in case prepared statement has parameter placeholders, but does not bind parameters 2016-07-11 22:16:39 +00:00
Balasubramanian Kandasamy
7d57772f47 Bug#23736787 - YUM UPDATE FAIL FROM 5.5.51(COMUNITY/COMMERCIAL) TO 5.6.32(COMUNITY/COMMERCIAL)
Remove mysql_config from client sub-package

(cherry picked from commit 45c4bfa0f3f1c70756591f48710bb3e76ffde9bc)
2016-07-07 10:53:11 +05:30
Sergei Golubchik
e81455bb16 MDEV-7973 bigint fail with gcc 5.0
-LONGLONG_MIN is the undefined behavior in C.
longlong2decimal() used to do this:

  int longlong2decimal(longlong from, decimal_t *to) {
    if ((to->sign= from < 0))
      return ull2dec(-from, to);
    return ull2dec(from, to);

and later in ull2dec() (DIG_BASE is 1000000000):

  static int ull2dec(ulonglong from, decimal_t *to) {
    for (intg1=1; from >= DIG_BASE; intg1++, from/=DIG_BASE) {}

this breaks in gcc-5 at -O3. Here ull2dec is inlined into
longlong2decimal. And gcc-5 believes that 'from' in the
inlined ull2dec is always a positive integer (indeed, if it was
negative, then -from was used instead). So gcc-5 uses
*signed* comparison with DIG_BASE.

Fix: make a special case for LONGLONG_MIN, don't negate it
2016-07-06 15:17:38 +04:00
Sergey Vojtovich
a7814d44fc MDEV-10311 - funcs_1.processlist_priv_no_prot fails sporadically
State column of SHOW PROCESSLIST can have NULL values for being initialized
threads (between new connection was acknowledged and waiting for network data).

Fixed test case to handle such cases by waiting for State to become empty
string.
2016-06-30 12:59:52 +04:00
Oleksandr Byelkin
79f852a069 MDEV-10050: Crash in subselect
thd should not be taken earlier then fix_field and reset on fix_fields if it is needed.
2016-06-24 14:15:35 +02:00
Jan Lindström
ef92aaf9ec MDEV-10083: Orphan ibd file when playing with foreign keys
Analysis: row_drop_table_for_mysql did not allow dropping
referenced table even in case when actual creating of the
referenced table was not successfull if foreign_key_checks=1.

Fix: Allow dropping referenced table even if foreign_key_checks=1
if actual table create returned error.
2016-06-23 06:46:05 +03:00
Sergei Golubchik
a482e76e65 fix a mysql-5.5.50 merge: mysqlcheck
quote identifiers correctly
2016-06-20 16:12:54 +02:00
Sergei Golubchik
95bf696d2c MDEV-9749 InnoDB receives 'Bad file descriptor' error, possibly related to feedback plugin
and
MDEV-10250 InnoDB: Error: File (unknown): 'close' returned OS error 209. Cannot continue operation"

after a failed connect() feedback plugin was continuing with the
file descriptor, trying to send the data (which failed) and
closing it at the end. Even though this fd might've been reused for
something else already.
2016-06-20 15:49:00 +02:00
Sergey Vojtovich
7f38a070ba MDEV-10043 - main.events_restart fails sporadically in buildbot (crashes upon
shutdown)

There was race condition between shutdown thread and event worker threads.

Shutdown thread waits for thread_count to become 0 in close_connections(). It
may happen so that event worker thread was started but didn't increment
thread_count by this time. In this case shutdown thread may miss wait for this
working thread and continue deinitialization. Worker thread in turn may continue
execution and crash on deinitialized data.

Fixed by incrementing thread_count before thread is actually created like it is
done for connection threads.

Also let event scheduler not to inc/dec running threads counter for symmetry
with other "service" threads.
2016-06-20 15:17:10 +04:00
Thayumanavar S
9f7288e2e0 BUG#23080148 - BACKPORT BUG 14653594 AND BUG 20683959 TO
MYSQL-5.5

The bug asks for a backport of bug#1463594 and bug#20682959. This
is required because of the fact that if replication is enabled, master
transaction can commit whereas slave can't commit due to not exact
'enviroment'. This manifestation is seen in bug#22024200.
2016-06-20 11:35:43 +05:30
Daniel Bartholomew
128930c19b bump the VERSION 2016-06-17 12:39:20 -04:00
Vicențiu Ciorbaru
7ff86b4991 MDEV-10247 TokuDB assertion error when building with DEBUG
Fix the assertion failure by setting the struct to 0. This can not be
done using a macro due to different definitions of mutexes on various
OS-es.
Afterwards we call toku_mutex_init and completely initialize the locks.
2016-06-17 14:59:17 +03:00
Terje Rosten
4a3f1c1f10 BUG#17903583 MYSQL-COMMUNITY-SERVER SHOULD NOT DEPEND ON MYSQL-COMMUNITY-CLIENT (#70985)
Fix is a backport of BUG#18518216/72230 to MySQL 5.5 and 5.6.

Will also resolve:

 BUG#23605713/81384 LIBMYSQLCLIENT.SO.18 MISSING FROM MYSQL 5.7

  as mysql-community-libs-5.5 or mysql-community-libs-5.6 can
  installed on EL6 system with libmysqlclient.16 (from MySQL 5.1)
  libmysqlclient.20 (from MySQL 5.7) by doing:

  $ rpm --oldpackage -ivh mysql-community-libs-5.5.50-2.el6.x86_64.rpm

  Providing a way to have several versions of libmysqlclient installed
  on the same system.

and help:

 BUG#23088014/80981 LIBS-COMPAT RPMS SHOULD BE INDEPENDENT OF ALL OTHER SUBPACKAGES

  due to less strict coupling between -libs-compat and -common package.
2016-06-17 13:30:24 +02:00
Shishir Jaiswal
957aefdc8f Bug#23498283 - BUFFER OVERFLOW
DESCRIPTION
===========
Buffer overflow is reported in Regex library. This can be
triggered when the data corresponding to argv[1] is >=
512 bytes resutling in abnormal behaviour.

ANALYSIS
========
Its a straight forward case of SEGFAULT where the target
buffer is smaller than the source string to be copied.
A simple pre-copy validation should do.

FIX
===
A check is added before doing strcpy() to ensure that the
target buffer is big enough to hold the to-be copied data.
If the check fails, the program aborts.
2016-06-17 10:11:33 +05:30
Vicențiu Ciorbaru
12ae840375 Fix typo bug that cause myisam repair to fail
We need to return TRUE if got_error == 1, not error, which is
initialized to FALSE.
2016-06-16 22:04:24 +03:00
Vicențiu Ciorbaru
c7eef02953 Increase the number of default build thread ids possibilities
When running mysql-test-run without a parallel parameter, it might
be impossible to find a free port.
2016-06-16 22:02:45 +03:00
Vicențiu Ciorbaru
7ab7abdb51 Fix compilation failure when compiling with std=c90
Change variable declaration to be before any other statements.
2016-06-16 18:52:46 +03:00
Vladislav Vaintroub
b644661e5d MDEV-9256 : Crashes on Windows x64 with aria_pagecache_buffer_size > 4GB
Fixed wrong calculation of buffer sizes. ulong datatype was used wrongly,
as were the casts to ulong. Buffer sizes should be of type size_t,
not ulong, or bad things happen on 64 bit Windows.

This patch changes pagecache struct to use size_t/ssize_t
where long/ulong were previously used. Also, removed several casts.
2016-06-14 22:31:39 +02:00
Vicențiu Ciorbaru
34a104ba0c MDEV-10229: TokuDB fails to build with CLang
Structure initialization must feature all members present within the
struct.
2016-06-14 19:17:29 +03:00
Vicențiu Ciorbaru
1bf25092cb MDEV-10162: Update repair testcase 2016-06-14 19:17:29 +03:00
Vicențiu Ciorbaru
2b47832a2d Fixed compilation failure using clang
Both aria and myisam storage engines feature a logic path in
thr_find_all_keys that leads to undefined behaviour by bypassing the
initialization code of variables after my_thread_init().

By refactoring the nested logic into a separate function, this problem
is resolved.
2016-06-14 19:17:29 +03:00
Vicențiu Ciorbaru
6a34ba3130 [Code cleanup] Refactor duplicate code within myisam and maria sort.cc 2016-06-14 19:17:29 +03:00
Daniel Black
bfef17bec1 MDEV-9433: [PATCH} cppcheck reported a number of minor coding errors
Fix cppwarning of va_args being opened but not closed.

Signed-off-by: Vicențiu Ciorbaru <vicentiu@mariadb.org>
2016-06-14 19:17:29 +03:00
Daniel Black
0089af8e1c MDEV-9433: [PATCH] cppcheck reported a number of minor coding errors
Fix a bug in testhash.c that caused an out of bounds memory access
when command line parameters specified 0 records to be inserted
in the hashtable.

Signed-off-by: Vicențiu Ciorbaru <vicentiu@mariadb.org>
2016-06-14 19:17:29 +03:00
Daniel Black
cf721d23cc MDEV-9257: Increase limit on parallel workers in mysql-test-run
Signed-off-by: Daniel Black <daniel.black@au.ibm.com>
2016-06-14 19:17:29 +03:00
Sergei Golubchik
05bb3b9f85 fix main.ssl_ca test for windows
where $HOME is the empty string
2016-06-14 16:28:07 +02:00
Sergei Golubchik
a4cfd32125 main.openssl_1 failure
don't test a cipher that was removed from
recent openssl versions
2016-06-14 14:52:43 +02:00