Do not panic if no addresses were found

This commit is contained in:
9seconds
2026-02-26 12:31:30 +01:00
parent 9c122f942f
commit 449f84133a
2 changed files with 4 additions and 1 deletions
+3
View File
@@ -252,6 +252,9 @@ func (p *Proxy) doTelegramCall(ctx *streamContext) error {
if err != nil {
return fmt.Errorf("no addresses to call: %w", err)
}
if conn == nil {
return fmt.Errorf("no available addresses for DC %d", ctx.dc)
}
tgConn, err := foundAddr.Obfuscator.SendHandshake(conn, ctx.dc)
if err != nil {