diff options
author | Andrew Bartlett <abartlet@samba.org> | 2004-02-08 11:59:55 +0000 |
---|---|---|
committer | Andrew Bartlett <abartlet@samba.org> | 2004-02-08 11:59:55 +0000 |
commit | 9b586b5a645c27d48d3cf8eb788e297ba83114d6 (patch) | |
tree | 7fff83e3eba138fe392a41ed9b6bb0f5348c8643 /source3/smbd/nttrans.c | |
parent | f7c1c68e19c00c3b107d4fd08401ed8aeb09bbaa (diff) | |
download | samba-9b586b5a645c27d48d3cf8eb788e297ba83114d6.tar.gz samba-9b586b5a645c27d48d3cf8eb788e297ba83114d6.tar.bz2 samba-9b586b5a645c27d48d3cf8eb788e297ba83114d6.zip |
(merge from 3.0)
Make more functions static, and remove duplication in the use of functions
in lib/smbpasswd.c that were exact duplicates of functions in passdb/passdb.c
(These should perhaps be pulled back out to smbpasswd.c, but that can occour
later).
This also includes some >14 character password changes, and the start
of a move away from using 'admin user' to determine if the user is
root (as root can login without setting 'admin user').
Andrew Bartlett
(This used to be commit be0704abb919152c359a735023283acbf9be3076)
Diffstat (limited to 'source3/smbd/nttrans.c')
-rw-r--r-- | source3/smbd/nttrans.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/source3/smbd/nttrans.c b/source3/smbd/nttrans.c index 25721d99a8..0a2843629e 100644 --- a/source3/smbd/nttrans.c +++ b/source3/smbd/nttrans.c @@ -56,7 +56,7 @@ struct generic_mapping file_generic_mapping = { FILE_GENERIC_ALL }; -char *nttrans_realloc(char **ptr, size_t size) +static char *nttrans_realloc(char **ptr, size_t size) { char *tptr = NULL; if (ptr==NULL) @@ -2022,11 +2022,12 @@ static int call_nt_transact_get_user_quota(connection_struct *conn, char *inbuf, SMB_NTQUOTA_STRUCT qt; SMB_NTQUOTA_LIST *tmp_list; SMB_NTQUOTA_HANDLE *qt_handle = NULL; + extern struct current_user current_user; ZERO_STRUCT(qt); /* access check */ - if (conn->admin_user != True) { + if (current_user.uid != 0) { DEBUG(1,("set_user_quota: access_denied service [%s] user [%s]\n", lp_servicename(SNUM(conn)),conn->user)); return ERROR_DOS(ERRDOS,ERRnoaccess); |