nwrap: Don't fail if we want to add an existing entry
authorAndreas Schneider <asn@samba.org>
Tue, 24 Nov 2015 16:32:47 +0000 (17:32 +0100)
committerAndreas Schneider <asn@samba.org>
Tue, 24 Nov 2015 16:32:47 +0000 (17:32 +0100)
Signed-off-by: Andreas Schneider <asn@samba.org>
src/nss_wrapper.c

index a080b808f54b112932f6f17a684f7560eb60bb2e..8c7128cc314210c7516ae84fd8b852550cdb0ddd 100644 (file)
@@ -2627,7 +2627,11 @@ static bool nwrap_ed_inventarize_add_to_existing(struct nwrap_entdata *const ed,
        }
 
        if (cursor->ed == ed) {
-               return false;
+               /*
+                * If the entry already exists, we should simply should return
+                * that everything is fine.
+                */
+               return true;
        }
 
        el_new = nwrap_entlist_init(ed);