diff options
author | Volker Lendecke <vl@samba.org> | 2008-12-06 07:12:34 -0500 |
---|---|---|
committer | Steve French <sfrench@us.ibm.com> | 2008-12-25 21:29:12 -0500 |
commit | 8fbbd365cc700e288fb6f9780b092c5afa4946e5 (patch) | |
tree | 630a08973a37ceb06709064b507535eca2664f3d /fs | |
parent | 6d9c6d543165d1d492602c1371cb019040093584 (diff) |
Simplify allocate_mid() slightly: Remove some unnecessary "else" branches
Simplify allocate_mid() slightly: Remove some unnecessary "else" branches
Signed-off-by: Volker Lendecke <vl@samba.org>
Acked-by: Jeff Layton <jlayton@redhat.com>
Signed-off-by: Steve French <sfrench@us.ibm.com>
Diffstat (limited to 'fs')
-rw-r--r-- | fs/cifs/transport.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/fs/cifs/transport.c b/fs/cifs/transport.c index e80210693ff7..c98f929315f2 100644 --- a/fs/cifs/transport.c +++ b/fs/cifs/transport.c | |||
@@ -385,10 +385,14 @@ static int allocate_mid(struct cifsSesInfo *ses, struct smb_hdr *in_buf, | |||
385 | { | 385 | { |
386 | if (ses->server->tcpStatus == CifsExiting) { | 386 | if (ses->server->tcpStatus == CifsExiting) { |
387 | return -ENOENT; | 387 | return -ENOENT; |
388 | } else if (ses->server->tcpStatus == CifsNeedReconnect) { | 388 | } |
389 | |||
390 | if (ses->server->tcpStatus == CifsNeedReconnect) { | ||
389 | cFYI(1, ("tcp session dead - return to caller to retry")); | 391 | cFYI(1, ("tcp session dead - return to caller to retry")); |
390 | return -EAGAIN; | 392 | return -EAGAIN; |
391 | } else if (ses->status != CifsGood) { | 393 | } |
394 | |||
395 | if (ses->status != CifsGood) { | ||
392 | /* check if SMB session is bad because we are setting it up */ | 396 | /* check if SMB session is bad because we are setting it up */ |
393 | if ((in_buf->Command != SMB_COM_SESSION_SETUP_ANDX) && | 397 | if ((in_buf->Command != SMB_COM_SESSION_SETUP_ANDX) && |
394 | (in_buf->Command != SMB_COM_NEGOTIATE)) | 398 | (in_buf->Command != SMB_COM_NEGOTIATE)) |