Merge 10.2 into bb-10.2-ext
This commit is contained in:
commit
1c4b6afbaa
@ -2168,6 +2168,25 @@ show status like "Qcache_hits";
|
|||||||
Variable_name Value
|
Variable_name Value
|
||||||
Qcache_hits 1
|
Qcache_hits 1
|
||||||
drop table t1;
|
drop table t1;
|
||||||
|
#
|
||||||
|
# MDEV-15328: MariaDB 10.2.13 Crashes upon CALL PROCEDURE PARAM
|
||||||
|
# LAST_INSERT_ID ()
|
||||||
|
# (part 2, part 1 is in sp.test)
|
||||||
|
#
|
||||||
|
create table t1 (a int);
|
||||||
|
insert into t1 values (1);
|
||||||
|
CREATE FUNCTION foo (i INT UNSIGNED ) RETURNS int deterministic RETURN 1;
|
||||||
|
show status like "Qcache_queries_in_cache";
|
||||||
|
Variable_name Value
|
||||||
|
Qcache_queries_in_cache 0
|
||||||
|
SELECT foo( LAST_INSERT_ID() ) from t1;
|
||||||
|
foo( LAST_INSERT_ID() )
|
||||||
|
1
|
||||||
|
show status like "Qcache_queries_in_cache";
|
||||||
|
Variable_name Value
|
||||||
|
Qcache_queries_in_cache 0
|
||||||
|
DROP FUNCTION foo;
|
||||||
|
drop table t1;
|
||||||
restore defaults
|
restore defaults
|
||||||
SET GLOBAL query_cache_type= default;
|
SET GLOBAL query_cache_type= default;
|
||||||
SET GLOBAL query_cache_size= default;
|
SET GLOBAL query_cache_size= default;
|
||||||
|
@ -8337,6 +8337,14 @@ drop procedure p1;
|
|||||||
drop procedure p2;
|
drop procedure p2;
|
||||||
drop procedure p3;
|
drop procedure p3;
|
||||||
#
|
#
|
||||||
|
# MDEV-15328: MariaDB 10.2.13 Crashes upon CALL PROCEDURE PARAM
|
||||||
|
# LAST_INSERT_ID ()
|
||||||
|
# (part 1, part 2 is in query_cache.test)
|
||||||
|
#
|
||||||
|
CREATE PROCEDURE foo ( IN i INT UNSIGNED ) BEGIN END;
|
||||||
|
CALL foo( LAST_INSERT_ID() );
|
||||||
|
DROP PROCEDURE foo;
|
||||||
|
#
|
||||||
# Start of 10.3 tests
|
# Start of 10.3 tests
|
||||||
#
|
#
|
||||||
#
|
#
|
||||||
|
@ -358,3 +358,15 @@ Error 1062 Duplicate entry '11' for key 'a'
|
|||||||
|
|
||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
DROP FUNCTION f1;
|
DROP FUNCTION f1;
|
||||||
|
connect con1,localhost,root,,;
|
||||||
|
SELECT TIME('10:10:10.11111111111');
|
||||||
|
TIME('10:10:10.11111111111')
|
||||||
|
10:10:10.111111
|
||||||
|
Warnings:
|
||||||
|
Note 1292 Truncated incorrect time value: '10:10:10.11111111111'
|
||||||
|
disconnect con1;
|
||||||
|
connect con2,localhost,root,,;
|
||||||
|
SHOW WARNINGS;
|
||||||
|
Level Code Message
|
||||||
|
disconnect con2;
|
||||||
|
connection default;
|
||||||
|
@ -335,7 +335,6 @@ INSERT INTO t1 SELECT * FROM t2;
|
|||||||
connection default;
|
connection default;
|
||||||
REPLACE INTO t2 SELECT * FROM t2;
|
REPLACE INTO t2 SELECT * FROM t2;
|
||||||
connection con1;
|
connection con1;
|
||||||
ERROR 40001: Deadlock found when trying to get lock; try restarting transaction
|
|
||||||
disconnect con1;
|
disconnect con1;
|
||||||
connect con2,localhost,root,,test;
|
connect con2,localhost,root,,test;
|
||||||
INSERT INTO t3 VALUES (1);
|
INSERT INTO t3 VALUES (1);
|
||||||
|
@ -1767,6 +1767,21 @@ show status like "Qcache_inserts";
|
|||||||
show status like "Qcache_hits";
|
show status like "Qcache_hits";
|
||||||
drop table t1;
|
drop table t1;
|
||||||
|
|
||||||
|
--echo #
|
||||||
|
--echo # MDEV-15328: MariaDB 10.2.13 Crashes upon CALL PROCEDURE PARAM
|
||||||
|
--echo # LAST_INSERT_ID ()
|
||||||
|
--echo # (part 2, part 1 is in sp.test)
|
||||||
|
--echo #
|
||||||
|
|
||||||
|
create table t1 (a int);
|
||||||
|
insert into t1 values (1);
|
||||||
|
CREATE FUNCTION foo (i INT UNSIGNED ) RETURNS int deterministic RETURN 1;
|
||||||
|
show status like "Qcache_queries_in_cache";
|
||||||
|
SELECT foo( LAST_INSERT_ID() ) from t1;
|
||||||
|
show status like "Qcache_queries_in_cache";
|
||||||
|
DROP FUNCTION foo;
|
||||||
|
drop table t1;
|
||||||
|
|
||||||
--echo restore defaults
|
--echo restore defaults
|
||||||
SET GLOBAL query_cache_type= default;
|
SET GLOBAL query_cache_type= default;
|
||||||
SET GLOBAL query_cache_size= default;
|
SET GLOBAL query_cache_size= default;
|
||||||
|
@ -9841,6 +9841,16 @@ drop procedure p1;
|
|||||||
drop procedure p2;
|
drop procedure p2;
|
||||||
drop procedure p3;
|
drop procedure p3;
|
||||||
|
|
||||||
|
--echo #
|
||||||
|
--echo # MDEV-15328: MariaDB 10.2.13 Crashes upon CALL PROCEDURE PARAM
|
||||||
|
--echo # LAST_INSERT_ID ()
|
||||||
|
--echo # (part 1, part 2 is in query_cache.test)
|
||||||
|
--echo #
|
||||||
|
|
||||||
|
CREATE PROCEDURE foo ( IN i INT UNSIGNED ) BEGIN END;
|
||||||
|
CALL foo( LAST_INSERT_ID() );
|
||||||
|
DROP PROCEDURE foo;
|
||||||
|
|
||||||
--echo #
|
--echo #
|
||||||
--echo # Start of 10.3 tests
|
--echo # Start of 10.3 tests
|
||||||
--echo #
|
--echo #
|
||||||
|
@ -1 +1 @@
|
|||||||
--loose-skip-innodb
|
--loose-skip-innodb --thread-handling=one-thread-per-connection
|
||||||
|
@ -286,3 +286,15 @@ SHOW WARNINGS;
|
|||||||
|
|
||||||
DROP TABLE t1;
|
DROP TABLE t1;
|
||||||
DROP FUNCTION f1;
|
DROP FUNCTION f1;
|
||||||
|
|
||||||
|
# MDEV-14581 Warning info not cleared when caching THD
|
||||||
|
connect (con1,localhost,root,,);
|
||||||
|
SELECT TIME('10:10:10.11111111111');
|
||||||
|
disconnect con1;
|
||||||
|
|
||||||
|
connect (con2,localhost,root,,);
|
||||||
|
SHOW WARNINGS;
|
||||||
|
disconnect con2;
|
||||||
|
|
||||||
|
connection default;
|
||||||
|
|
||||||
|
@ -462,7 +462,7 @@ INSERT INTO t1 SELECT * FROM t2;
|
|||||||
REPLACE INTO t2 SELECT * FROM t2;
|
REPLACE INTO t2 SELECT * FROM t2;
|
||||||
|
|
||||||
--connection con1
|
--connection con1
|
||||||
--error ER_LOCK_DEADLOCK
|
--error 0, ER_LOCK_DEADLOCK, ER_LOCK_WAIT_TIMEOUT
|
||||||
--reap
|
--reap
|
||||||
--disconnect con1
|
--disconnect con1
|
||||||
|
|
||||||
|
@ -2959,6 +2959,10 @@ static bool cache_thread(THD *thd)
|
|||||||
_db_pop_();
|
_db_pop_();
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
/* Clear warnings. */
|
||||||
|
if (!thd->get_stmt_da()->is_warning_info_empty())
|
||||||
|
thd->get_stmt_da()->clear_warning_info(thd->query_id);
|
||||||
|
|
||||||
set_timespec(abstime, THREAD_CACHE_TIMEOUT);
|
set_timespec(abstime, THREAD_CACHE_TIMEOUT);
|
||||||
while (!abort_loop && ! wake_thread && ! kill_cached_threads)
|
while (!abort_loop && ! wake_thread && ! kill_cached_threads)
|
||||||
{
|
{
|
||||||
|
@ -3042,6 +3042,8 @@ public:
|
|||||||
{
|
{
|
||||||
safe_to_cache_query= 0;
|
safe_to_cache_query= 0;
|
||||||
|
|
||||||
|
if (current_select) // initialisation SP variables has no SELECT
|
||||||
|
{
|
||||||
/*
|
/*
|
||||||
There are no sense to mark select_lex and union fields of LEX,
|
There are no sense to mark select_lex and union fields of LEX,
|
||||||
but we should merk all subselects as uncacheable from current till
|
but we should merk all subselects as uncacheable from current till
|
||||||
@ -3058,6 +3060,7 @@ public:
|
|||||||
}
|
}
|
||||||
select_lex.uncacheable|= cause;
|
select_lex.uncacheable|= cause;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
void set_trg_event_type_for_tables();
|
void set_trg_event_type_for_tables();
|
||||||
|
|
||||||
TABLE_LIST *unlink_first_table(bool *link_to_local);
|
TABLE_LIST *unlink_first_table(bool *link_to_local);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user