s3:smb2_server: remove unused 'sconn' from smbd_smb2_request_pending_state
authorStefan Metzmacher <metze@samba.org>
Wed, 11 Jun 2014 09:22:16 +0000 (11:22 +0200)
committerMichael Adam <obnox@samba.org>
Wed, 6 Aug 2014 07:51:13 +0000 (09:51 +0200)
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
source3/smbd/smb2_server.c

index b24d47c5260a1dd0a2e1630c6489196b5b2aa279..b34bea8cf4972c4f820fdc1220ae2d99fe68b665 100644 (file)
@@ -1278,7 +1278,6 @@ static NTSTATUS smb2_send_async_interim_response(const struct smbd_smb2_request
 }
 
 struct smbd_smb2_request_pending_state {
-        struct smbd_server_connection *sconn;
        struct smbd_smb2_send_queue queue_entry;
         uint8_t buf[NBT_HDR_SIZE + SMB2_TF_HDR_SIZE + SMB2_HDR_BODY + 0x08 + 1];
         struct iovec vector[1 + SMBD_SMB2_NUM_IOV_PER_REQ];
@@ -1426,8 +1425,7 @@ static void smbd_smb2_request_pending_timer(struct tevent_context *ev,
        struct smbd_smb2_request *req =
                talloc_get_type_abort(private_data,
                struct smbd_smb2_request);
-       struct smbd_server_connection *sconn = req->sconn;
-       struct smbXsrv_connection *xconn = sconn->conn;
+       struct smbXsrv_connection *xconn = req->xconn;
        struct smbd_smb2_request_pending_state *state = NULL;
        uint8_t *outhdr = NULL;
        const uint8_t *inhdr = NULL;
@@ -1475,7 +1473,6 @@ static void smbd_smb2_request_pending_timer(struct tevent_context *ev,
                                                 nt_errstr(NT_STATUS_NO_MEMORY));
                return;
        }
-       state->sconn = req->sconn;
 
        tf = state->buf + NBT_HDR_SIZE;
        tf_len = SMB2_TF_HDR_SIZE;
@@ -1603,7 +1600,7 @@ static void smbd_smb2_request_pending_timer(struct tevent_context *ev,
 
        status = smbd_smb2_flush_send_queue(xconn);
        if (!NT_STATUS_IS_OK(status)) {
-               smbd_server_connection_terminate(sconn,
+               smbd_server_connection_terminate(req->sconn,
                                                 nt_errstr(status));
                return;
        }