mirror of
https://github.com/MetaCubeX/mihomo.git
synced 2024-11-16 11:42:43 +08:00
Chore: more detailed error when dial failed
This commit is contained in:
parent
00ecdf0afc
commit
f0ecf5b8d4
|
@ -218,7 +218,7 @@ func handleUDPConn(packet *inbound.PacketAdapter) {
|
||||||
|
|
||||||
rawPc, err := proxy.DialUDP(metadata)
|
rawPc, err := proxy.DialUDP(metadata)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
log.Warnln("[UDP] dial %s error: %s", proxy.Name(), err.Error())
|
log.Warnln("[UDP] dial %s to %s error: %s", proxy.Name(), metadata.String(), err.Error())
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
pc := newUDPTracker(rawPc, DefaultManager, metadata, rule)
|
pc := newUDPTracker(rawPc, DefaultManager, metadata, rule)
|
||||||
|
@ -257,13 +257,13 @@ func handleTCPConn(localConn C.ServerAdapter) {
|
||||||
|
|
||||||
proxy, rule, err := resolveMetadata(metadata)
|
proxy, rule, err := resolveMetadata(metadata)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
log.Warnln("Parse metadata failed: %v", err)
|
log.Warnln("[Metadata] parse failed: %s", err.Error())
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
remoteConn, err := proxy.Dial(metadata)
|
remoteConn, err := proxy.Dial(metadata)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
log.Warnln("dial %s error: %s", proxy.Name(), err.Error())
|
log.Warnln("dial %s to %s error: %s", proxy.Name(), metadata.String(), err.Error())
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
remoteConn = newTCPTracker(remoteConn, DefaultManager, metadata, rule)
|
remoteConn = newTCPTracker(remoteConn, DefaultManager, metadata, rule)
|
||||||
|
|
Loading…
Reference in New Issue
Block a user