mirror of
https://github.com/v2fly/v2ray-core.git
synced 2024-12-22 01:57:12 -05:00
fix config in http
This commit is contained in:
parent
2d233295e6
commit
48f1d34ca5
@ -21,11 +21,11 @@ type HttpProxyServer struct {
|
|||||||
sync.Mutex
|
sync.Mutex
|
||||||
accepting bool
|
accepting bool
|
||||||
space app.Space
|
space app.Space
|
||||||
config Config
|
config *Config
|
||||||
tcpListener *net.TCPListener
|
tcpListener *net.TCPListener
|
||||||
}
|
}
|
||||||
|
|
||||||
func NewHttpProxyServer(space app.Space, config Config) *HttpProxyServer {
|
func NewHttpProxyServer(space app.Space, config *Config) *HttpProxyServer {
|
||||||
return &HttpProxyServer{
|
return &HttpProxyServer{
|
||||||
space: space,
|
space: space,
|
||||||
config: config,
|
config: config,
|
||||||
|
@ -9,6 +9,6 @@ import (
|
|||||||
func init() {
|
func init() {
|
||||||
internal.MustRegisterInboundConnectionHandlerCreator("http",
|
internal.MustRegisterInboundConnectionHandlerCreator("http",
|
||||||
func(space app.Space, rawConfig interface{}) (proxy.InboundConnectionHandler, error) {
|
func(space app.Space, rawConfig interface{}) (proxy.InboundConnectionHandler, error) {
|
||||||
return NewHttpProxyServer(space, rawConfig.(Config)), nil
|
return NewHttpProxyServer(space, rawConfig.(*Config)), nil
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user