Binlog: add an assert
GitOrigin-RevId: 84ac88b0e83917d16d0f7a7e35b9abd486698f3d
This commit is contained in:
parent
4621bdaff3
commit
f51c0602e6
@ -20,6 +20,8 @@ class BinlogEventsProcessor {
|
|||||||
template <class CallbackT>
|
template <class CallbackT>
|
||||||
void for_each(CallbackT &&callback) {
|
void for_each(CallbackT &&callback) {
|
||||||
for (size_t i = 0; i < ids_.size(); i++) {
|
for (size_t i = 0; i < ids_.size(); i++) {
|
||||||
|
CHECK(i == 0 || ids_[i - 1] < ids_[i]) << ids_[i - 1] << " " << events_[i - 1].public_to_string() << " "
|
||||||
|
<< ids_[i] << " " << events_[i].public_to_string();
|
||||||
if ((ids_[i] & 1) == 0) {
|
if ((ids_[i] & 1) == 0) {
|
||||||
callback(events_[i]);
|
callback(events_[i]);
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user