From b741f0b9926b62d8cb551550f4308a38706e74a5 Mon Sep 17 00:00:00 2001 From: Thomas Schoebel-Theuer Date: Tue, 29 Apr 2014 11:32:45 +0200 Subject: [PATCH] lib_log: quiet annoying false error message --- kernel/lib_log.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/kernel/lib_log.h b/kernel/lib_log.h index d1dbb5b4..f9e220db 100644 --- a/kernel/lib_log.h +++ b/kernel/lib_log.h @@ -183,9 +183,11 @@ int log_scan(void *buf, int len, loff_t file_pos, int file_offset, bool sloppy, DATA_GET(buf, offset, lh->l_written.tv_sec); DATA_GET(buf, offset, lh->l_written.tv_nsec); - if (unlikely(lh->l_seq_nr != *seq_nr + 1 && lh->l_seq_nr && *seq_nr)) { + if (unlikely(lh->l_seq_nr > *seq_nr + 1 && lh->l_seq_nr && *seq_nr)) { MARS_ERR(SCAN_TXT "record sequence number %u mismatch, expected was %u\n", SCAN_PAR, lh->l_seq_nr, *seq_nr + 1); return -EBADMSG; + } else if (unlikely(lh->l_seq_nr != *seq_nr + 1 && lh->l_seq_nr && *seq_nr)) { + MARS_WRN(SCAN_TXT "record sequence number %u mismatch, expected was %u\n", SCAN_PAR, lh->l_seq_nr, *seq_nr + 1); } *seq_nr = lh->l_seq_nr;