Re: [PATCH] warnings cleanup: comparison of static array to null pointer
[
Date Prev][
Date Next]
[
Thread Prev][
Thread Next]
Re: [PATCH] warnings cleanup: comparison of static array to null pointer
- From: Patrick McLean <chutzpah [at] gentoo.org>
- To: Arthur de Jong <arthur [at] arthurdejong.org>
- Cc: nss-pam-ldapd-users [at] lists.arthurdejong.org
- Subject: Re: [PATCH] warnings cleanup: comparison of static array to null pointer
- Date: Wed, 11 Mar 2015 15:51:51 -0700
On Wed, 11 Mar 2015 23:40:01 +0100
Arthur de Jong <arthur@arthurdejong.org> wrote:
> On Wed, 2015-03-11 at 10:59 -0700, Patrick McLean wrote:
> > There are several places where a static length array in a struct is
> > compared to a null pointer. These comparisons will always be false,
> > since an array in a struct is not actually a pointer, so they can be
> > removed.
>
> Thanks for the patch. I think the comparisons came from when the code
> used cfg->binddb and cfg->bindpw.
That sounds likely. GCC didn't notice the warnings, I only noticed when
I compiled with clang.
>
> I'll look into the string formatting issue later. There are a few
> fixes in Git that are not in the latest release.
All these patches are created against the latest git (as of this
morning), rather than the latest release.
>
> Thanks,
>
--
To unsubscribe send an email to
nss-pam-ldapd-users-unsubscribe@lists.arthurdejong.org or see
http://lists.arthurdejong.org/nss-pam-ldapd-users/