summaryrefslogtreecommitdiff
path: root/sql/set_var.h
diff options
context:
space:
mode:
authormonty@mysql.com <>2004-03-06 10:43:35 +0200
committermonty@mysql.com <>2004-03-06 10:43:35 +0200
commitef971bb6048db5fc99cddaff1673c8a001705111 (patch)
tree1cf950921cf3e82b17e59b8516f0db0627a429a2 /sql/set_var.h
parentb9c4ee353df8eb5257202fac419298b469e624e3 (diff)
downloadmariadb-git-ef971bb6048db5fc99cddaff1673c8a001705111.tar.gz
Ensure that one can't from the command line set a variable too small. (Bug #2710)
Allow one to force lower_case_table_names to 0, even if the file system is case insensitive. This fixes some issues on Mac OS X (Bug #2994) Added variables "lower_case_file_system", "version_compile_os" and "license"
Diffstat (limited to 'sql/set_var.h')
-rw-r--r--sql/set_var.h25
1 files changed, 25 insertions, 0 deletions
diff --git a/sql/set_var.h b/sql/set_var.h
index e22c55276a7..08e3f20fdb4 100644
--- a/sql/set_var.h
+++ b/sql/set_var.h
@@ -156,6 +156,31 @@ public:
};
+class sys_var_const_str :public sys_var
+{
+public:
+ char *value; // Pointer to const value
+ sys_var_const_str(const char *name_arg, const char *value_arg)
+ :sys_var(name_arg), value((char*) value_arg)
+ {}
+ bool check(THD *thd, set_var *var)
+ {
+ return 1;
+ }
+ bool update(THD *thd, set_var *var)
+ {
+ return 1;
+ }
+ SHOW_TYPE type() { return SHOW_CHAR; }
+ byte *value_ptr(THD *thd, enum_var_type type) { return (byte*) value; }
+ bool check_update_type(Item_result type)
+ {
+ return 1;
+ }
+ bool check_default(enum_var_type type) { return 1; }
+};
+
+
class sys_var_enum :public sys_var
{
uint *value;