summaryrefslogtreecommitdiff
path: root/source3/utils/smbcquotas.c
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2007-11-29 13:24:54 -0800
committerJeremy Allison <jra@samba.org>2007-11-29 13:24:54 -0800
commitd2cf97aeba14a4d336fb57b01f19bd5a08dcb003 (patch)
tree659f15d8011a1a110850c01e11078eae86d8bdad /source3/utils/smbcquotas.c
parent42c87fe6e6036a56b178183b034275321949050d (diff)
downloadsamba-d2cf97aeba14a4d336fb57b01f19bd5a08dcb003.tar.gz
samba-d2cf97aeba14a4d336fb57b01f19bd5a08dcb003.tar.bz2
samba-d2cf97aeba14a4d336fb57b01f19bd5a08dcb003.zip
Remove the explicit TALLOC_CTX * from cli_struct.
Make us very explicit about how long a talloc ctx should last. Jeremy. (This used to be commit ba9e2be2b5a59684e854609f9d82ea1633448c62)
Diffstat (limited to 'source3/utils/smbcquotas.c')
-rw-r--r--source3/utils/smbcquotas.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/source3/utils/smbcquotas.c b/source3/utils/smbcquotas.c
index ae793c28f9..6ae63f4c68 100644
--- a/source3/utils/smbcquotas.c
+++ b/source3/utils/smbcquotas.c
@@ -62,7 +62,7 @@ static bool cli_open_policy_hnd(void)
/* Some systems don't support SEC_RIGHTS_MAXIMUM_ALLOWED,
but NT sends 0x2000000 so we might as well do it too. */
- if (!NT_STATUS_IS_OK(rpccli_lsa_open_policy(global_pipe_hnd, cli_ipc->mem_ctx, True,
+ if (!NT_STATUS_IS_OK(rpccli_lsa_open_policy(global_pipe_hnd, talloc_tos(), True,
GENERIC_EXECUTE_ACCESS, &pol))) {
return False;
}
@@ -87,7 +87,7 @@ static void SidToString(fstring str, DOM_SID *sid, bool _numeric)
/* Ask LSA to convert the sid to a name */
if (!cli_open_policy_hnd() ||
- !NT_STATUS_IS_OK(rpccli_lsa_lookup_sids(global_pipe_hnd, cli_ipc->mem_ctx,
+ !NT_STATUS_IS_OK(rpccli_lsa_lookup_sids(global_pipe_hnd, talloc_tos(),
&pol, 1, sid, &domains,
&names, &types)) ||
!domains || !domains[0] || !names || !names[0]) {
@@ -114,7 +114,7 @@ static bool StringToSid(DOM_SID *sid, const char *str)
}
if (!cli_open_policy_hnd() ||
- !NT_STATUS_IS_OK(rpccli_lsa_lookup_names(global_pipe_hnd, cli_ipc->mem_ctx,
+ !NT_STATUS_IS_OK(rpccli_lsa_lookup_names(global_pipe_hnd, talloc_tos(),
&pol, 1, &str, NULL, 1, &sids,
&types))) {
result = False;
@@ -559,4 +559,3 @@ FSQFLAGS:QUOTA_ENABLED/DENY_DISK/LOG_SOFTLIMIT/LOG_HARD_LIMIT", "SETSTRING" },
return result;
}
-