| Submitter | Eric Dumazet |
|---|---|
| Date | Jan. 9, 2009, 5:57 p.m. |
| Message ID | <49679012.3000702@cosmosbay.com> |
| Download | mbox | patch |
| Permalink | /patch/17561/ |
| State | RFC |
| Delegated to: | David Miller |
| Headers | show |
Comments
Patch
diff --git a/net/ipv4/tcp.c b/net/ipv4/tcp.c index bd6ff90..15bd67b 100644 --- a/net/ipv4/tcp.c +++ b/net/ipv4/tcp.c @@ -533,6 +533,9 @@ static int __tcp_splice_read(struct sock *sk, struct tcp_splice_state *tss) .arg.data = tss, }; + if (tss->flags & SPLICE_F_NONBLOCK) + rd_desc.count = 1; /* we want as many segments as possible */ + return tcp_read_sock(sk, &rd_desc, tcp_splice_data_recv); }