diff options
author | Jakub Hrozek <jhrozek@redhat.com> | 2013-04-29 14:37:27 +0200 |
---|---|---|
committer | Jakub Hrozek <jhrozek@redhat.com> | 2013-05-30 17:21:35 +0200 |
commit | f07523526597f6232dfcafbe23e0857ec61f69ab (patch) | |
tree | 586581e3fcee4da24fd487c3f4070a278bdf6bf2 /src/db/sysdb_ops.c | |
parent | d00672f4efc25a3cfd7252254854dfc60deeec6b (diff) | |
download | sssd-f07523526597f6232dfcafbe23e0857ec61f69ab.tar.gz sssd-f07523526597f6232dfcafbe23e0857ec61f69ab.tar.xz sssd-f07523526597f6232dfcafbe23e0857ec61f69ab.zip |
Only try to relink ghost users if we're not enumerating1.9.2-90
https://fedorahosted.org/sssd/ticket/1893
When SSSD is not enumerating (which is the default), we are trying to
link any "ghost" entries with a newly created user entry. However, when
enumeration is on, this means a spurious search on adding any user.
Diffstat (limited to 'src/db/sysdb_ops.c')
-rw-r--r-- | src/db/sysdb_ops.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/db/sysdb_ops.c b/src/db/sysdb_ops.c index 5d0748740..5e6698010 100644 --- a/src/db/sysdb_ops.c +++ b/src/db/sysdb_ops.c @@ -1071,6 +1071,14 @@ int sysdb_add_user(struct sysdb_ctx *sysdb, goto done; } + /* If we're not enumerating, previous getgr{nam,gid} calls might + * have stored ghost users into the cache, so we need to link them + * with the newly-created user entry */ + if (domain->enumerate == true) { + ret = EOK; + goto done; + } + /* We need to find all groups that contain this object as a ghost user * and replace the ghost user by actual member record in direct parents. * Note that this object can be referred to either by its name or any |