summaryrefslogtreecommitdiff
path: root/source3/smbd/process.c
diff options
context:
space:
mode:
authorGerald Carter <jerry@samba.org>2003-09-09 04:07:32 +0000
committerGerald Carter <jerry@samba.org>2003-09-09 04:07:32 +0000
commit4093bf7ff8c8861cf7b941945ede53a8ec5bb6c8 (patch)
treedd0a9f32d9933e1f75d919b5083e007d7453f9c4 /source3/smbd/process.c
parent3d7cb49747a9a7f5cdec0ee05c6270ec3604202f (diff)
downloadsamba-4093bf7ff8c8861cf7b941945ede53a8ec5bb6c8.tar.gz
samba-4093bf7ff8c8861cf7b941945ede53a8ec5bb6c8.tar.bz2
samba-4093bf7ff8c8861cf7b941945ede53a8ec5bb6c8.zip
sync 3.0 into HEAD for the last time
(This used to be commit c17a7dc9a190156a069da3e861c18fd3f81224ad)
Diffstat (limited to 'source3/smbd/process.c')
-rw-r--r--source3/smbd/process.c17
1 files changed, 15 insertions, 2 deletions
diff --git a/source3/smbd/process.c b/source3/smbd/process.c
index dce1c4bc03..3c15cd1833 100644
--- a/source3/smbd/process.c
+++ b/source3/smbd/process.c
@@ -48,6 +48,15 @@ BOOL global_machine_password_needs_changing = False;
extern int max_send;
/****************************************************************************
+ Function to return the current request mid from Inbuffer.
+****************************************************************************/
+
+uint16 get_current_mid(void)
+{
+ return SVAL(InBuffer,smb_mid);
+}
+
+/****************************************************************************
structure to hold a linked list of queued messages.
for processing.
****************************************************************************/
@@ -88,7 +97,7 @@ static BOOL push_message(ubi_slList *list_head, char *buf, int msg_len)
ubi_slAddTail( list_head, msg);
/* Push the MID of this packet on the signing queue. */
- srv_defer_sign_response(SVAL(buf,smb_mid));
+ srv_defer_sign_response(SVAL(buf,smb_mid), True);
return True;
}
@@ -710,7 +719,7 @@ static int switch_message(int type,char *inbuf,char *outbuf,int size,int bufsize
if(session_tag != UID_FIELD_INVALID)
vuser = get_valid_user_struct(session_tag);
if(vuser != NULL)
- current_user_info = vuser->user;
+ set_current_user_info(&vuser->user);
}
/* does this protocol need to be run as root? */
@@ -1256,8 +1265,10 @@ void smbd_process(void)
if ((InBuffer == NULL) || (OutBuffer == NULL))
return;
+#if defined(DEVELOPER)
clobber_region(SAFE_STRING_FUNCTION_NAME, SAFE_STRING_LINE, InBuffer, total_buffer_size);
clobber_region(SAFE_STRING_FUNCTION_NAME, SAFE_STRING_LINE, OutBuffer, total_buffer_size);
+#endif
max_recv = MIN(lp_maxxmit(),BUFFER_SIZE);
@@ -1286,7 +1297,9 @@ void smbd_process(void)
num_smbs = 0; /* Reset smb counter. */
}
+#if defined(DEVELOPER)
clobber_region(SAFE_STRING_FUNCTION_NAME, SAFE_STRING_LINE, InBuffer, total_buffer_size);
+#endif
while (!receive_message_or_smb(InBuffer,BUFFER_SIZE+LARGE_WRITEX_HDR_SIZE,select_timeout)) {
if(!timeout_processing( deadtime, &select_timeout, &last_timeout_processing_time))