mirror of
https://github.com/MetaCubeX/mihomo.git
synced 2026-01-05 20:59:01 +08:00
24 lines
313 B
Go
24 lines
313 B
Go
package gun
|
|
|
|
import (
|
|
"golang.org/x/net/http2"
|
|
"net"
|
|
)
|
|
|
|
type TransportWrap struct {
|
|
*http2.Transport
|
|
}
|
|
|
|
type netAddr struct {
|
|
remoteAddr net.Addr
|
|
localAddr net.Addr
|
|
}
|
|
|
|
func (addr netAddr) RemoteAddr() net.Addr {
|
|
return addr.remoteAddr
|
|
}
|
|
|
|
func (addr netAddr) LocalAddr() net.Addr {
|
|
return addr.localAddr
|
|
}
|