From edc7f5a7ce7560c429db97b6d1675b3b6e7e792c Mon Sep 17 00:00:00 2001 From: Con Kolivas Date: Mon, 9 Mar 2015 21:10:48 +1100 Subject: [PATCH] Don't check for failure condition that can no longer occur --- rzip.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/rzip.c b/rzip.c index 9468952..360ea84 100644 --- a/rzip.c +++ b/rzip.c @@ -657,11 +657,8 @@ static inline bool hash_search(rzip_control *control, struct rzip_state *st, current.p = p; current.ofs = 0; - if (likely(end > 0)) { + if (likely(end > 0)) t = control->full_tag(control, st, p); - if (unlikely(t == -1)) - return false; - } while (p < end) { i64 reverse, mlen, offset; @@ -724,8 +721,6 @@ static inline bool hash_search(rzip_control *control, struct rzip_state *st, current.p = p = st->last_match; current.len = 0; t = control->full_tag(control, st, p); - if (unlikely(t == -1)) - return false; } if (p > cksum_limit) {