diff options
author | Mats Kindahl <mats@mysql.com> | 2008-08-25 14:23:49 +0200 |
---|---|---|
committer | Mats Kindahl <mats@mysql.com> | 2008-08-25 14:23:49 +0200 |
commit | aa67166ef208cc7346b5ad36900f3f93bdee28d9 (patch) | |
tree | 652190f524948fc11fd70f6dd652192a6cfece05 /sql/sql_class.h | |
parent | 8b637b284784d92b912318cd3b52d1550920fa09 (diff) | |
download | mariadb-git-aa67166ef208cc7346b5ad36900f3f93bdee28d9.tar.gz |
Eliminating some compiler warnings.
sql/sql_class.h:
Adding default return clause.
Diffstat (limited to 'sql/sql_class.h')
-rw-r--r-- | sql/sql_class.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/sql/sql_class.h b/sql/sql_class.h index 0bc8d00b22c..488a35ff070 100644 --- a/sql/sql_class.h +++ b/sql/sql_class.h @@ -1001,6 +1001,7 @@ show_system_thread(enum_thread_type thread) { #define RETURN_NAME_AS_STRING(NAME) case (NAME): return #NAME switch (thread) { + static char buf[64]; RETURN_NAME_AS_STRING(NON_SYSTEM_THREAD); RETURN_NAME_AS_STRING(SYSTEM_THREAD_DELAYED_INSERT); RETURN_NAME_AS_STRING(SYSTEM_THREAD_SLAVE_IO); @@ -1008,6 +1009,9 @@ show_system_thread(enum_thread_type thread) RETURN_NAME_AS_STRING(SYSTEM_THREAD_NDBCLUSTER_BINLOG); RETURN_NAME_AS_STRING(SYSTEM_THREAD_EVENT_SCHEDULER); RETURN_NAME_AS_STRING(SYSTEM_THREAD_EVENT_WORKER); + default: + sprintf(buf, "<UNKNOWN SYSTEM THREAD: %d>", thread); + return buf; } #undef RETURN_NAME_AS_STRING } |