Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
MariaDB
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
MariaDB
Commits
e843297d
Commit
e843297d
authored
May 08, 2011
by
Michael Widenius
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixed compiler warnings
parent
183d6b70
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
11 additions
and
11 deletions
+11
-11
sql/log.cc
sql/log.cc
+3
-3
sql/log_event.cc
sql/log_event.cc
+6
-7
sql/mysql_priv.h
sql/mysql_priv.h
+1
-0
sql/rpl_utility.cc
sql/rpl_utility.cc
+1
-1
No files found.
sql/log.cc
View file @
e843297d
...
...
@@ -2815,9 +2815,9 @@ bool MYSQL_BIN_LOG::open(const char *log_name,
relay_log_checksum_alg
:
/* otherwise use slave's local preference of RL events verification */
(
opt_slave_sql_verify_checksum
==
0
)
?
(
uint8
)
BINLOG_CHECKSUM_ALG_OFF
:
binlog_checksum_options
)
:
(
uint8
)
BINLOG_CHECKSUM_ALG_OFF
:
(
uint8
)
binlog_checksum_options
)
:
/* binlog */
binlog_checksum_options
;
(
uint8
)
binlog_checksum_options
;
DBUG_ASSERT
(
s
.
checksum_alg
!=
BINLOG_CHECKSUM_ALG_UNDEF
);
if
(
!
s
.
is_valid
())
goto
err
;
...
...
@@ -5699,7 +5699,7 @@ void MYSQL_BIN_LOG::close(uint exiting)
Stop_log_event
s
;
// the checksumming rule for relay-log case is similar to Rotate
s
.
checksum_alg
=
is_relay_log
?
relay_log_checksum_alg
:
binlog_checksum_options
;
(
uint8
)
relay_log_checksum_alg
:
(
uint8
)
binlog_checksum_options
;
DBUG_ASSERT
(
!
is_relay_log
||
relay_log_checksum_alg
!=
BINLOG_CHECKSUM_ALG_UNDEF
);
s
.
pre_55_writing_direct
();
...
...
sql/log_event.cc
View file @
e843297d
...
...
@@ -955,18 +955,17 @@ my_bool Log_event::need_checksum()
{
DBUG_ENTER
(
"Log_event::need_checksum"
);
my_bool
ret
;
extern
ulong
binlog_checksum_options
;
/*
few callers of Log_event::write
(incl FD::write, FD constructing code on the slave side, Rotate relay log
and Stop event)
provides their checksum alg preference through Log_event::checksum_alg.
*/
ret
=
(
checksum_alg
!=
BINLOG_CHECKSUM_ALG_UNDEF
)
?
(
checksum_alg
!=
BINLOG_CHECKSUM_ALG_OFF
)
:
((
binlog_checksum_options
!=
BINLOG_CHECKSUM_ALG_OFF
)
&&
(
cache_type
==
Log_event
::
EVENT_NO_CACHE
))
?
binlog_checksum_options
:
FALSE
;
ret
=
(
(
checksum_alg
!=
BINLOG_CHECKSUM_ALG_UNDEF
)
?
(
checksum_alg
!=
BINLOG_CHECKSUM_ALG_OFF
)
:
((
binlog_checksum_options
!=
BINLOG_CHECKSUM_ALG_OFF
)
&&
(
cache_type
==
Log_event
::
EVENT_NO_CACHE
))
?
test
(
binlog_checksum_options
)
:
FALSE
)
;
/*
FD calls the methods before data_written has been calculated.
...
...
@@ -980,7 +979,7 @@ my_bool Log_event::need_checksum()
if
(
checksum_alg
==
BINLOG_CHECKSUM_ALG_UNDEF
)
checksum_alg
=
ret
?
// calculated value stored
binlog_checksum_options
:
(
uint8
)
BINLOG_CHECKSUM_ALG_OFF
;
(
uint8
)
binlog_checksum_options
:
(
uint8
)
BINLOG_CHECKSUM_ALG_OFF
;
DBUG_ASSERT
(
!
ret
||
((
checksum_alg
==
binlog_checksum_options
||
...
...
sql/mysql_priv.h
View file @
e843297d
...
...
@@ -2067,6 +2067,7 @@ extern ulong MYSQL_PLUGIN_IMPORT specialflag;
#ifdef MYSQL_SERVER
extern
ulong
current_pid
;
extern
ulong
expire_logs_days
,
sync_binlog_period
,
sync_binlog_counter
;
extern
ulong
binlog_checksum_options
;
extern
ulong
opt_tc_log_size
,
tc_log_max_pages_used
,
tc_log_page_size
;
extern
ulong
tc_log_page_waits
;
extern
my_bool
relay_log_purge
,
opt_innodb_safe_binlog
,
opt_innodb
;
...
...
sql/rpl_utility.cc
View file @
e843297d
...
...
@@ -279,7 +279,7 @@ bool event_checksum_test(uchar *event_buf, ulong event_len, uint8 alg)
{
/* restoring the orig value of flags of FD */
DBUG_ASSERT
(
event_buf
[
EVENT_TYPE_OFFSET
]
==
FORMAT_DESCRIPTION_EVENT
);
event_buf
[
FLAGS_OFFSET
]
=
flags
;
event_buf
[
FLAGS_OFFSET
]
=
(
uchar
)
flags
;
}
res
=
!
(
computed
==
incoming
);
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment