From c45a5033b95b532cbfea1e5f662dd64c9c2826ac Mon Sep 17 00:00:00 2001 From: QuantumEntangledAndy Date: Thu, 3 Aug 2023 18:59:59 +0700 Subject: [PATCH] fmt --- crates/core/src/bc_protocol.rs | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/crates/core/src/bc_protocol.rs b/crates/core/src/bc_protocol.rs index 74f1d6b..3447228 100644 --- a/crates/core/src/bc_protocol.rs +++ b/crates/core/src/bc_protocol.rs @@ -205,6 +205,13 @@ impl BcCamera { }, if allow_local => v, v = async { let reg_result; + // Registration is looped as it seems that reolink + // only updates the registration lazily when someone attempts + // to connect. The first few connects fails until the server data + // is updated + // + // We loop infinitly and allow the caller to timeout at the + // interval they desire loop { tokio::task::yield_now().await; if let Ok(result) = discovery.get_registration(uid).await {