diff options
author | cmiller@zippy.cornsilk.net <> | 2007-04-03 19:52:24 -0400 |
---|---|---|
committer | cmiller@zippy.cornsilk.net <> | 2007-04-03 19:52:24 -0400 |
commit | 4078a7cccec3d5f7d3a84d1e98e4bc6ac6895475 (patch) | |
tree | f5182482cadf49899468ed490901464095a3484f /sql/sql_profile.cc | |
parent | cd28612e4b08c2e4b17d215f0eb70fa0e69120f3 (diff) | |
download | mariadb-git-4078a7cccec3d5f7d3a84d1e98e4bc6ac6895475.tar.gz |
Unreported minor bug: We start numbering query IDs at zero, which
is a special case in "SHOW PROFILE FOR QUERY n". No one can get
the zero item (which is always the statement that turns on profiling),
because zero represents the final item, internally.
Now, order the queries starting at one.
Diffstat (limited to 'sql/sql_profile.cc')
-rw-r--r-- | sql/sql_profile.cc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sql/sql_profile.cc b/sql/sql_profile.cc index b17bb6daa0d..5fd83ce70c6 100644 --- a/sql/sql_profile.cc +++ b/sql/sql_profile.cc @@ -158,7 +158,7 @@ void PROFILE_ENTRY::collect() QUERY_PROFILE::QUERY_PROFILE(PROFILING *profiling_arg, char *query_source_arg, uint query_length_arg) - :profiling(profiling_arg), server_query_id(-1), profiling_query_id(-1), + :profiling(profiling_arg), server_query_id(0), profiling_query_id(0), query_source(NULL) { profile_end= &profile_start; @@ -445,7 +445,7 @@ bool QUERY_PROFILE::show(uint options) } PROFILING::PROFILING() - :profile_id_counter(0), keeping(1), current(NULL), last(NULL) + :profile_id_counter(1), keeping(1), current(NULL), last(NULL) { } |