mirror of
https://github.com/XTLS/Xray-core.git
synced 2025-06-17 21:59:47 +03:00
Fix
This commit is contained in:
@ -374,7 +374,6 @@ func (w *PacketWriter) WriteMultiBuffer(mb buf.MultiBuffer) error {
|
|||||||
if w.Handler.config.hasStrategy() && b.UDP.Address.Family().IsDomain() {
|
if w.Handler.config.hasStrategy() && b.UDP.Address.Family().IsDomain() {
|
||||||
if ip := w.resolvedUDPAddr[b.UDP.Address.Domain()]; ip != nil {
|
if ip := w.resolvedUDPAddr[b.UDP.Address.Domain()]; ip != nil {
|
||||||
b.UDP.Address = ip
|
b.UDP.Address = ip
|
||||||
}
|
|
||||||
} else {
|
} else {
|
||||||
ip := w.Handler.resolveIP(w.Context, b.UDP.Address.Domain(), nil)
|
ip := w.Handler.resolveIP(w.Context, b.UDP.Address.Domain(), nil)
|
||||||
if ip != nil {
|
if ip != nil {
|
||||||
@ -382,6 +381,7 @@ func (w *PacketWriter) WriteMultiBuffer(mb buf.MultiBuffer) error {
|
|||||||
w.resolvedUDPAddr[b.UDP.Address.Domain()] = ip
|
w.resolvedUDPAddr[b.UDP.Address.Domain()] = ip
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
destAddr, _ := net.ResolveUDPAddr("udp", b.UDP.NetAddr())
|
destAddr, _ := net.ResolveUDPAddr("udp", b.UDP.NetAddr())
|
||||||
if destAddr == nil {
|
if destAddr == nil {
|
||||||
b.Release()
|
b.Release()
|
||||||
|
Reference in New Issue
Block a user