On Thu, Nov 08, 2012 at 07:06:31PM -0600, Kim Phillips wrote: > On Thu, 8 Nov 2012 12:20:51 +0100 > Wolfgang Denk <w...@denx.de> wrote: > > > In message <1351553687-12469-14-git-send-email-kim.phill...@freescale.com> > > you wrote: > > > define Z_NULL to (void *)0 include/u-boot/zlib.h to get rid of most of > > > the NULL pointer warnings. > > ... > > > -#define Z_NULL 0 /* for initializing zalloc, zfree, opaque */ > > > +#define Z_NULL (void *)0 /* for initializing zalloc, zfree, opaque */ > > > > Don't we have to put parens around such an expression? > > I suppose. > > > > --- a/lib/zlib/adler32.c > > > +++ b/lib/zlib/adler32.c > > > @@ -54,10 +54,7 @@ > > > #endif > > > > > > /* > > > ========================================================================= > > > */ > > > -uLong ZEXPORT adler32(adler, buf, len) > > > - uLong adler; > > > - const Bytef *buf; > > > - uInt len; > > > +uLong ZEXPORT adler32(uLong adler, const Bytef *buf, uInt len) > > > > Hm... this code has been imported from another project. This > > modification makes updates (or even comparing what has changed in more > > recent versions) much mor difficult, or even impossible > > :-( > > my goal is to improve u-boot code quality by eliminating as much > sparse noise as possible - most boards use this code to decompress > kernels, so it's widely used. E.g., this patch removes 52 lines of > sparse output. But ok, we can revert this patch and turn off > checking for these files, in the form of an #ifndef __CHECKER__ at > the top, with an 'imported from another project' justification > comment. Would that be better?
My memory could be faulty here, but can't we rely on the kernel here? That'll give us sparse-clean zlib, or hints on how they're keeping it in sync. -- Tom
signature.asc
Description: Digital signature
_______________________________________________ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot