summaryrefslogtreecommitdiff
path: root/source3/smbd
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2013-05-02 13:08:16 -0700
committerRichard Sharpe <sharpe@samba.org>2013-05-07 17:58:45 +0200
commit1102e73832f78ca5decc928d6c3649d4fe68eab7 (patch)
tree696c240bf43c03d6da1573c5ff8e184cfedc89bd /source3/smbd
parenta026fc6b699719309a27d4646d06fe1a45b0d158 (diff)
downloadsamba-1102e73832f78ca5decc928d6c3649d4fe68eab7.tar.gz
samba-1102e73832f78ca5decc928d6c3649d4fe68eab7.tar.bz2
samba-1102e73832f78ca5decc928d6c3649d4fe68eab7.zip
Move a variable into the area of code where it's used.
Signed-off-by: Jeremy Allison <jra@samba.org> Reviewed-by: Richard Sharpe <realrichardsharpe@gmail.com>
Diffstat (limited to 'source3/smbd')
-rw-r--r--source3/smbd/smb2_server.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/source3/smbd/smb2_server.c b/source3/smbd/smb2_server.c
index 9a55d6af2c..1738b5ef5e 100644
--- a/source3/smbd/smb2_server.c
+++ b/source3/smbd/smb2_server.c
@@ -1272,7 +1272,6 @@ NTSTATUS smbd_smb2_request_pending_queue(struct smbd_smb2_request *req,
uint32_t defer_time)
{
NTSTATUS status;
- int idx = req->current_idx;
struct timeval defer_endtime;
uint8_t *outhdr = NULL;
uint32_t flags;
@@ -1296,7 +1295,7 @@ NTSTATUS smbd_smb2_request_pending_queue(struct smbd_smb2_request *req,
return NT_STATUS_OK;
}
- if (req->in.vector_count > idx + SMBD_SMB2_NUM_IOV_PER_REQ) {
+ if (req->in.vector_count > req->current_idx + SMBD_SMB2_NUM_IOV_PER_REQ) {
/*
* We're trying to go async in a compound
* request chain. This is not allowed.
@@ -1318,6 +1317,7 @@ NTSTATUS smbd_smb2_request_pending_queue(struct smbd_smb2_request *req,
}
if (req->out.vector_count >= (2*SMBD_SMB2_NUM_IOV_PER_REQ)) {
+ int idx = req->current_idx;
/*
* This is a compound reply. We
* must do an interim response