From: Richard Levitte Date: Fri, 4 Oct 2002 13:04:37 +0000 (+0000) Subject: If we're loading libz dynamically, and COMP_zlib() is called more than once, X-Git-Tag: OpenSSL_0_9_7-beta4~140^2~29 X-Git-Url: https://git.openssl.org/?p=openssl.git;a=commitdiff_plain;h=e984b2af64e7bda295edb5c963e1b8932112230e;hp=70e96dcf5930c14f25f64b99f7fc30fdc2c24239 If we're loading libz dynamically, and COMP_zlib() is called more than once, only the first call would provide the correct result. PR: 277 --- diff --git a/crypto/comp/c_zlib.c b/crypto/comp/c_zlib.c index cd2f8a491b..8c0876151a 100644 --- a/crypto/comp/c_zlib.c +++ b/crypto/comp/c_zlib.c @@ -208,11 +208,11 @@ COMP_METHOD *COMP_zlib(void) = (inflateInit__ft) DSO_bind_func(zlib_dso, "inflateInit_"); zlib_loaded++; - meth = &zlib_method; } } -#elif defined(ZLIB) +#endif +#if defined(ZLIB) || defined(ZLIB_SHARED) meth = &zlib_method; #endif