summaryrefslogtreecommitdiff
path: root/source3/libsmb/namecache.c
diff options
context:
space:
mode:
authorVolker Lendecke <vl@samba.org>2013-09-04 08:57:59 +0200
committerJeremy Allison <jra@samba.org>2013-09-05 20:09:21 +0200
commitd3c689fc5c80431b7e72150f72465b3d255a6f02 (patch)
tree5345e29db38968ef5692e1c8d2435b2d6a3fe45a /source3/libsmb/namecache.c
parent32037e0533f720ebbd3f49c5951c4ef30aac9985 (diff)
downloadsamba-d3c689fc5c80431b7e72150f72465b3d255a6f02.tar.gz
samba-d3c689fc5c80431b7e72150f72465b3d255a6f02.tar.bz2
samba-d3c689fc5c80431b7e72150f72465b3d255a6f02.zip
lib: Use "mem_ctx" arg in gencache_get
Signed-off-by: Volker Lendecke <vl@samba.org> Signed-off-by: Jeremy Allison <jra@samba.org> Autobuild-User(master): Jeremy Allison <jra@samba.org> Autobuild-Date(master): Thu Sep 5 20:09:21 CEST 2013 on sn-devel-104
Diffstat (limited to 'source3/libsmb/namecache.c')
-rw-r--r--source3/libsmb/namecache.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/source3/libsmb/namecache.c b/source3/libsmb/namecache.c
index ebd51fd919..1e6158444d 100644
--- a/source3/libsmb/namecache.c
+++ b/source3/libsmb/namecache.c
@@ -156,7 +156,7 @@ bool namecache_fetch(const char *name,
return False;
}
- if (!gencache_get(key, NULL, &value, &timeout)) {
+ if (!gencache_get(key, talloc_tos(), &value, &timeout)) {
DEBUG(5, ("no entry for %s#%02X found.\n", name, name_type));
SAFE_FREE(key);
return False;
@@ -170,7 +170,7 @@ bool namecache_fetch(const char *name,
*num_names = ipstr_list_parse(value, ip_list);
SAFE_FREE(key);
- SAFE_FREE(value);
+ TALLOC_FREE(value);
return *num_names > 0; /* true only if some ip has been fetched */
}
@@ -294,7 +294,7 @@ bool namecache_status_fetch(const char *keyname,
if (!key)
return False;
- if (!gencache_get(key, NULL, &value, &timeout)) {
+ if (!gencache_get(key, talloc_tos(), &value, &timeout)) {
DEBUG(5, ("namecache_status_fetch: no entry for %s found.\n",
key));
SAFE_FREE(key);
@@ -306,6 +306,6 @@ bool namecache_status_fetch(const char *keyname,
strlcpy(srvname_out, value, 16);
SAFE_FREE(key);
- SAFE_FREE(value);
+ TALLOC_FREE(value);
return True;
}