1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-29 05:21:33 +03:00

bugs in sys_var::val_* code

1. @@boolean_var differs from SHOW VARIABLES
2. @@str_var ignored variable charset (which is wrong
   for path variables that use filesystem charset)
3. @@signed_int_var in the string context was printed
   as unsigned
This commit is contained in:
Sergei Golubchik
2014-09-03 20:05:51 +02:00
parent b969a69021
commit a7b2c95a40
4 changed files with 25 additions and 15 deletions

View File

@ -211,10 +211,12 @@ public:
str_charset=cs;
}
bool set_int(longlong num, bool unsigned_flag, CHARSET_INFO *cs);
bool set(longlong num, CHARSET_INFO *cs)
{ return set_int(num, false, cs); }
bool set(ulonglong num, CHARSET_INFO *cs)
{ return set_int((longlong)num, true, cs); }
bool set(int num, CHARSET_INFO *cs) { return set_int(num, false, cs); }
bool set(uint num, CHARSET_INFO *cs) { return set_int(num, true, cs); }
bool set(long num, CHARSET_INFO *cs) { return set_int(num, false, cs); }
bool set(ulong num, CHARSET_INFO *cs) { return set_int(num, true, cs); }
bool set(longlong num, CHARSET_INFO *cs) { return set_int(num, false, cs); }
bool set(ulonglong num, CHARSET_INFO *cs) { return set_int((longlong)num, true, cs); }
bool set_real(double num,uint decimals, CHARSET_INFO *cs);
/* Move handling of buffer from some other object to String */