diff options
author | unknown <brian@zim.(none)> | 2006-10-31 20:10:32 -0800 |
---|---|---|
committer | unknown <brian@zim.(none)> | 2006-10-31 20:10:32 -0800 |
commit | b014bd22e40c87fdb7d17772edaa990ccad554b3 (patch) | |
tree | 4f858c6e222d7e18d7d5f41edcc2dca83b4185cd /sql/handler.cc | |
parent | 78fd640b8b5385bb00cab65d880ef8d4c4202732 (diff) | |
download | mariadb-git-b014bd22e40c87fdb7d17772edaa990ccad554b3.tar.gz |
Adding in an ha_end() call. This is the first part of the patch I and Monty have agreed on. In the future engines will have the option of shutting down more quickly via the panic call, or just shutting down during the unloading of a plugin.
sql/handler.cc:
Adding ha_end
sql/handler.h:
Function declaration for ha_end()
sql/mysqld.cc:
Adding ha_end call.
Diffstat (limited to 'sql/handler.cc')
-rw-r--r-- | sql/handler.cc | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/sql/handler.cc b/sql/handler.cc index 4beef164ee1..01f73347397 100644 --- a/sql/handler.cc +++ b/sql/handler.cc @@ -510,6 +510,23 @@ int ha_init() DBUG_RETURN(error); } +int ha_end() +{ + int error= 0; + DBUG_ENTER("ha_end"); + + + /* + This should be eventualy based on the graceful shutdown flag. + So if flag is equal to HA_PANIC_CLOSE, the deallocate + the errors. + */ + if (ha_finish_errors()) + error= 1; + + DBUG_RETURN(error); +} + static my_bool dropdb_handlerton(THD *unused1, st_plugin_int *plugin, void *path) { |