summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
authorVolker Lendecke <vl@samba.org>2010-09-25 16:28:21 -0700
committerVolker Lendecke <vl@samba.org>2010-09-26 03:29:29 +0200
commitbf6ca13346e67107d821cec9edf4f767defa490e (patch)
tree1455bc72515e11741cda4a1a4e09c30d7b84c9f0 /source3
parent77e96d3229ea95d220a663aa99c7d376f3619d41 (diff)
downloadsamba-bf6ca13346e67107d821cec9edf4f767defa490e.tar.gz
samba-bf6ca13346e67107d821cec9edf4f767defa490e.tar.bz2
samba-bf6ca13346e67107d821cec9edf4f767defa490e.zip
s3: Remove talloc_autofree_context() from smbpasswd
In both cases, pwd is freed immediately
Diffstat (limited to 'source3')
-rw-r--r--source3/utils/smbpasswd.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/source3/utils/smbpasswd.c b/source3/utils/smbpasswd.c
index 1b68136c68..2ae7e4dcdf 100644
--- a/source3/utils/smbpasswd.c
+++ b/source3/utils/smbpasswd.c
@@ -342,7 +342,7 @@ static int process_root(int local_flags)
load_interfaces();
}
- if (!user_name[0] && (pwd = getpwuid_alloc(talloc_autofree_context(), geteuid()))) {
+ if (!user_name[0] && (pwd = getpwuid_alloc(talloc_tos(), geteuid()))) {
fstrcpy(user_name, pwd->pw_name);
TALLOC_FREE(pwd);
}
@@ -507,7 +507,7 @@ static int process_nonroot(int local_flags)
}
if (!user_name[0]) {
- pwd = getpwuid_alloc(talloc_autofree_context(), getuid());
+ pwd = getpwuid_alloc(talloc_tos(), getuid());
if (pwd) {
fstrcpy(user_name,pwd->pw_name);
TALLOC_FREE(pwd);