summaryrefslogtreecommitdiffstats
path: root/source/smbd/process.c
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2001-08-27 08:19:43 +0000
committerAndrew Tridgell <tridge@samba.org>2001-08-27 08:19:43 +0000
commit83d9896c1ea8be796192b51a4678c2a3b87f7518 (patch)
tree3eca52e51950890d1a5b6e7c8b0ddfdee78a239a /source/smbd/process.c
parent9e0c9a99f6ca01cd6a0ee3084f85e1c36b11d7c3 (diff)
downloadsamba-83d9896c1ea8be796192b51a4678c2a3b87f7518.tar.gz
samba-83d9896c1ea8be796192b51a4678c2a3b87f7518.tar.xz
samba-83d9896c1ea8be796192b51a4678c2a3b87f7518.zip
converted smbd to use NTSTATUS by default
major changes include: - added NSTATUS type - added automatic mapping between dos and nt error codes - changed all ERROR() calls to ERROR_DOS() and many to ERROR_NT() these calls auto-translate to the client error code system - got rid of the cached error code and the writebmpx code We eventually will need to also: - get rid of BOOL, so we don't lose error info - replace all ERROR_DOS() calls with ERROR_NT() calls but that is too much for one night
Diffstat (limited to 'source/smbd/process.c')
-rw-r--r--source/smbd/process.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/source/smbd/process.c b/source/smbd/process.c
index 2b75197c380..ce1e855e29f 100644
--- a/source/smbd/process.c
+++ b/source/smbd/process.c
@@ -352,9 +352,9 @@ struct smb_message_struct
/* 0x1b */ { "SMBreadBmpx",reply_readbmpx,AS_USER},
/* 0x1c */ { "SMBreadBs",NULL,AS_USER},
/* 0x1d */ { "SMBwritebraw",reply_writebraw,AS_USER},
-/* 0x1e */ { "SMBwriteBmpx",reply_writebmpx,AS_USER},
-/* 0x1f */ { "SMBwriteBs",reply_writebs,AS_USER},
-/* 0x20 */ { "SMBwritec",NULL,AS_USER},
+/* 0x1e */ { NULL,NULL,0},
+/* 0x1f */ { NULL,NULL,0},
+/* 0x20 */ { NULL,NULL,0},
/* 0x21 */ { NULL, NULL, 0 },
/* 0x22 */ { "SMBsetattrE",reply_setattrE,AS_USER | NEED_WRITE },
/* 0x23 */ { "SMBgetattrE",reply_getattrE,AS_USER },
@@ -695,7 +695,7 @@ static int switch_message(int type,char *inbuf,char *outbuf,int size,int bufsize
/* does this protocol need a valid tree connection? */
if ((flags & AS_USER) && !conn) {
- return ERROR(ERRSRV, ERRinvnid);
+ return ERROR_DOS(ERRSRV, ERRinvnid);
}
@@ -704,7 +704,7 @@ static int switch_message(int type,char *inbuf,char *outbuf,int size,int bufsize
if (flags & AS_GUEST)
flags &= ~AS_USER;
else
- return(ERROR(ERRSRV,ERRaccess));
+ return(ERROR_DOS(ERRSRV,ERRaccess));
}
/* this code is to work around a bug is MS client 3 without
@@ -715,23 +715,23 @@ static int switch_message(int type,char *inbuf,char *outbuf,int size,int bufsize
/* does it need write permission? */
if ((flags & NEED_WRITE) && !CAN_WRITE(conn))
- return(ERROR(ERRSRV,ERRaccess));
+ return(ERROR_DOS(ERRSRV,ERRaccess));
/* ipc services are limited */
if (IS_IPC(conn) && (flags & AS_USER) && !(flags & CAN_IPC)) {
- return(ERROR(ERRSRV,ERRaccess));
+ return(ERROR_DOS(ERRSRV,ERRaccess));
}
/* load service specific parameters */
if (conn && !become_service(conn,(flags & AS_USER)?True:False)) {
- return(ERROR(ERRSRV,ERRaccess));
+ return(ERROR_DOS(ERRSRV,ERRaccess));
}
/* does this protocol need to be run as guest? */
if ((flags & AS_GUEST) &&
(!become_guest() ||
!check_access(smbd_server_fd(), lp_hostsallow(-1), lp_hostsdeny(-1)))) {
- return(ERROR(ERRSRV,ERRaccess));
+ return(ERROR_DOS(ERRSRV,ERRaccess));
}
last_inbuf = inbuf;