summaryrefslogtreecommitdiff
path: root/sql/sql_cursor.cc
diff options
context:
space:
mode:
authorJan Lindström <jan.lindstrom@mariadb.com>2015-06-24 07:16:08 +0300
committerJan Lindström <jan.lindstrom@mariadb.com>2015-06-24 07:16:08 +0300
commit2e4984c185ddcd2da789017cd147338846ff409a (patch)
tree0293831900c860600efbaa747ea886d9d1cbf5bd /sql/sql_cursor.cc
parent792b53e80806df893ee62c9a1c1bd117114c8c6d (diff)
parenta6087e7dc1ef3561d8189c8db15e9591d0f9b520 (diff)
downloadmariadb-git-2e4984c185ddcd2da789017cd147338846ff409a.tar.gz
Merge tag 'mariadb-10.0.20' into 10.0-FusionIO10.0-FusionIO
Conflicts: storage/innobase/os/os0file.cc storage/xtradb/os/os0file.cc storage/xtradb/srv/srv0start.cc
Diffstat (limited to 'sql/sql_cursor.cc')
-rw-r--r--sql/sql_cursor.cc4
1 files changed, 4 insertions, 0 deletions
diff --git a/sql/sql_cursor.cc b/sql/sql_cursor.cc
index 99b7b1e58d0..c09f3269d7a 100644
--- a/sql/sql_cursor.cc
+++ b/sql/sql_cursor.cc
@@ -98,6 +98,7 @@ public:
int mysql_open_cursor(THD *thd, select_result *result,
Server_side_cursor **pcursor)
{
+ sql_digest_state *parent_digest;
PSI_statement_locker *parent_locker;
select_result *save_result;
Select_materialize *result_materialize;
@@ -117,11 +118,14 @@ int mysql_open_cursor(THD *thd, select_result *result,
&thd->security_ctx->priv_user[0],
(char *) thd->security_ctx->host_or_ip,
2);
+ parent_digest= thd->m_digest;
parent_locker= thd->m_statement_psi;
+ thd->m_digest= NULL;
thd->m_statement_psi= NULL;
/* Mark that we can't use query cache with cursors */
thd->query_cache_is_applicable= 0;
rc= mysql_execute_command(thd);
+ thd->m_digest= parent_digest;
thd->m_statement_psi= parent_locker;
MYSQL_QUERY_EXEC_DONE(rc);