Skip to contentSkip to conversation

lib/inflate.c: remove dead code

PATCH In review Jan Beulich 2 participants 2 messages Mar 25, 2025

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 lib/inflate.c: remove dead code

From: Ariel Otilibili <[email protected]>

This is a follow up from a discussion in Xen:

The if-statement tests that res is non-zero; meaning the case zero is never reached.

Origin: git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git 41c761dede6e

xen/common/gzip/inflate.c +0 -2
@@ -1164,8 +1164,6 @@ static int __init gunzip(struct gunzip_s
     if ( (res = inflate(s)) )
     {
         switch (res) {
-        case 0:
-            break;
         case 1:
             error("invalid compressed format (err=1)");
             break;
Acked-by on v1 1/1
#1 lore raw
Quoted 7 lines · Jan Beulich

From: Ariel Otilibili <[email protected]>

This is a follow up from a discussion in Xen:

The if-statement tests that res is non-zero; meaning the case zero is never reached.

Quoted 8 lines

Origin: git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git 41c761dede6e