[Zlib-devel] Fwd: zlib app crashes on release, not debug in Visual C++

Mark Adler madler at madler.net
Tue Aug 3 09:21:52 EDT 2010


Perhaps someone can respond to this.  Thanks.

Mark


Begin forwarded message:
> From: Tilman Hausherr <tilman at snafu.de>
> Date: August 3, 2010 4:31:41 AM PDT
> To: zlib at gzip.org
> Cc: Tilman Hausherr <tilman at snafu.de>
> Subject: zlib app crashes on release, not debug in Visual C++
> 
> Hello,
> 
> I've built a mini console application with Visual C++ 6 that uses the
> zlib1.dll (1.2.5) http://zlib.net/zlib125-dll.zip that does nothing
> except calling zlibVersion(). It crashes in release mode with an access
> violation, but not in debug mode. I can run it in release mode if I
> enable the /debug linker flag.
> 
> It gets even weirder:
> I have found an older zdll.lib at
> http://www.codeproject.com/KB/files/PdfDigiPad.aspx that is from
> 24.5.2005, and has a size of 11KB (the current one has a size of 39KB).
> With the old lib it works in debug *and* release mode...
> 
> It also works if I use
> http://www.winimage.com/zLibDll/zlib125dll.zip
> and then use zlibwapi.lib with ZLIB_WINAPI defined.
> 
> I did RTFM and found no clue :-( 
> What's my mistake?
> 
> Tilman





More information about the Zlib-devel mailing list