diff options
Diffstat (limited to 'src/libstd/old_io/net/udp.rs')
| -rw-r--r-- | src/libstd/old_io/net/udp.rs | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/src/libstd/old_io/net/udp.rs b/src/libstd/old_io/net/udp.rs index 8dc19047de0..7171198e7a4 100644 --- a/src/libstd/old_io/net/udp.rs +++ b/src/libstd/old_io/net/udp.rs @@ -186,7 +186,7 @@ mod test { use old_io::test::*; use old_io::{IoError, TimedOut, PermissionDenied, ShortWrite}; use super::*; - use thread::Thread; + use thread; // FIXME #11530 this fails on android because tests are run as root #[cfg_attr(any(windows, target_os = "android"), ignore)] @@ -206,7 +206,7 @@ mod test { let (tx1, rx1) = channel(); let (tx2, rx2) = channel(); - let _t = Thread::spawn(move|| { + let _t = thread::spawn(move|| { match UdpSocket::bind(client_ip) { Ok(ref mut client) => { rx1.recv().unwrap(); @@ -241,7 +241,7 @@ mod test { let client_ip = next_test_ip6(); let (tx, rx) = channel::<()>(); - let _t = Thread::spawn(move|| { + let _t = thread::spawn(move|| { match UdpSocket::bind(client_ip) { Ok(ref mut client) => { rx.recv().unwrap(); @@ -298,7 +298,7 @@ mod test { let mut sock1 = UdpSocket::bind(addr1).unwrap(); let sock2 = UdpSocket::bind(addr2).unwrap(); - let _t = Thread::spawn(move|| { + let _t = thread::spawn(move|| { let mut sock2 = sock2; let mut buf = [0, 0]; assert_eq!(sock2.recv_from(&mut buf), Ok((1, addr1))); @@ -310,7 +310,7 @@ mod test { let (tx1, rx1) = channel(); let (tx2, rx2) = channel(); - let _t = Thread::spawn(move|| { + let _t = thread::spawn(move|| { let mut sock3 = sock3; rx1.recv().unwrap(); sock3.send_to(&[1], addr2).unwrap(); @@ -331,7 +331,7 @@ mod test { let (tx1, rx) = channel(); let tx2 = tx1.clone(); - let _t = Thread::spawn(move|| { + let _t = thread::spawn(move|| { let mut sock2 = sock2; sock2.send_to(&[1], addr1).unwrap(); rx.recv().unwrap(); @@ -342,7 +342,7 @@ mod test { let sock3 = sock1.clone(); let (done, rx) = channel(); - let _t = Thread::spawn(move|| { + let _t = thread::spawn(move|| { let mut sock3 = sock3; let mut buf = [0, 0]; sock3.recv_from(&mut buf).unwrap(); @@ -366,7 +366,7 @@ mod test { let (tx, rx) = channel(); let (serv_tx, serv_rx) = channel(); - let _t = Thread::spawn(move|| { + let _t = thread::spawn(move|| { let mut sock2 = sock2; let mut buf = [0, 1]; @@ -382,7 +382,7 @@ mod test { let (done, rx) = channel(); let tx2 = tx.clone(); - let _t = Thread::spawn(move|| { + let _t = thread::spawn(move|| { let mut sock3 = sock3; match sock3.send_to(&[1], addr2) { Ok(..) => { let _ = tx2.send(()); } @@ -410,7 +410,7 @@ mod test { let (tx, rx) = channel(); let (tx2, rx2) = channel(); - let _t = Thread::spawn(move|| { + let _t = thread::spawn(move|| { let mut a = a2; assert_eq!(a.recv_from(&mut [0]), Ok((1, addr1))); assert_eq!(a.send_to(&[0], addr1), Ok(())); |
