]> git.proxmox.com Git - mirror_qemu.git/commit
slirp: handle deferred ECONNREFUSED on non-blocking TCP sockets
authorSteven Luo <steven+qemu@steven676.net>
Thu, 7 Apr 2016 05:04:55 +0000 (22:04 -0700)
committerSamuel Thibault <samuel.thibault@ens-lyon.org>
Thu, 7 Apr 2016 11:02:05 +0000 (13:02 +0200)
commit6625d83a6eb3b51a622d72adce713cab75cbf2e7
treecf4b63d2e2500003ead1ddd06ef318ce79661160
parent27d92ebc5ed1bb0b518d0ebc4c609182ad20a799
slirp: handle deferred ECONNREFUSED on non-blocking TCP sockets

slirp currently only handles ECONNREFUSED in the case where connect()
returns immediately with that error; since we use non-blocking sockets,
most of the time we won't receive the error until we later try to read
from the socket.  Ensure that we deliver the appropriate RST to the
guest in this case.

Signed-off-by: Steven Luo <steven+qemu@steven676.net>
Reviewed-by: Edgar E. Iglesias <edgar.iglesias@xilinx.com>
Signed-off-by: Samuel Thibault <samuel.thibault@ens-lyon.org>
slirp/socket.c
slirp/tcp_input.c