Added missing spinlock calls to temporary table checks.
This commit is contained in:
@ -2154,10 +2154,15 @@ static bool route_single_stmt(
|
|||||||
/**
|
/**
|
||||||
* Check if the query has anything to do with temporary tables.
|
* Check if the query has anything to do with temporary tables.
|
||||||
*/
|
*/
|
||||||
|
if (!rses_begin_locked_router_action(rses))
|
||||||
|
{
|
||||||
|
succp = false;
|
||||||
|
goto retblock;
|
||||||
|
}
|
||||||
qtype = is_read_tmp_table(rses, querybuf, qtype);
|
qtype = is_read_tmp_table(rses, querybuf, qtype);
|
||||||
check_create_tmp_table(rses, querybuf, qtype);
|
check_create_tmp_table(rses, querybuf, qtype);
|
||||||
check_drop_tmp_table(rses, querybuf,qtype);
|
check_drop_tmp_table(rses, querybuf,qtype);
|
||||||
|
rses_end_locked_router_action(rses);
|
||||||
/**
|
/**
|
||||||
* If autocommit is disabled or transaction is explicitly started
|
* If autocommit is disabled or transaction is explicitly started
|
||||||
* transaction becomes active and master gets all statements until
|
* transaction becomes active and master gets all statements until
|
||||||
@ -2605,7 +2610,10 @@ static bool rses_begin_locked_router_action(
|
|||||||
ROUTER_CLIENT_SES* rses)
|
ROUTER_CLIENT_SES* rses)
|
||||||
{
|
{
|
||||||
bool succp = false;
|
bool succp = false;
|
||||||
|
|
||||||
|
if(rses == NULL)
|
||||||
|
return false;
|
||||||
|
|
||||||
CHK_CLIENT_RSES(rses);
|
CHK_CLIENT_RSES(rses);
|
||||||
|
|
||||||
if (rses->rses_closed) {
|
if (rses->rses_closed) {
|
||||||
|
Reference in New Issue
Block a user