Skip to content

Commit fc2076c

Browse files
renato-zannonseanmonstar
authored andcommitted
fix(rustup): use module-level thread functions
1 parent f4a66b3 commit fc2076c

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/server/acceptor.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
use std::thread::{Thread, JoinGuard};
1+
use std::thread::{self, JoinGuard};
22
use std::sync::Arc;
33
use std::sync::mpsc;
44
use net::NetworkAcceptor;
@@ -34,7 +34,7 @@ impl<A: NetworkAcceptor + 'static> AcceptorPool<A> {
3434
for _ in 0..threads { spawn() }
3535

3636
// Spawn the supervisor
37-
Thread::scoped(move || for () in supervisor_rx.iter() { spawn() })
37+
thread::scoped(move || for () in supervisor_rx.iter() { spawn() })
3838
}
3939
}
4040

@@ -43,7 +43,7 @@ where A: NetworkAcceptor + 'static,
4343
F: Fn(<A as NetworkAcceptor>::Stream) + Send + Sync + 'static {
4444
use std::old_io::EndOfFile;
4545

46-
Thread::spawn(move || {
46+
thread::spawn(move || {
4747
let sentinel = Sentinel::new(supervisor, ());
4848

4949
loop {

0 commit comments

Comments
 (0)