]> git.sesse.net Git - vlc/commit
net_Read(): truly ignore POLLRDHUP
authorRémi Denis-Courmont <remi@remlab.net>
Wed, 18 Apr 2012 13:35:12 +0000 (16:35 +0300)
committerRémi Denis-Courmont <remi@remlab.net>
Wed, 18 Apr 2012 13:39:26 +0000 (16:39 +0300)
commit546cdb234c30d12b4dffbcddf16d9c150091ff28
tree5b594900fd94cd4817b53516130940cb0276f72e
parentf340bff6580aad0f97c0f7513f8c6733fe82fc05
net_Read(): truly ignore POLLRDHUP

The Linux TCP stack sets POLLRDHUP as soon as the FIN packet is
received. If there is some unread data in the receive buffer, it would
be discarded. Then upper layer protocol typically fail.

This can happen with HTTP/1.1 "Connection: close" or with HTTP/1.0
in particular.

Pointed-out-by: Jean-Baptiste Kempf <jb@videolan.org>
src/network/io.c