From 2931e237d609968086a560eb2f9c7beaf320e44b Mon Sep 17 00:00:00 2001 From: Kostya Shishkov Date: Thu, 23 Feb 2023 17:53:43 +0100 Subject: [PATCH] cinepakenc: fix detection of codebook changed part --- nihav-commonfmt/src/codecs/cinepakenc.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/nihav-commonfmt/src/codecs/cinepakenc.rs b/nihav-commonfmt/src/codecs/cinepakenc.rs index 4729cd6..28f9c93 100644 --- a/nihav-commonfmt/src/codecs/cinepakenc.rs +++ b/nihav-commonfmt/src/codecs/cinepakenc.rs @@ -391,7 +391,7 @@ impl CinepakEncoder { } } else { let mut end = 256; - for (i, (ncw, ocw)) in new_cb.iter().rev().zip(old_cb.iter().rev()).enumerate() { + for (i, (ncw, ocw)) in new_cb.iter().zip(old_cb.iter()).enumerate().rev() { if ncw == ocw { end = i; } else { -- 2.39.5