diff options
author | unknown <monty@mysql.com/nosik.monty.fi> | 2008-02-11 20:55:04 +0200 |
---|---|---|
committer | unknown <monty@mysql.com/nosik.monty.fi> | 2008-02-11 20:55:04 +0200 |
commit | 315d7b3419fda7c4987c8f2c51d500ed2259899c (patch) | |
tree | 7144a209ad4df9e8ef57404604d7eb6a56047332 /sql/handler.h | |
parent | 5fa560e995a01c87bd7d20264c85c2ec66c19748 (diff) | |
download | mariadb-git-315d7b3419fda7c4987c8f2c51d500ed2259899c.tar.gz |
Add warning of TRANSACTIONAL=1 is used with handler that doesn't support it
Added hton_name() and handler->engine_name() and use these when appropriate
KNOWN_BUGS.txt:
Added some of the known bugs
mysql-test/r/maria.result:
Added test for TRANSACTIONAL=1
mysql-test/r/myisam.result:
Added test for TRANSACTIONAL=1
mysql-test/t/maria.test:
Added test for TRANSACTIONAL=1
mysql-test/t/myisam.test:
Added test for TRANSACTIONAL=1
sql/handler.cc:
ha_resolve_storage_engine_name() -> hton_name()
sql/handler.h:
Added hton_name() and handler->engine_name()
sql/set_var.cc:
Use hton_name()
sql/sql_table.cc:
Add warning of TRANSACTIONAL=1 is used with handler that doesn't support it
Indentation fixes
ha_resolve_storage_engine_name() -> hton_name()
sql/sql_tablespace.cc:
ha_resolve_storage_engine_name() -> hton_name()
Indentation fixes
sql/sql_yacc.yy:
ha_resolve_storage_engine_name() -> hton_name()
sql/unireg.cc:
ha_resolve_storage_engine_name() -> hton_name()
Indentation fixes
Diffstat (limited to 'sql/handler.h')
-rw-r--r-- | sql/handler.h | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/sql/handler.h b/sql/handler.h index 8e3073eb6ba..a4ef34d5f2d 100644 --- a/sql/handler.h +++ b/sql/handler.h @@ -709,6 +709,12 @@ struct handlerton }; +inline LEX_STRING *hton_name(const handlerton *hton) +{ + return &(hton2plugin[hton->slot]->name); +} + + /* Possible flags of a handlerton (there can be 32 of them) */ #define HTON_NO_FLAGS 0 #define HTON_CLOSE_CURSORS_AT_COMMIT (1 << 0) @@ -1629,6 +1635,8 @@ public: */ virtual void use_hidden_primary_key(); + LEX_STRING *engine_name() { return hton_name(ht); } + protected: /* Service methods for use by storage engines. */ void ha_statistic_increment(ulong SSV::*offset) const; @@ -1644,6 +1652,7 @@ protected: */ virtual int rename_table(const char *from, const char *to); virtual int delete_table(const char *name); + private: /* Low-level primitives for storage engines. These should be @@ -1848,7 +1857,7 @@ static inline enum legacy_db_type ha_legacy_type(const handlerton *db_type) static inline const char *ha_resolve_storage_engine_name(const handlerton *db_type) { - return db_type == NULL ? "UNKNOWN" : hton2plugin[db_type->slot]->name.str; + return db_type == NULL ? "UNKNOWN" : hton_name(db_type)->str; } static inline bool ha_check_storage_engine_flag(const handlerton *db_type, uint32 flag) |