summaryrefslogtreecommitdiff
path: root/src/providers/ldap/sdap_async_users.c
diff options
context:
space:
mode:
authorJan Zeleny <jzeleny@redhat.com>2012-02-21 07:18:12 -0500
committerStephen Gallagher <sgallagh@redhat.com>2012-02-24 14:58:26 -0500
commit3ff729e6c8a371e7a52914772816c39ca73c50a9 (patch)
tree03d5c089a7b0c88dcbf79b3011f7a886d13bcfc2 /src/providers/ldap/sdap_async_users.c
parent277a0187190fd417696590b303a5d7a204ed0555 (diff)
downloadsssd-3ff729e6c8a371e7a52914772816c39ca73c50a9.tar.gz
sssd-3ff729e6c8a371e7a52914772816c39ca73c50a9.tar.bz2
sssd-3ff729e6c8a371e7a52914772816c39ca73c50a9.zip
Modifications to simplify list_missing_attrs
Diffstat (limited to 'src/providers/ldap/sdap_async_users.c')
-rw-r--r--src/providers/ldap/sdap_async_users.c13
1 files changed, 2 insertions, 11 deletions
diff --git a/src/providers/ldap/sdap_async_users.c b/src/providers/ldap/sdap_async_users.c
index 57540749..20067040 100644
--- a/src/providers/ldap/sdap_async_users.c
+++ b/src/providers/ldap/sdap_async_users.c
@@ -34,7 +34,6 @@ int sdap_save_user(TALLOC_CTX *memctx,
struct sdap_options *opts,
struct sss_domain_info *dom,
struct sysdb_attrs *attrs,
- const char **ldap_attrs,
bool is_initgr,
char **_usn_value,
time_t now)
@@ -256,17 +255,11 @@ int sdap_save_user(TALLOC_CTX *memctx,
* did not receive are also removed from the sysdb
*/
ret = list_missing_attrs(user_attrs, opts->user_map, SDAP_OPTS_USER,
- ldap_attrs, attrs, &missing);
+ attrs, &missing);
if (ret != EOK) {
goto fail;
}
- /* Remove missing attributes */
- if (missing && !missing[0]) {
- /* Nothing to remove */
- talloc_zfree(missing);
- }
-
DEBUG(6, ("Storing info for user %s\n", name));
ret = sysdb_store_user(ctx, name, pwd, uid, gid, gecos, homedir, shell,
@@ -293,7 +286,6 @@ fail:
int sdap_save_users(TALLOC_CTX *memctx,
struct sysdb_ctx *sysdb,
- const char **attrs,
struct sss_domain_info *dom,
struct sdap_options *opts,
struct sysdb_attrs **users,
@@ -327,7 +319,7 @@ int sdap_save_users(TALLOC_CTX *memctx,
usn_value = NULL;
ret = sdap_save_user(tmpctx, sysdb, opts, dom,
- users[i], attrs, false,
+ users[i], false,
&usn_value, now);
/* Do not fail completely on errors.
@@ -558,7 +550,6 @@ static void sdap_get_users_process(struct tevent_req *subreq)
}
ret = sdap_save_users(state, state->sysdb,
- state->attrs,
state->dom, state->opts,
state->users, state->count,
&state->higher_usn);