From f9ef93dd9c559303ef1c645cd3b0bcc715b57630 Mon Sep 17 00:00:00 2001 From: boqiu <82121246@qq.com> Date: Thu, 24 Oct 2024 19:29:08 +0800 Subject: [PATCH] Mark peer connected if FileAnnouncement RPC message received --- node/sync/src/controllers/serial.rs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/node/sync/src/controllers/serial.rs b/node/sync/src/controllers/serial.rs index 876f6d7..7343444 100644 --- a/node/sync/src/controllers/serial.rs +++ b/node/sync/src/controllers/serial.rs @@ -89,6 +89,9 @@ pub struct SerialSyncController { /// Cache for storing and serving gossip messages. file_location_cache: Arc, + + /// Whether to find files from neighbors only. + neighbors_only: bool, } impl SerialSyncController { @@ -115,6 +118,7 @@ impl SerialSyncController { ctx, store, file_location_cache, + neighbors_only: true, } }