Skip to content

Commit ae231ce

Browse files
committed
concurrency: link-checker: mentioned shared Receiver pattern
1 parent 7e2b110 commit ae231ce

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/concurrency/sync-exercises/link-checker.rs

+1
Original file line numberDiff line numberDiff line change
@@ -105,6 +105,7 @@ fn spawn_crawler_threads(
105105
result_sender: mpsc::Sender<CrawlResult>,
106106
thread_count: u32,
107107
) {
108+
// To multiplex the non-cloneable Receiver, wrap it in Arc<Mutex<_>>.
108109
let command_receiver = Arc::new(Mutex::new(command_receiver));
109110

110111
for _ in 0..thread_count {

0 commit comments

Comments
 (0)