use yamux instead of smux

This commit is contained in:
fatedier
2018-04-25 02:34:07 +08:00
parent 69919e8ef9
commit 976cf3e9f8
33 changed files with 3567 additions and 1755 deletions

View File

@ -29,7 +29,7 @@ import (
"github.com/fatedier/frp/utils/version"
"github.com/fatedier/frp/utils/vhost"
"github.com/xtaci/smux"
fmux "github.com/hashicorp/yamux"
)
const (
@ -234,7 +234,7 @@ func (svr *Service) HandleListener(l frpNet.Listener) {
}
if g.GlbServerCfg.TcpMux {
session, err := smux.Server(frpConn, nil)
session, err := fmux.Server(frpConn, nil)
if err != nil {
log.Warn("Failed to create mux connection: %v", err)
frpConn.Close()