Closed Bug 431950 Opened 14 years ago Closed 13 years ago
disable scary-but-harmless zlib trace warnings in debug builds
While using a debug build, you'll see occasional console messages like: bit length overflow code 4 bits 6->7 These are a side effect of bug 389273... We reencode favicons as PNGs, the PNG encoder uses zlib, and zlib barfs up messages like this now and then. The messages are harmless, but can be a bit confusing to people watching the console while testing their own changes. This patch disables DEBUG mode in zlib unless ZLIB_DEBUG is also defined. zlib is extremely stable, so there's not much value in having it's DEBUG mode just because Mozilla might be in DEBUG too.
Comment on attachment 319096 [details] [diff] [review] Patch v.1 are there other mozilla ifdefs in this code? i'd really rather not change zlib if we can avoid it.
Yeah, there seem to be some other mozilla-specific changes to zlib since it was upgraded to 1.2.3 long ago (a #include of mozzconfig.h, something for OS/2, something for VC9). So the "have to merge Mozilla changes with Zlib changes" threshold has already been crossed...
Comment on attachment 319096 [details] [diff] [review] Patch v.1 I don't believe this needs sr under the current rules. Can you add this (and any other undocumented moz changes, like the OS/2 and VC9 stuff you mentioned) to Changelog.moz? r=bholley with that change.
Updated patch, added note to ChangeLog.moz.
Assignee: nobody → dolske
Attachment #319096 - Attachment is obsolete: true
Status: NEW → RESOLVED
Closed: 13 years ago
Resolution: --- → FIXED
Target Milestone: mozilla1.9 → mozilla1.9.3a1
dolske: I solved this problem in NSS's zlib by compiling it with -Dverbose=-1: http://bonsai.mozilla.org/cvsblame.cgi?file=mozilla/security/nss/lib/zlib/manifest.mn&rev=1.9&mark=64-66#64 Although the 'verbose' macro seems undocumented, I believe defining 'verbose' as a negative number is the proper way to turn off zlib's "Trace" macro in DEBUG build. See http://bonsai.mozilla.org/cvsblame.cgi?file=mozilla/security/nss/lib/zlib/zutil.c&rev=1.6&mark=115,117-120#115 http://bonsai.mozilla.org/cvsblame.cgi?file=mozilla/security/nss/lib/zlib/zutil.h&rev=1.8&mark=239,244#238
You need to log in before you can comment on or make changes to this bug.