diff --git a/src/node_zlib.cc b/src/node_zlib.cc index 4495eb2bcad255..85fc4927a03ca9 100644 --- a/src/node_zlib.cc +++ b/src/node_zlib.cc @@ -562,6 +562,7 @@ class ZCtx : public AsyncWrap { delete[] dictionary; ctx->dictionary_ = nullptr; } + ctx->mode_ = NONE; ctx->env()->ThrowError("Init error"); } }