mirror of
https://github.com/MariaDB/server.git
synced 2025-08-01 03:47:19 +03:00
small cleanup
* keep all com_xxx constants together in struct system_status_var * fix an outdated comment in sql_cmd.h * fix an off-by-one bug in mysqld.cc
This commit is contained in:
@ -3919,7 +3919,7 @@ void init_sql_statement_info()
|
|||||||
while (var->name != NULL)
|
while (var->name != NULL)
|
||||||
{
|
{
|
||||||
ptr= (size_t)(var->value);
|
ptr= (size_t)(var->value);
|
||||||
if ((first_com <= ptr) && (ptr <= last_com))
|
if ((first_com <= ptr) && (ptr < last_com))
|
||||||
{
|
{
|
||||||
com_index= ((int)(ptr - first_com))/record_size;
|
com_index= ((int)(ptr - first_com))/record_size;
|
||||||
DBUG_ASSERT(com_index < (uint) SQLCOM_END);
|
DBUG_ASSERT(com_index < (uint) SQLCOM_END);
|
||||||
|
@ -674,8 +674,17 @@ typedef struct system_variables
|
|||||||
|
|
||||||
typedef struct system_status_var
|
typedef struct system_status_var
|
||||||
{
|
{
|
||||||
ulong com_other;
|
|
||||||
ulong com_stat[(uint) SQLCOM_END];
|
ulong com_stat[(uint) SQLCOM_END];
|
||||||
|
ulong com_other;
|
||||||
|
|
||||||
|
ulong com_stmt_prepare;
|
||||||
|
ulong com_stmt_reprepare;
|
||||||
|
ulong com_stmt_execute;
|
||||||
|
ulong com_stmt_send_long_data;
|
||||||
|
ulong com_stmt_fetch;
|
||||||
|
ulong com_stmt_reset;
|
||||||
|
ulong com_stmt_close;
|
||||||
|
|
||||||
ulong created_tmp_disk_tables_;
|
ulong created_tmp_disk_tables_;
|
||||||
ulong created_tmp_tables_;
|
ulong created_tmp_tables_;
|
||||||
ulong ha_commit_count;
|
ulong ha_commit_count;
|
||||||
@ -728,14 +737,6 @@ typedef struct system_status_var
|
|||||||
ulong filesort_rows_;
|
ulong filesort_rows_;
|
||||||
ulong filesort_scan_count_;
|
ulong filesort_scan_count_;
|
||||||
ulong filesort_pq_sorts_;
|
ulong filesort_pq_sorts_;
|
||||||
/* Prepared statements and binary protocol */
|
|
||||||
ulong com_stmt_prepare;
|
|
||||||
ulong com_stmt_reprepare;
|
|
||||||
ulong com_stmt_execute;
|
|
||||||
ulong com_stmt_send_long_data;
|
|
||||||
ulong com_stmt_fetch;
|
|
||||||
ulong com_stmt_reset;
|
|
||||||
ulong com_stmt_close;
|
|
||||||
|
|
||||||
/* Features used */
|
/* Features used */
|
||||||
ulong feature_dynamic_columns; /* +1 when creating a dynamic column */
|
ulong feature_dynamic_columns; /* +1 when creating a dynamic column */
|
||||||
|
@ -96,7 +96,7 @@ enum enum_sql_command {
|
|||||||
|
|
||||||
/*
|
/*
|
||||||
When a command is added here, be sure it's also added in mysqld.cc
|
When a command is added here, be sure it's also added in mysqld.cc
|
||||||
in "struct show_var_st status_vars[]= {" ...
|
in "struct show_var_st com_status_vars[]= {" ...
|
||||||
*/
|
*/
|
||||||
/* This should be the last !!! */
|
/* This should be the last !!! */
|
||||||
SQLCOM_END
|
SQLCOM_END
|
||||||
|
Reference in New Issue
Block a user