From 85cf1c27bcb9b38831a3cb4267f9fc814396f7be Mon Sep 17 00:00:00 2001 From: Timo Sirainen Date: Thu, 5 Oct 2017 13:17:59 +0300 Subject: [PATCH] mbox: Remove unnecessary check from assert - move_diff is always negative here --- src/lib-storage/index/mbox/mbox-sync.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/lib-storage/index/mbox/mbox-sync.c b/src/lib-storage/index/mbox/mbox-sync.c index e5c8fef3db..fd09d2133c 100644 --- a/src/lib-storage/index/mbox/mbox-sync.c +++ b/src/lib-storage/index/mbox/mbox-sync.c @@ -673,8 +673,7 @@ static int mbox_sync_handle_header(struct mbox_sync_mail_context *mail_ctx) if (ret > 0) { /* rewrite successful, write From-line to new location */ - i_assert(move_diff > 0 || - (off_t)mail_ctx->mail.from_offset >= + i_assert((off_t)mail_ctx->mail.from_offset >= -move_diff); mail_ctx->mail.from_offset += move_diff; mail_ctx->mail.offset += move_diff; -- 2.47.3