aboutsummaryrefslogtreecommitdiffstats
path: root/net/ipv4/tcp.c
diff options
context:
space:
mode:
Diffstat (limited to 'net/ipv4/tcp.c')
-rw-r--r--net/ipv4/tcp.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/net/ipv4/tcp.c b/net/ipv4/tcp.c
index dbb08140cdc9..6baa6dc1b13b 100644
--- a/net/ipv4/tcp.c
+++ b/net/ipv4/tcp.c
@@ -1937,6 +1937,11 @@ static int tcp_inq_hint(struct sock *sk)
1937 inq = tp->rcv_nxt - tp->copied_seq; 1937 inq = tp->rcv_nxt - tp->copied_seq;
1938 release_sock(sk); 1938 release_sock(sk);
1939 } 1939 }
1940 /* After receiving a FIN, tell the user-space to continue reading
1941 * by returning a non-zero inq.
1942 */
1943 if (inq == 0 && sock_flag(sk, SOCK_DONE))
1944 inq = 1;
1940 return inq; 1945 return inq;
1941} 1946}
1942 1947