mirror of
https://github.com/skywind3000/kcp.git
synced 2025-01-13 20:10:12 +08:00
commit kcp
This commit is contained in:
parent
b3c3a19132
commit
c6d74fbdc2
4
ikcp.c
4
ikcp.c
@ -901,7 +901,7 @@ void ikcp_flush(ikcpcb *kcp)
|
||||
if (kcp->probe & IKCP_ASK_SEND) {
|
||||
seg.cmd = IKCP_CMD_WASK;
|
||||
size = (int)(ptr - buffer);
|
||||
if (size + IKCP_OVERHEAD >= (int)kcp->mtu) {
|
||||
if (size + IKCP_OVERHEAD > (int)kcp->mtu) {
|
||||
ikcp_output(kcp, buffer, size);
|
||||
ptr = buffer;
|
||||
}
|
||||
@ -912,7 +912,7 @@ void ikcp_flush(ikcpcb *kcp)
|
||||
if (kcp->probe & IKCP_ASK_TELL) {
|
||||
seg.cmd = IKCP_CMD_WINS;
|
||||
size = (int)(ptr - buffer);
|
||||
if (size + IKCP_OVERHEAD >= (int)kcp->mtu) {
|
||||
if (size + IKCP_OVERHEAD > (int)kcp->mtu) {
|
||||
ikcp_output(kcp, buffer, size);
|
||||
ptr = buffer;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user