diff options
author | Stephen Gallagher <sgallagh@redhat.com> | 2011-04-15 09:19:40 -0400 |
---|---|---|
committer | Stephen Gallagher <sgallagh@redhat.com> | 2011-04-15 12:03:48 -0400 |
commit | d51dfcd1ca28ce1e02299ae42313fb575c485b46 (patch) | |
tree | ffea1f28cb1b7b9c63d47b87302aef7000e01fc6 /src/responder/common/negcache.c | |
parent | 0de124abf79be1bb9fcfec251b9df8880159817c (diff) | |
download | sssd-d51dfcd1ca28ce1e02299ae42313fb575c485b46.tar.gz sssd-d51dfcd1ca28ce1e02299ae42313fb575c485b46.tar.xz sssd-d51dfcd1ca28ce1e02299ae42313fb575c485b46.zip |
Fix regressions in the negative cachesssd-1.5.1-30.el5
Do not throw a DP error when failing to delete a nonexistent entity
Add debug logging to the negative cache
Fix a regression with the negative cache in multi-domain configurations
Fix regression where nonexistent entries were never added to the negative cache
Diffstat (limited to 'src/responder/common/negcache.c')
-rw-r--r-- | src/responder/common/negcache.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/responder/common/negcache.c b/src/responder/common/negcache.c index 5f85df25d..d8c4c2698 100644 --- a/src/responder/common/negcache.c +++ b/src/responder/common/negcache.c @@ -71,6 +71,8 @@ static int sss_ncache_check_str(struct sss_nc_ctx *ctx, char *str, int ttl) char *ep; int ret; + DEBUG(8, ("Checking negative cache for [%s]\n", str)); + ret = string_to_tdb_data(str, &key); if (ret != EOK) goto done; @@ -141,6 +143,9 @@ static int sss_ncache_set_str(struct sss_nc_ctx *ctx, ret = string_to_tdb_data(timest, &data); if (ret != EOK) goto done; + DEBUG(6, ("Adding [%s] to negative cache%s\n", + str, permanent?" permanently":"")); + ret = tdb_store(ctx->tdb, key, data, TDB_REPLACE); if (ret != 0) { DEBUG(1, ("Negative cache failed to set entry: [%s]\n", |