summaryrefslogtreecommitdiff
path: root/storage/perfschema
diff options
context:
space:
mode:
authorOleksandr Byelkin <sanja@mariadb.com>2020-06-22 18:21:21 +0200
committerOleksandr Byelkin <sanja@mariadb.com>2021-07-15 16:28:13 +0200
commita7d880f0b095939118594ecbeba953959ae8e351 (patch)
tree4bd583a11bf5fc42327bdb8b069fb7673cb54a47 /storage/perfschema
parent826eab3f9b28dbc370e5d7a2f81dc42d2f09ed40 (diff)
downloadmariadb-git-a7d880f0b095939118594ecbeba953959ae8e351.tar.gz
MDEV-21916: COM_STMT_BULK_EXECUTE with RETURNING insert wrong values
The problem is that array binding uses net buffer to read parameters for each execution while each execiting with RETURNING write in the same buffer. Solution is to allocate new net buffer to avoid changing buffer we are reading from.
Diffstat (limited to 'storage/perfschema')
-rw-r--r--storage/perfschema/pfs.cc2
1 files changed, 2 insertions, 0 deletions
diff --git a/storage/perfschema/pfs.cc b/storage/perfschema/pfs.cc
index 1bb712f64cc..3e9198a6b6c 100644
--- a/storage/perfschema/pfs.cc
+++ b/storage/perfschema/pfs.cc
@@ -5466,6 +5466,7 @@ void pfs_end_statement_v1(PSI_statement_locker *locker, void *stmt_da)
switch(da->status())
{
case Diagnostics_area::DA_OK_BULK:
+ case Diagnostics_area::DA_EOF_BULK:
case Diagnostics_area::DA_EMPTY:
break;
case Diagnostics_area::DA_OK:
@@ -5706,6 +5707,7 @@ void pfs_end_statement_v1(PSI_statement_locker *locker, void *stmt_da)
switch (da->status())
{
case Diagnostics_area::DA_OK_BULK:
+ case Diagnostics_area::DA_EOF_BULK:
case Diagnostics_area::DA_EMPTY:
break;
case Diagnostics_area::DA_OK: