diff options
author | monty@mysql.com/narttu.mysql.fi <> | 2006-12-15 00:51:37 +0200 |
---|---|---|
committer | monty@mysql.com/narttu.mysql.fi <> | 2006-12-15 00:51:37 +0200 |
commit | 88dd873de0d5dc6e8f262268f925596a60b58704 (patch) | |
tree | 142bd488523fec48817d9fb2194f1a608eec00fc /sql/handler.cc | |
parent | 601e6f4b2a78921304bc1d779991c615ee229f89 (diff) | |
download | mariadb-git-88dd873de0d5dc6e8f262268f925596a60b58704.tar.gz |
Fixed compiler warnings detected by option -Wshadow and -Wunused:
- Removed not used variables and functions
- Added #ifdef around code that is not used
- Renamed variables and functions to avoid conflicts
- Removed some not used arguments
Fixed some class/struct warnings in ndb
Added define IS_LONGDATA() to simplify code in libmysql.c
I did run gcov on the changes and added 'purecov' comments on almost all lines that was not just variable name changes
Diffstat (limited to 'sql/handler.cc')
-rw-r--r-- | sql/handler.cc | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/sql/handler.cc b/sql/handler.cc index ae314afb991..2429217418c 100644 --- a/sql/handler.cc +++ b/sql/handler.cc @@ -122,11 +122,6 @@ handlerton isam_hton = { "ISAM", SHOW_OPTION_NO, "Obsolete storage engine", DB_TYPE_ISAM, NULL, 0, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, HTON_NO_FLAGS }; - -/* static functions defined in this file */ - -static SHOW_COMP_OPTION have_yes= SHOW_OPTION_YES; - /* number of entries in handlertons[] */ ulong total_ha; /* number of storage engines (from handlertons[]) that support 2pc */ @@ -714,7 +709,7 @@ int ha_commit_trans(THD *thd, bool all) } DBUG_EXECUTE_IF("crash_commit_after_prepare", abort();); if (error || (is_real_trans && xid && - (error= !(cookie= tc_log->log(thd, xid))))) + (error= !(cookie= tc_log->log_xid(thd, xid))))) { ha_rollback_trans(thd, all); error= 1; @@ -722,7 +717,7 @@ int ha_commit_trans(THD *thd, bool all) } DBUG_EXECUTE_IF("crash_commit_after_log", abort();); } - error=ha_commit_one_phase(thd, all) ? cookie ? 2 : 1 : 0; + error=ha_commit_one_phase(thd, all) ? (cookie ? 2 : 1) : 0; DBUG_EXECUTE_IF("crash_commit_before_unlog", abort();); if (cookie) tc_log->unlog(cookie, xid); |