Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
linux
Commits
ce495618
Commit
ce495618
authored
Oct 28, 2003
by
David S. Miller
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[TCP]: Put Alexey's -EAGAIN change back in with Linus's fix on top.
parent
a7fa6cb1
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
11 deletions
+12
-11
net/ipv4/tcp.c
net/ipv4/tcp.c
+12
-11
No files found.
net/ipv4/tcp.c
View file @
ce495618
...
@@ -1536,19 +1536,14 @@ int tcp_recvmsg(struct kiocb *iocb, struct sock *sk, struct msghdr *msg,
...
@@ -1536,19 +1536,14 @@ int tcp_recvmsg(struct kiocb *iocb, struct sock *sk, struct msghdr *msg,
struct
sk_buff
*
skb
;
struct
sk_buff
*
skb
;
u32
offset
;
u32
offset
;
/* Are we at urgent data? Stop if we have read anything. */
/* Are we at urgent data? Stop if we have read anything or have SIGURG pending. */
if
(
copied
&&
tp
->
urg_data
&&
tp
->
urg_seq
==
*
seq
)
if
(
tp
->
urg_data
&&
tp
->
urg_seq
==
*
seq
)
{
break
;
/* We need to check signals first, to get correct SIGURG
* handling. FIXME: Need to check this doesn't impact 1003.1g
* and move it down to the bottom of the loop
*/
if
(
signal_pending
(
current
))
{
if
(
copied
)
if
(
copied
)
break
;
break
;
copied
=
timeo
?
sock_intr_errno
(
timeo
)
:
-
EAGAIN
;
if
(
signal_pending
(
current
))
{
break
;
copied
=
timeo
?
sock_intr_errno
(
timeo
)
:
-
EAGAIN
;
break
;
}
}
}
/* Next get a buffer. */
/* Next get a buffer. */
...
@@ -1587,6 +1582,7 @@ int tcp_recvmsg(struct kiocb *iocb, struct sock *sk, struct msghdr *msg,
...
@@ -1587,6 +1582,7 @@ int tcp_recvmsg(struct kiocb *iocb, struct sock *sk, struct msghdr *msg,
sk
->
sk_state
==
TCP_CLOSE
||
sk
->
sk_state
==
TCP_CLOSE
||
(
sk
->
sk_shutdown
&
RCV_SHUTDOWN
)
||
(
sk
->
sk_shutdown
&
RCV_SHUTDOWN
)
||
!
timeo
||
!
timeo
||
signal_pending
(
current
)
||
(
flags
&
MSG_PEEK
))
(
flags
&
MSG_PEEK
))
break
;
break
;
}
else
{
}
else
{
...
@@ -1616,6 +1612,11 @@ int tcp_recvmsg(struct kiocb *iocb, struct sock *sk, struct msghdr *msg,
...
@@ -1616,6 +1612,11 @@ int tcp_recvmsg(struct kiocb *iocb, struct sock *sk, struct msghdr *msg,
copied
=
-
EAGAIN
;
copied
=
-
EAGAIN
;
break
;
break
;
}
}
if
(
signal_pending
(
current
))
{
copied
=
sock_intr_errno
(
timeo
);
break
;
}
}
}
cleanup_rbuf
(
sk
,
copied
);
cleanup_rbuf
(
sk
,
copied
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment