We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
在ikcp_input函数中,处理IKCP_CMD_ACK这段逻辑,在更新maxack时,由于比较ts与latest_ts使用的是>,会导致maxack未更新到最新的sn 举例:在一次ikcp_flush中,发送了4个包,则这4个包的ts都是一致的,假设这4个包的sn分别是1,2,3,4,此时如果对端只收到了sn为2,4的包,并返回了ack,本地在处理ack时,第1个ack会将maxack设置为2,latest_ts设置为ts,而第2个ack由于ts一致,导致无法将maxack更新到4,因此在ikcp_parse_fastack中更新faskack时,sn为3的包不会触发fastack++ 因此,对比latest_ts的逻辑应该需要使用>=比较合理?
ikcp_input
IKCP_CMD_ACK
maxack
ts
latest_ts
>
sn
ikcp_flush
ikcp_parse_fastack
faskack
fastack++
>=
The text was updated successfully, but these errors were encountered:
No branches or pull requests
在
ikcp_input
函数中,处理IKCP_CMD_ACK
这段逻辑,在更新maxack
时,由于比较ts
与latest_ts
使用的是>
,会导致maxack
未更新到最新的sn
举例:在一次
ikcp_flush
中,发送了4个包,则这4个包的ts
都是一致的,假设这4个包的sn
分别是1,2,3,4,此时如果对端只收到了sn
为2,4的包,并返回了ack,本地在处理ack时,第1个ack会将maxack
设置为2,latest_ts
设置为ts
,而第2个ack由于ts
一致,导致无法将maxack
更新到4,因此在ikcp_parse_fastack
中更新faskack
时,sn
为3的包不会触发fastack++
因此,对比
latest_ts
的逻辑应该需要使用>=
比较合理?The text was updated successfully, but these errors were encountered: