summaryrefslogtreecommitdiff
path: root/source3/smbd/reply.c
diff options
context:
space:
mode:
Diffstat (limited to 'source3/smbd/reply.c')
-rw-r--r--source3/smbd/reply.c15
1 files changed, 7 insertions, 8 deletions
diff --git a/source3/smbd/reply.c b/source3/smbd/reply.c
index 7b981e1c8a..a62b54550e 100644
--- a/source3/smbd/reply.c
+++ b/source3/smbd/reply.c
@@ -2960,22 +2960,21 @@ void reply_read_and_X(connection_struct *conn, struct smb_request *req)
return;
}
- if (!reply_prep_legacy(req, &inbuf, &outbuf, &length, &bufsize)) {
- reply_nterror(req, NT_STATUS_NO_MEMORY);
+ if (!big_readX
+ && schedule_aio_read_and_X(conn, req, fsp, startpos, smb_maxcnt)) {
END_PROFILE(SMBreadX);
+ reply_post_legacy(req, -1);
return;
}
- set_message(inbuf,outbuf,12,0,True);
-
- if (!big_readX
- && schedule_aio_read_and_X(conn, inbuf, outbuf, length, bufsize,
- fsp, startpos, smb_maxcnt)) {
+ if (!reply_prep_legacy(req, &inbuf, &outbuf, &length, &bufsize)) {
+ reply_nterror(req, NT_STATUS_NO_MEMORY);
END_PROFILE(SMBreadX);
- reply_post_legacy(req, -1);
return;
}
+ set_message(inbuf,outbuf,12,0,True);
+
nread = send_file_readX(conn, inbuf, outbuf, length, bufsize, fsp,
startpos, smb_maxcnt);
/* Only call chain_reply if not an error. */