diff --git a/lib/zlib_inflate/inftrees.c b/lib/zlib_inflate/inftrees.c
index c5f66fbb0dd0b427a355b76c378786705b3ec6bd..874950ec48582e4b85c48ba6f1be7cb1f04cc659 100644
--- a/lib/zlib_inflate/inftrees.c
+++ b/lib/zlib_inflate/inftrees.c
@@ -141,7 +141,7 @@ static int huft_build(
   {
     *t = NULL;
     *m = 0;
-    return Z_DATA_ERROR;
+    return Z_OK;
   }