mirror of
https://github.com/nadoo/glider.git
synced 2025-04-22 04:02:07 +08:00
log next dialer in verbose mode.
Print out the next dialer is useful when a particular website does not load completely, and it helps when updating config rules.
This commit is contained in:
parent
f02935d484
commit
3ed90f1d65
@ -99,12 +99,16 @@ func (rd *Dialer) NextDialer(dstAddr string) proxy.Dialer {
|
||||
|
||||
// Dial dials to targer addr and return a conn
|
||||
func (rd *Dialer) Dial(network, addr string) (net.Conn, error) {
|
||||
return rd.NextDialer(addr).Dial(network, addr)
|
||||
d := rd.NextDialer(addr)
|
||||
log.F("[Dial] %s => %s", addr, d.Addr())
|
||||
return d.Dial(network, addr)
|
||||
}
|
||||
|
||||
// DialUDP connects to the given address via the proxy
|
||||
func (rd *Dialer) DialUDP(network, addr string) (pc net.PacketConn, writeTo net.Addr, err error) {
|
||||
return rd.NextDialer(addr).DialUDP(network, addr)
|
||||
d := rd.NextDialer(addr)
|
||||
log.F("[DialUDP] %s => %s", addr, d.Addr())
|
||||
return d.DialUDP(network, addr)
|
||||
}
|
||||
|
||||
// AddDomainIP used to update ipMap rules according to domainMap rule
|
||||
|
Loading…
Reference in New Issue
Block a user