Commit 9789c943 authored by unknown's avatar unknown

MWL#180: Merge bugfix from 5.2 to 5.3 codebase + really fix version from which...

MWL#180: Merge bugfix from 5.2 to 5.3 codebase + really fix version from which mariadb supports binlog checksums.
parents 32d88236 4337aa74
...@@ -27,13 +27,22 @@ show binary logs; ...@@ -27,13 +27,22 @@ show binary logs;
Log_name File_size Log_name File_size
master-bin.000001 # master-bin.000001 #
set @@global.binlog_checksum = NONE; set @@global.binlog_checksum = NONE;
select @@global.binlog_checksum;
@@global.binlog_checksum
NONE
*** must be rotations seen *** *** must be rotations seen ***
show binary logs; show binary logs;
Log_name File_size Log_name File_size
master-bin.000001 # master-bin.000001 #
master-bin.000002 # master-bin.000002 #
set @@global.binlog_checksum = default; set @@global.binlog_checksum = default;
select @@global.binlog_checksum;
@@global.binlog_checksum
NONE
set @@global.binlog_checksum = CRC32; set @@global.binlog_checksum = CRC32;
select @@global.binlog_checksum;
@@global.binlog_checksum
CRC32
set @@global.binlog_checksum = CRC32; set @@global.binlog_checksum = CRC32;
set @@global.master_verify_checksum = 0; set @@global.master_verify_checksum = 0;
set @@global.master_verify_checksum = default; set @@global.master_verify_checksum = default;
......
...@@ -40,13 +40,16 @@ connection master; ...@@ -40,13 +40,16 @@ connection master;
source include/show_binary_logs.inc; source include/show_binary_logs.inc;
set @@global.binlog_checksum = NONE; set @@global.binlog_checksum = NONE;
select @@global.binlog_checksum;
--echo *** must be rotations seen *** --echo *** must be rotations seen ***
source include/show_binary_logs.inc; source include/show_binary_logs.inc;
set @@global.binlog_checksum = default; set @@global.binlog_checksum = default;
select @@global.binlog_checksum;
# testing lack of side-effects in non-effective update of binlog_checksum: # testing lack of side-effects in non-effective update of binlog_checksum:
set @@global.binlog_checksum = CRC32; set @@global.binlog_checksum = CRC32;
select @@global.binlog_checksum;
set @@global.binlog_checksum = CRC32; set @@global.binlog_checksum = CRC32;
set @@global.master_verify_checksum = 0; set @@global.master_verify_checksum = 0;
......
...@@ -7016,7 +7016,7 @@ static void ...@@ -7016,7 +7016,7 @@ static void
binlog_checksum_update(MYSQL_THD thd, struct st_mysql_sys_var *var, binlog_checksum_update(MYSQL_THD thd, struct st_mysql_sys_var *var,
void *var_ptr, const void *save) void *var_ptr, const void *save)
{ {
ulong value= *((ulong *)var_ptr); ulong value= *((ulong *)save);
pthread_mutex_lock(mysql_bin_log.get_log_lock()); pthread_mutex_lock(mysql_bin_log.get_log_lock());
if(mysql_bin_log.is_open()) if(mysql_bin_log.is_open())
......
...@@ -89,7 +89,7 @@ const ulong checksum_version_product_mysql= ...@@ -89,7 +89,7 @@ const ulong checksum_version_product_mysql=
(checksum_version_split_mysql[0] * 256 + (checksum_version_split_mysql[0] * 256 +
checksum_version_split_mysql[1]) * 256 + checksum_version_split_mysql[1]) * 256 +
checksum_version_split_mysql[2]; checksum_version_split_mysql[2];
const uchar checksum_version_split_mariadb[3]= {5, 2, 5}; const uchar checksum_version_split_mariadb[3]= {5, 3, 0};
const ulong checksum_version_product_mariadb= const ulong checksum_version_product_mariadb=
(checksum_version_split_mariadb[0] * 256 + (checksum_version_split_mariadb[0] * 256 +
checksum_version_split_mariadb[1]) * 256 + checksum_version_split_mariadb[1]) * 256 +
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment