Re: Bug in 0.7.13 nslcd (Still present in trunk)
[
Date Prev][
Date Next]
[
Thread Prev][
Thread Next]
Re: Bug in 0.7.13 nslcd (Still present in trunk)
- From: Arthur de Jong <arthur [at] arthurdejong.org>
- To: nss-pam-ldapd-users [at] lists.arthurdejong.org
- Subject: Re: Bug in 0.7.13 nslcd (Still present in trunk)
- Date: Sat, 21 May 2011 16:54:42 +0200
On Fri, 2011-05-20 at 13:13 +1000, Tim wrote:
> I believe I've found a bug in nslcd.
Thanks for reporting this, finding the bug and providing the fix.
> The simple fix is to add in a continue statement.
> So from line 1449
>
> /* ensure that we found an equals sign now */
> if (exploded_rdn[i][j]!='=')
> j++;
>
> Becomes
> /* ensure that we found an equals sign now */
> if (exploded_rdn[i][j]!='=')
> continue;
> j++;
From the indenting it seems that this continue statement was meant to be
there. This bug has been there at least since February 2007.
> Apologies for not producing a proper diff. If you really need one for
> this one liner, then let me know and I'll checkout both 0.7.13 and
> 0.8.13 and patch against them.
This is fine. I've applied your fix to be in both the next 0.7 and 0.8
releases.
> btw, I was trying to debug with gdb, but I think maybe nslcd has
> threads because it was proving very difficult to debug with gdb. What
> is your normal method of debugging?
nslcd indeed uses threads so using gdb can be a little hard. I never
really get the hang of using gdb so I generally insert debug statements
and do code inspection. You can debug threads in gdb (forget how though)
and you can reduce the complexity by only starting one worker thread in
nslcd (theads keyword in nslcd.conf).
Anyway, thanks again for spotting this and providing a fix.
--
-- arthur - arthur@arthurdejong.org - http://arthurdejong.org --
--
To unsubscribe send an email to
nss-pam-ldapd-users-unsubscribe@lists.arthurdejong.org or see
http://lists.arthurdejong.org/nss-pam-ldapd-users