From 4d66d3769d694a2e273eab4bf784f752c52b81c4 Mon Sep 17 00:00:00 2001 From: Siavash Sameni Date: Sun, 12 Apr 2026 14:49:34 +0400 Subject: [PATCH] fix(relay): set peer_relay_fp on originating relay when answer arrives MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The originating relay (where the caller is) never set peer_relay_fp because the call was created locally. When the callee's answer arrived via federation, the cross-relay dispatcher handled it but didn't mark the call as cross-relay. This meant the caller's MediaPathReport was delivered via local hub.send_to() to a peer fingerprint that isn't connected locally — silently dropped. Fix: in the cross-relay answer dispatcher, call reg.set_peer_relay_fp(call_id, Some(origin_relay_fp)) so the originating relay knows to forward MediaPathReport via federation. Co-Authored-By: Claude Opus 4.6 (1M context) --- crates/wzp-relay/src/main.rs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/crates/wzp-relay/src/main.rs b/crates/wzp-relay/src/main.rs index 121d350..04387d3 100644 --- a/crates/wzp-relay/src/main.rs +++ b/crates/wzp-relay/src/main.rs @@ -625,10 +625,13 @@ async fn main() -> anyhow::Result<()> { // then read back everything needed to cross- // wire peer_direct_addr + peer_local_addrs in // the local CallSetup. + // Also set peer_relay_fp so the originating + // relay knows where to forward MediaPathReport. let room_name = format!("call-{call_id}"); let (callee_addr_for_setup, callee_local_for_setup) = { let mut reg = call_registry_d.lock().await; reg.set_active(call_id, accept_mode, room_name.clone()); + reg.set_peer_relay_fp(call_id, Some(origin_relay_fp.clone())); reg.set_callee_reflexive_addr( call_id, callee_reflexive_addr.clone(),