summaryrefslogtreecommitdiff
path: root/lib/nss_wrapper
diff options
context:
space:
mode:
authorAndreas Schneider <asn@samba.org>2015-11-24 17:32:47 +0100
committerMichael Adam <obnox@samba.org>2016-01-11 12:25:32 +0100
commit19b2dcbeb230adc956d023dfea0d1aad9bb2a1ca (patch)
treea4c2c1fa17b295d2b351d1056866107a735fe761 /lib/nss_wrapper
parent9b7902090d2d594d25d517759dba78ced0f9124b (diff)
downloadsamba-19b2dcbeb230adc956d023dfea0d1aad9bb2a1ca.tar.gz
nwrap: Don't fail if we want to add an existing entry
Pair-Programmed-With: Michael Adam <obnox@samba.org> Signed-off-by: Andreas Schneider <asn@samba.org> Signed-off-by: Michael Adam <obnox@samba.org>
Diffstat (limited to 'lib/nss_wrapper')
-rw-r--r--lib/nss_wrapper/nss_wrapper.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/lib/nss_wrapper/nss_wrapper.c b/lib/nss_wrapper/nss_wrapper.c
index a080b808f54..f48b9cc7e8d 100644
--- a/lib/nss_wrapper/nss_wrapper.c
+++ b/lib/nss_wrapper/nss_wrapper.c
@@ -2622,12 +2622,14 @@ static bool nwrap_ed_inventarize_add_to_existing(struct nwrap_entdata *const ed,
for (cursor = el; cursor->next != NULL; cursor = cursor->next)
{
if (cursor->ed == ed) {
- return false;
+ /* The entry already exists in this list. */
+ return true;
}
}
if (cursor->ed == ed) {
- return false;
+ /* The entry already exists in this list. */
+ return true;
}
el_new = nwrap_entlist_init(ed);