diff options
author | Jeff Layton <jlayton@redhat.com> | 2013-04-03 10:27:36 -0400 |
---|---|---|
committer | Steve French <smfrench@gmail.com> | 2013-05-04 23:17:56 -0400 |
commit | ad313cb86dfba27f8f2306da304974ef17c91c56 (patch) | |
tree | b6fbc7b3f6d7448264c7db49ef82f300c2699d3e /fs/cifs/smb1ops.c | |
parent | ce6c44e44e43f0cef12030de0a8f0814914d47dd (diff) |
cifs: on send failure, readjust server sequence number downward
If sending a call to the server fails for some reason (for instance, the
sending thread caught a signal), then we must readjust the sequence
number downward again or the next send will have it too high.
Signed-off-by: Jeff Layton <jlayton@redhat.com>
Signed-off-by: Steve French <sfrench@us.ibm.com>
Signed-off-by: Steve French <smfrench@gmail.com>
Diffstat (limited to 'fs/cifs/smb1ops.c')
-rw-r--r-- | fs/cifs/smb1ops.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/fs/cifs/smb1ops.c b/fs/cifs/smb1ops.c index 23bcd11c8103..3efdb9d5c0b8 100644 --- a/fs/cifs/smb1ops.c +++ b/fs/cifs/smb1ops.c | |||
@@ -61,6 +61,9 @@ send_nt_cancel(struct TCP_Server_Info *server, void *buf, | |||
61 | */ | 61 | */ |
62 | --server->sequence_number; | 62 | --server->sequence_number; |
63 | rc = smb_send(server, in_buf, be32_to_cpu(in_buf->smb_buf_length)); | 63 | rc = smb_send(server, in_buf, be32_to_cpu(in_buf->smb_buf_length)); |
64 | if (rc < 0) | ||
65 | server->sequence_number--; | ||
66 | |||
64 | mutex_unlock(&server->srv_mutex); | 67 | mutex_unlock(&server->srv_mutex); |
65 | 68 | ||
66 | cifs_dbg(FYI, "issued NT_CANCEL for mid %u, rc = %d\n", | 69 | cifs_dbg(FYI, "issued NT_CANCEL for mid %u, rc = %d\n", |