1
0
mirror of https://github.com/v2fly/v2ray-core.git synced 2025-01-18 07:17:32 -05:00

Fixed: internal.CreateOutboundHandler should return ErrorProxyNotFound if !found instead of ErrorNameExists

This commit is contained in:
Shelikhoo 2016-06-09 09:36:03 +08:00
parent dfe1ac1f2b
commit 3b1f8b553b
No known key found for this signature in database
GPG Key ID: 7791BDB0709ABD21

View File

@ -63,7 +63,7 @@ func CreateInboundHandler(name string, space app.Space, rawConfig []byte) (proxy
func CreateOutboundHandler(name string, space app.Space, rawConfig []byte) (proxy.OutboundHandler, error) { func CreateOutboundHandler(name string, space app.Space, rawConfig []byte) (proxy.OutboundHandler, error) {
creator, found := outboundFactories[name] creator, found := outboundFactories[name]
if !found { if !found {
return nil, ErrorNameExists return nil, ErrorProxyNotFound
} }
if len(rawConfig) > 0 { if len(rawConfig) > 0 {