mirror of
https://github.com/MHSanaei/3x-ui.git
synced 2026-09-24 08:12:19 +07:00
kcp: mtu and tti
Add KCP-specific fields mtu and tti to inbound stream handling in web/assets/js/model/inbound.js. The changes add obj.mtu/obj.tti when serializing the kcp stream and set params for mtu and tti in the various KCP parameter-building branches so these values are preserved and transmitted where KCP is used.
This commit is contained in:
@@ -1566,6 +1566,8 @@ class Inbound extends XrayCommonClass {
|
|||||||
}
|
}
|
||||||
} else if (network === 'kcp') {
|
} else if (network === 'kcp') {
|
||||||
const kcp = this.stream.kcp;
|
const kcp = this.stream.kcp;
|
||||||
|
obj.mtu = kcp.mtu;
|
||||||
|
obj.tti = kcp.tti;
|
||||||
} else if (network === 'ws') {
|
} else if (network === 'ws') {
|
||||||
const ws = this.stream.ws;
|
const ws = this.stream.ws;
|
||||||
obj.path = ws.path;
|
obj.path = ws.path;
|
||||||
@@ -1626,6 +1628,8 @@ class Inbound extends XrayCommonClass {
|
|||||||
break;
|
break;
|
||||||
case "kcp":
|
case "kcp":
|
||||||
const kcp = this.stream.kcp;
|
const kcp = this.stream.kcp;
|
||||||
|
params.set("mtu", kcp.mtu);
|
||||||
|
params.set("tti", kcp.tti);
|
||||||
break;
|
break;
|
||||||
case "ws":
|
case "ws":
|
||||||
const ws = this.stream.ws;
|
const ws = this.stream.ws;
|
||||||
@@ -1727,6 +1731,8 @@ class Inbound extends XrayCommonClass {
|
|||||||
break;
|
break;
|
||||||
case "kcp":
|
case "kcp":
|
||||||
const kcp = this.stream.kcp;
|
const kcp = this.stream.kcp;
|
||||||
|
params.set("mtu", kcp.mtu);
|
||||||
|
params.set("tti", kcp.tti);
|
||||||
break;
|
break;
|
||||||
case "ws":
|
case "ws":
|
||||||
const ws = this.stream.ws;
|
const ws = this.stream.ws;
|
||||||
@@ -1804,6 +1810,8 @@ class Inbound extends XrayCommonClass {
|
|||||||
break;
|
break;
|
||||||
case "kcp":
|
case "kcp":
|
||||||
const kcp = this.stream.kcp;
|
const kcp = this.stream.kcp;
|
||||||
|
params.set("mtu", kcp.mtu);
|
||||||
|
params.set("tti", kcp.tti);
|
||||||
break;
|
break;
|
||||||
case "ws":
|
case "ws":
|
||||||
const ws = this.stream.ws;
|
const ws = this.stream.ws;
|
||||||
|
|||||||
Reference in New Issue
Block a user