libutp
libutp copied to clipboard
Try fix for #92
We need to process the ST_FIN packet even if the connection has not been fully established yet.
I believe the correct fix would be to consider ST_FIN as connection completion (as well as ST_DATA):
https://github.com/bittorrent/libutp/blob/master/utp_internal.cpp#L2160
if ((pk_flags == ST_DATA || pk_flags == ST_FIN) && conn->state == CS_SYN_RECV) {
conn->state = CS_CONNECTED;
}