mirror of
https://github.com/samba-team/samba.git
synced 2025-08-26 01:49:31 +03:00
s3:smbd: pass smbXsrv_connection to open_was_deferred()
Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
This commit is contained in:
committed by
Michael Adam
parent
333707fa37
commit
d8cffad8e0
@ -582,7 +582,7 @@ void reply_ntcreate_and_X(struct smb_request *req)
|
||||
&info); /* pinfo */
|
||||
|
||||
if (!NT_STATUS_IS_OK(status)) {
|
||||
if (open_was_deferred(req->sconn, req->mid)) {
|
||||
if (open_was_deferred(req->xconn, req->mid)) {
|
||||
/* We have re-scheduled this call, no error. */
|
||||
goto out;
|
||||
}
|
||||
@ -1189,7 +1189,7 @@ static void call_nt_transact_create(connection_struct *conn,
|
||||
&info); /* pinfo */
|
||||
|
||||
if(!NT_STATUS_IS_OK(status)) {
|
||||
if (open_was_deferred(req->sconn, req->mid)) {
|
||||
if (open_was_deferred(req->xconn, req->mid)) {
|
||||
/* We have re-scheduled this call, no error. */
|
||||
return;
|
||||
}
|
||||
@ -1670,7 +1670,7 @@ void reply_ntrename(struct smb_request *req)
|
||||
}
|
||||
|
||||
if (!NT_STATUS_IS_OK(status)) {
|
||||
if (open_was_deferred(req->sconn, req->mid)) {
|
||||
if (open_was_deferred(req->xconn, req->mid)) {
|
||||
/* We have re-scheduled this call. */
|
||||
goto out;
|
||||
}
|
||||
|
@ -853,8 +853,9 @@ bool schedule_deferred_open_message_smb(struct smbd_server_connection *sconn,
|
||||
Return true if this mid is on the deferred queue and was not yet processed.
|
||||
****************************************************************************/
|
||||
|
||||
bool open_was_deferred(struct smbd_server_connection *sconn, uint64_t mid)
|
||||
bool open_was_deferred(struct smbXsrv_connection *xconn, uint64_t mid)
|
||||
{
|
||||
struct smbd_server_connection *sconn = xconn->client->sconn;
|
||||
struct pending_message_list *pml;
|
||||
|
||||
if (sconn->using_smb2) {
|
||||
|
@ -753,7 +753,7 @@ void remove_deferred_open_message_smb(struct smbd_server_connection *sconn,
|
||||
uint64_t mid);
|
||||
bool schedule_deferred_open_message_smb(struct smbd_server_connection *sconn,
|
||||
uint64_t mid);
|
||||
bool open_was_deferred(struct smbd_server_connection *sconn, uint64_t mid);
|
||||
bool open_was_deferred(struct smbXsrv_connection *xconn, uint64_t mid);
|
||||
bool get_deferred_open_message_state(struct smb_request *smbreq,
|
||||
struct timeval *p_request_time,
|
||||
struct deferred_open_record **open_rec);
|
||||
|
@ -2012,7 +2012,7 @@ void reply_open(struct smb_request *req)
|
||||
&info); /* pinfo */
|
||||
|
||||
if (!NT_STATUS_IS_OK(status)) {
|
||||
if (open_was_deferred(req->sconn, req->mid)) {
|
||||
if (open_was_deferred(req->xconn, req->mid)) {
|
||||
/* We have re-scheduled this call. */
|
||||
goto out;
|
||||
}
|
||||
@ -2181,7 +2181,7 @@ void reply_open_and_X(struct smb_request *req)
|
||||
&smb_action); /* pinfo */
|
||||
|
||||
if (!NT_STATUS_IS_OK(status)) {
|
||||
if (open_was_deferred(req->sconn, req->mid)) {
|
||||
if (open_was_deferred(req->xconn, req->mid)) {
|
||||
/* We have re-scheduled this call. */
|
||||
goto out;
|
||||
}
|
||||
@ -2429,7 +2429,7 @@ void reply_mknew(struct smb_request *req)
|
||||
NULL); /* pinfo */
|
||||
|
||||
if (!NT_STATUS_IS_OK(status)) {
|
||||
if (open_was_deferred(req->sconn, req->mid)) {
|
||||
if (open_was_deferred(req->xconn, req->mid)) {
|
||||
/* We have re-scheduled this call. */
|
||||
goto out;
|
||||
}
|
||||
@ -2563,7 +2563,7 @@ void reply_ctemp(struct smb_request *req)
|
||||
}
|
||||
|
||||
if (!NT_STATUS_IS_OK(status)) {
|
||||
if (open_was_deferred(req->sconn, req->mid)) {
|
||||
if (open_was_deferred(req->xconn, req->mid)) {
|
||||
/* We have re-scheduled this call. */
|
||||
goto out;
|
||||
}
|
||||
@ -3052,7 +3052,7 @@ void reply_unlink(struct smb_request *req)
|
||||
status = unlink_internals(conn, req, dirtype, smb_fname,
|
||||
path_contains_wcard);
|
||||
if (!NT_STATUS_IS_OK(status)) {
|
||||
if (open_was_deferred(req->sconn, req->mid)) {
|
||||
if (open_was_deferred(req->xconn, req->mid)) {
|
||||
/* We have re-scheduled this call. */
|
||||
goto out;
|
||||
}
|
||||
@ -6046,7 +6046,7 @@ void reply_rmdir(struct smb_request *req)
|
||||
&info); /* pinfo */
|
||||
|
||||
if (!NT_STATUS_IS_OK(status)) {
|
||||
if (open_was_deferred(req->sconn, req->mid)) {
|
||||
if (open_was_deferred(req->xconn, req->mid)) {
|
||||
/* We have re-scheduled this call. */
|
||||
goto out;
|
||||
}
|
||||
@ -7121,7 +7121,7 @@ void reply_mv(struct smb_request *req)
|
||||
attrs, False, src_has_wcard, dest_has_wcard,
|
||||
DELETE_ACCESS);
|
||||
if (!NT_STATUS_IS_OK(status)) {
|
||||
if (open_was_deferred(req->sconn, req->mid)) {
|
||||
if (open_was_deferred(req->xconn, req->mid)) {
|
||||
/* We have re-scheduled this call. */
|
||||
goto out;
|
||||
}
|
||||
|
@ -956,7 +956,7 @@ static struct tevent_req *smbd_smb2_create_send(TALLOC_CTX *mem_ctx,
|
||||
&result,
|
||||
&info);
|
||||
if (!NT_STATUS_IS_OK(status)) {
|
||||
if (open_was_deferred(smb1req->sconn, smb1req->mid)) {
|
||||
if (open_was_deferred(smb1req->xconn, smb1req->mid)) {
|
||||
return req;
|
||||
}
|
||||
tevent_req_nterror(req, status);
|
||||
|
@ -1230,7 +1230,7 @@ static void call_trans2open(connection_struct *conn,
|
||||
&smb_action); /* psbuf */
|
||||
|
||||
if (!NT_STATUS_IS_OK(status)) {
|
||||
if (open_was_deferred(req->sconn, req->mid)) {
|
||||
if (open_was_deferred(req->xconn, req->mid)) {
|
||||
/* We have re-scheduled this call. */
|
||||
goto out;
|
||||
}
|
||||
@ -8391,7 +8391,7 @@ static void call_trans2setfilepathinfo(connection_struct *conn,
|
||||
ppdata, total_data,
|
||||
&data_return_size);
|
||||
if (!NT_STATUS_IS_OK(status)) {
|
||||
if (open_was_deferred(req->sconn, req->mid)) {
|
||||
if (open_was_deferred(req->xconn, req->mid)) {
|
||||
/* We have re-scheduled this call. */
|
||||
return;
|
||||
}
|
||||
|
Reference in New Issue
Block a user