lists.arthurdejong.org
RSS feed

nss-pam-ldapd commit: r1907 - nss-pam-ldapd-0.8/nslcd

[Date Prev][Date Next] [Thread Prev][Thread Next]

nss-pam-ldapd commit: r1907 - nss-pam-ldapd-0.8/nslcd



Author: arthur
Date: Fri Jan 11 13:21:15 2013
New Revision: 1907
URL: http://arthurdejong.org/viewvc/nss-pam-ldapd?revision=1907&view=revision

Log:
correctly handle the case where the gid option is before the uid option in the 
configuration (fixes r1723)

Modified:
   nss-pam-ldapd-0.8/nslcd/cfg.c

Modified: nss-pam-ldapd-0.8/nslcd/cfg.c
==============================================================================
--- nss-pam-ldapd-0.8/nslcd/cfg.c       Thu Jan 10 22:19:16 2013        (r1906)
+++ nss-pam-ldapd-0.8/nslcd/cfg.c       Fri Jan 11 13:21:15 2013        (r1907)
@@ -459,7 +459,7 @@
   {
     /* get the name and gid from the passwd database */
     pwent=getpwuid(*var);
-    if ((gid!=NULL)&&(*gid!=NOGID))
+    if ((gid!=NULL)&&(*gid==NOGID))
       *gid=pwent->pw_gid;
     if (str!=NULL)
       *str=strdup(pwent->pw_name);
@@ -470,7 +470,7 @@
   if (pwent!=NULL)
   {
     *var=pwent->pw_uid;
-    if ((gid!=NULL)&&(*gid!=NOGID))
+    if ((gid!=NULL)&&(*gid==NOGID))
       *gid=pwent->pw_gid;
     if (str!=NULL)
       *str=strdup(token);
-- 
To unsubscribe send an email to
nss-pam-ldapd-commits-unsubscribe@lists.arthurdejong.org or see
http://lists.arthurdejong.org/nss-pam-ldapd-commits/