diff options
author | Volker Lendecke <vl@samba.org> | 2018-08-16 10:51:44 +0200 |
---|---|---|
committer | Andreas Schneider <asn@cryptomilk.org> | 2018-08-17 11:30:11 +0200 |
commit | c2ea10077715fb2a554a9f39b2ff49338bd8a124 (patch) | |
tree | 854522aa679e6396c94bace54639025232aaf084 /source3/passdb | |
parent | f986a73b240ea61df1d4664b9c3c6d0858b17111 (diff) | |
download | samba-c2ea10077715fb2a554a9f39b2ff49338bd8a124.tar.gz |
lib: Pass mem_ctx to state_path()
Fix a confusing API: Many places TALLOC_FREE the path where it's not
clear you have to do it.
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
Diffstat (limited to 'source3/passdb')
-rw-r--r-- | source3/passdb/account_pol.c | 2 | ||||
-rw-r--r-- | source3/passdb/pdb_tdb.c | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/source3/passdb/account_pol.c b/source3/passdb/account_pol.c index 421a054f83b..4d94dfe817c 100644 --- a/source3/passdb/account_pol.c +++ b/source3/passdb/account_pol.c @@ -220,7 +220,7 @@ bool init_account_policy(void) return True; } - db_path = state_path("account_policy.tdb"); + db_path = state_path(talloc_tos(), "account_policy.tdb"); if (db_path == NULL) { return false; } diff --git a/source3/passdb/pdb_tdb.c b/source3/passdb/pdb_tdb.c index 6f3dda6e229..91735ff7084 100644 --- a/source3/passdb/pdb_tdb.c +++ b/source3/passdb/pdb_tdb.c @@ -336,7 +336,7 @@ static bool tdbsam_upgrade_next_rid(struct db_context *db) return true; } - db_path = state_path("winbindd_idmap.tdb"); + db_path = state_path(talloc_tos(), "winbindd_idmap.tdb"); if (db_path == NULL) { return false; } |