summaryrefslogtreecommitdiff
path: root/source3/smbd
diff options
context:
space:
mode:
Diffstat (limited to 'source3/smbd')
-rw-r--r--source3/smbd/nttrans.c5
-rw-r--r--source3/smbd/server.c2
2 files changed, 4 insertions, 3 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);
diff --git a/source3/smbd/server.c b/source3/smbd/server.c
index e7aa41e343..26e4021443 100644
--- a/source3/smbd/server.c
+++ b/source3/smbd/server.c
@@ -145,7 +145,7 @@ static void msg_exit_server(int msg_type, pid_t src, void *buf, size_t len)
Have we reached the process limit ?
****************************************************************************/
-BOOL allowable_number_of_smbd_processes(void)
+static BOOL allowable_number_of_smbd_processes(void)
{
int max_processes = lp_max_smbd_processes();