mirror of
https://github.com/MariaDB/server.git
synced 2025-08-07 00:04:31 +03:00
Merge 10.5 into 10.6
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
/*
|
||||
Copyright (c) 2005, 2015, Oracle and/or its affiliates.
|
||||
Copyright (c) 2010, 2017, MariaDB
|
||||
Copyright (c) 2010, 2022, MariaDB
|
||||
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
@@ -1897,12 +1897,11 @@ run_scheduler(stats *sptr, statement *stmts, uint concur, ulonglong limit)
|
||||
|
||||
pthread_handler_t run_task(void *p)
|
||||
{
|
||||
ulonglong counter= 0, queries;
|
||||
ulonglong queries;
|
||||
ulonglong detach_counter;
|
||||
unsigned int commit_counter;
|
||||
MYSQL *mysql;
|
||||
MYSQL_RES *result;
|
||||
MYSQL_ROW row;
|
||||
statement *ptr;
|
||||
thread_context *con= (thread_context *)p;
|
||||
|
||||
@@ -2023,8 +2022,7 @@ limit_not_met:
|
||||
my_progname, mysql_errno(mysql), mysql_error(mysql));
|
||||
else
|
||||
{
|
||||
while ((row= mysql_fetch_row(result)))
|
||||
counter++;
|
||||
while (mysql_fetch_row(result)) {}
|
||||
mysql_free_result(result);
|
||||
}
|
||||
}
|
||||
@@ -2034,7 +2032,7 @@ limit_not_met:
|
||||
if (commit_rate && (++commit_counter == commit_rate))
|
||||
{
|
||||
commit_counter= 0;
|
||||
run_query(mysql, "COMMIT", strlen("COMMIT"));
|
||||
run_query(mysql, C_STRING_WITH_LEN("COMMIT"));
|
||||
}
|
||||
|
||||
if (con->limit && queries == con->limit)
|
||||
@@ -2046,7 +2044,7 @@ limit_not_met:
|
||||
|
||||
end:
|
||||
if (commit_rate)
|
||||
run_query(mysql, "COMMIT", strlen("COMMIT"));
|
||||
run_query(mysql, C_STRING_WITH_LEN("COMMIT"));
|
||||
|
||||
mysql_close(mysql);
|
||||
|
||||
|
Reference in New Issue
Block a user