Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 71544
b: refs/heads/master
c: f01d5e1
h: refs/heads/master
v: v3
  • Loading branch information
Steve French committed Aug 30, 2007
1 parent 7a33b9b commit 15adaca
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 7 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 8594c15ad226227aaf178b7cf57f2e7291684dd4
refs/heads/master: f01d5e14e764b14b6bf5512678523d009254b209
13 changes: 7 additions & 6 deletions trunk/fs/cifs/connect.c
Original file line number Diff line number Diff line change
Expand Up @@ -400,9 +400,11 @@ cifs_demultiplex_thread(struct TCP_Server_Info *server)
iov.iov_len = 4;
smb_msg.msg_control = NULL;
smb_msg.msg_controllen = 0;
pdu_length = 4; /* enough to get RFC1001 header */
incomplete_rcv:
length =
kernel_recvmsg(csocket, &smb_msg,
&iov, 1, 4, 0 /* BB see socket.h flags */);
&iov, 1, pdu_length, 0 /* BB other flags? */);

if ( kthread_should_stop() ) {
break;
Expand Down Expand Up @@ -437,13 +439,12 @@ cifs_demultiplex_thread(struct TCP_Server_Info *server)
wake_up(&server->response_q);
continue;
} else if (length < 4) {
cFYI(1,
("Frame under four bytes received (%d bytes long)",
cFYI(1, ("less than four bytes received (%d bytes)",
length));
pdu_length -= length;
cifs_reconnect(server);
csocket = server->ssocket;
wake_up(&server->response_q);
continue;
msleep(1);
goto incomplete_rcv;
}

/* The right amount was read from socket - 4 bytes */
Expand Down

0 comments on commit 15adaca

Please sign in to comment.