diff options
author | Volker Lendecke <vl@samba.org> | 2013-09-04 08:56:23 +0200 |
---|---|---|
committer | Jeremy Allison <jra@samba.org> | 2013-09-05 09:16:23 -0700 |
commit | 8a7246ac2c5b27cc29e6ca23c1e2e0f43e298eb5 (patch) | |
tree | eed73a2a54d2e811e0bbfae2bbb27a5df6d48436 /source3/lib | |
parent | f630360b7ff07ffd2a22f16d50293949860418ca (diff) | |
download | samba-8a7246ac2c5b27cc29e6ca23c1e2e0f43e298eb5.tar.gz samba-8a7246ac2c5b27cc29e6ca23c1e2e0f43e298eb5.tar.bz2 samba-8a7246ac2c5b27cc29e6ca23c1e2e0f43e298eb5.zip |
lib: Add a "mem_ctx" arg to gencache_get (unused so far)
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Diffstat (limited to 'source3/lib')
-rw-r--r-- | source3/lib/gencache.c | 3 | ||||
-rw-r--r-- | source3/lib/idmap_cache.c | 8 | ||||
-rw-r--r-- | source3/lib/wins_srv.c | 2 |
3 files changed, 7 insertions, 6 deletions
diff --git a/source3/lib/gencache.c b/source3/lib/gencache.c index 0d5d9e8815..1ecaad5be5 100644 --- a/source3/lib/gencache.c +++ b/source3/lib/gencache.c @@ -705,7 +705,8 @@ static int stabilize_fn(struct tdb_context *tdb, TDB_DATA key, TDB_DATA val, * @retval False for failure **/ -bool gencache_get(const char *keystr, char **value, time_t *ptimeout) +bool gencache_get(const char *keystr, TALLOC_CTX *mem_ctx, char **value, + time_t *ptimeout) { DATA_BLOB blob; bool ret = False; diff --git a/source3/lib/idmap_cache.c b/source3/lib/idmap_cache.c index edf37a8496..627ced30b3 100644 --- a/source3/lib/idmap_cache.c +++ b/source3/lib/idmap_cache.c @@ -48,7 +48,7 @@ bool idmap_cache_find_sid2unixid(const struct dom_sid *sid, struct unixid *id, if (key == NULL) { return false; } - ret = gencache_get(key, &value, &timeout); + ret = gencache_get(key, NULL, &value, &timeout); if (!ret) { goto done; } @@ -209,7 +209,7 @@ bool idmap_cache_find_uid2sid(uid_t uid, struct dom_sid *sid, bool *expired) if (key == NULL) { return false; } - ret = gencache_get(key, &value, &timeout); + ret = gencache_get(key, NULL, &value, &timeout); TALLOC_FREE(key); if (!ret) { return false; @@ -246,7 +246,7 @@ bool idmap_cache_find_gid2sid(gid_t gid, struct dom_sid *sid, bool *expired) if (key == NULL) { return false; } - ret = gencache_get(key, &value, &timeout); + ret = gencache_get(key, NULL, &value, &timeout); TALLOC_FREE(key); if (!ret) { return false; @@ -431,7 +431,7 @@ static bool idmap_cache_del_xid(char t, int xid) time_t timeout; bool ret = true; - if (!gencache_get(key, &sid_str, &timeout)) { + if (!gencache_get(key, NULL, &sid_str, &timeout)) { DEBUG(3, ("no entry: %s\n", key)); ret = false; goto done; diff --git a/source3/lib/wins_srv.c b/source3/lib/wins_srv.c index fb5587f9ba..6f7d5b3b0c 100644 --- a/source3/lib/wins_srv.c +++ b/source3/lib/wins_srv.c @@ -101,7 +101,7 @@ bool wins_srv_is_dead(struct in_addr wins_ip, struct in_addr src_ip) /* If the key exists then the WINS server has been marked as dead */ - result = gencache_get(keystr, NULL, NULL); + result = gencache_get(keystr, NULL, NULL, NULL); SAFE_FREE(keystr); DEBUG(4, ("wins_srv_is_dead: %s is %s\n", inet_ntoa(wins_ip), |