feat: inbound support Hysteria2

This commit is contained in:
wwqgtxx
2023-09-21 14:52:26 +08:00
parent 6c3b973748
commit 233eeb0b38
8 changed files with 315 additions and 6 deletions

View File

@ -117,12 +117,12 @@ type HysteriaOption struct {
func (c *HysteriaOption) Speed() (uint64, uint64, error) {
var up, down uint64
up = stringToBps(c.Up)
up = StringToBps(c.Up)
if up == 0 {
return 0, 0, fmt.Errorf("invaild upload speed: %s", c.Up)
}
down = stringToBps(c.Down)
down = StringToBps(c.Down)
if down == 0 {
return 0, 0, fmt.Errorf("invaild download speed: %s", c.Down)
}