diff --git a/backend/pkg/messages/batch.go b/backend/pkg/messages/batch.go index f6f1e23ff..2b4bc0eea 100644 --- a/backend/pkg/messages/batch.go +++ b/backend/pkg/messages/batch.go @@ -98,7 +98,10 @@ func (i *iteratorImpl) Next() bool { i.version = m.Version isBatchMeta = true log.Printf("new batch version: %d", i.version) - + if i.version > 1 { + log.Printf("incorrect batch version, skip current batch") + return false + } case MsgBatchMeta: // Is not required to be present in batch since IOS doesn't have it (though we might change it) if i.index != 0 { // Might be several 0-0 BatchMeta in a row without an error though log.Printf("Batch Meta found at the end of the batch")