summaryrefslogtreecommitdiff
path: root/sql/sql_parse.cc
diff options
context:
space:
mode:
authorMarko Mäkelä <marko.makela@mariadb.com>2019-03-26 14:57:33 +0200
committerMarko Mäkelä <marko.makela@mariadb.com>2019-03-26 14:57:53 +0200
commitf2c1c9590c7d5bdff0d7c95985cb1a5154a96786 (patch)
treeda3b01dec3651987471606b247e25a25a74160d7 /sql/sql_parse.cc
parent42fd53724420627da65c3862f0fef0acffca3241 (diff)
downloadmariadb-git-f2c1c9590c7d5bdff0d7c95985cb1a5154a96786.tar.gz
Fix cmake -DENABLED_PROFILING=OFF
Diffstat (limited to 'sql/sql_parse.cc')
-rw-r--r--sql/sql_parse.cc4
1 files changed, 3 insertions, 1 deletions
diff --git a/sql/sql_parse.cc b/sql/sql_parse.cc
index e3f183e3e42..1f060305d4f 100644
--- a/sql/sql_parse.cc
+++ b/sql/sql_parse.cc
@@ -1,5 +1,5 @@
/* Copyright (c) 2000, 2017, Oracle and/or its affiliates.
- Copyright (c) 2008, 2018, MariaDB
+ Copyright (c) 2008, 2019, 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
@@ -3016,8 +3016,10 @@ mysql_execute_command(THD *thd)
else
{
WSREP_SYNC_WAIT(thd, WSREP_SYNC_WAIT_BEFORE_SHOW);
+#ifdef ENABLED_PROFILING
if (lex->sql_command == SQLCOM_SHOW_PROFILE)
thd->profiling.discard_current_query();
+#endif
}
thd->status_var.last_query_cost= 0.0;