diff options
Diffstat (limited to 'sql')
-rw-r--r-- | sql/ha_ndbcluster.cc | 1 | ||||
-rw-r--r-- | sql/ha_partition.cc | 1 | ||||
-rw-r--r-- | sql/handler.h | 1 | ||||
-rw-r--r-- | sql/log.cc | 1 | ||||
-rw-r--r-- | sql/sql_show.cc | 17 |
5 files changed, 21 insertions, 0 deletions
diff --git a/sql/ha_ndbcluster.cc b/sql/ha_ndbcluster.cc index 0d57f3decec..d04220b8f92 100644 --- a/sql/ha_ndbcluster.cc +++ b/sql/ha_ndbcluster.cc @@ -10773,6 +10773,7 @@ mysql_declare_plugin(ndbcluster) ndbcluster_hton_name, "MySQL AB", "Clustered, fault-tolerant tables", + PLUGIN_LICENSE_GPL, ndbcluster_init, /* Plugin Init */ NULL, /* Plugin Deinit */ 0x0100 /* 1.0 */, diff --git a/sql/ha_partition.cc b/sql/ha_partition.cc index 0da0094d92e..deb3bedb203 100644 --- a/sql/ha_partition.cc +++ b/sql/ha_partition.cc @@ -5643,6 +5643,7 @@ mysql_declare_plugin(partition) "partition", "Mikael Ronstrom, MySQL AB", "Partition Storage Engine Helper", + PLUGIN_LICENSE_GPL, partition_initialize, /* Plugin Init */ NULL, /* Plugin Deinit */ 0x0100, /* 1.0 */ diff --git a/sql/handler.h b/sql/handler.h index e0827fec5c8..5e26d9c7b63 100644 --- a/sql/handler.h +++ b/sql/handler.h @@ -683,6 +683,7 @@ struct handlerton const char *wild, bool dir, List<char> *files); int (*table_exists_in_engine)(handlerton *hton, THD* thd, const char *db, const char *name); + uint32 license; /* Flag for Engine License */ }; diff --git a/sql/log.cc b/sql/log.cc index b718dc014b2..b63ec563baf 100644 --- a/sql/log.cc +++ b/sql/log.cc @@ -4689,6 +4689,7 @@ mysql_declare_plugin(binlog) "binlog", "MySQL AB", "This is a pseudo storage engine to represent the binlog in a transaction", + PLUGIN_LICENSE_GPL, binlog_init, /* Plugin Init */ NULL, /* Plugin Deinit */ 0x0100 /* 1.0 */, diff --git a/sql/sql_show.cc b/sql/sql_show.cc index 45865adddcd..599bca6cbe1 100644 --- a/sql/sql_show.cc +++ b/sql/sql_show.cc @@ -211,6 +211,22 @@ static my_bool show_plugins(THD *thd, st_plugin_int *plugin, else table->field[8]->set_null(); + switch (plug->license) { + case PLUGIN_LICENSE_GPL: + table->field[9]->store(PLUGIN_LICENSE_GPL_STRING, + strlen(PLUGIN_LICENSE_GPL_STRING), cs); + break; + case PLUGIN_LICENSE_BSD: + table->field[9]->store(PLUGIN_LICENSE_BSD_STRING, + strlen(PLUGIN_LICENSE_BSD_STRING), cs); + break; + default: + table->field[9]->store(PLUGIN_LICENSE_PROPRIETARY_STRING, + strlen(PLUGIN_LICENSE_PROPRIETARY_STRING), cs); + break; + } + table->field[9]->set_notnull(); + return schema_table_store_record(thd, table); } @@ -5579,6 +5595,7 @@ ST_FIELD_INFO plugin_fields_info[]= {"PLUGIN_LIBRARY_VERSION", 20, MYSQL_TYPE_STRING, 0, 1, 0}, {"PLUGIN_AUTHOR", NAME_LEN, MYSQL_TYPE_STRING, 0, 1, 0}, {"PLUGIN_DESCRIPTION", 65535, MYSQL_TYPE_STRING, 0, 1, 0}, + {"PLUGIN_LICENSE", 80, MYSQL_TYPE_STRING, 0, 1, "License"}, {0, 0, MYSQL_TYPE_STRING, 0, 0, 0} }; |