We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 57c4c28 commit 0b9ad6eCopy full SHA for 0b9ad6e
src/libstd/net/tcp.rs
@@ -1187,9 +1187,13 @@ mod tests {
1187
#[test]
1188
fn double_bind() {
1189
each_ip(&mut |addr| {
1190
- let _listener = t!(TcpListener::bind(&addr));
+ let listener1 = t!(TcpListener::bind(&addr));
1191
match TcpListener::bind(&addr) {
1192
- Ok(..) => panic!(),
+ Ok(listener2) => panic!(
1193
+ "This system (perhaps due to options set by TcpListener::bind) \
1194
+ permits double binding: {:?} and {:?}",
1195
+ listener1, listener2
1196
+ ),
1197
Err(e) => {
1198
assert!(e.kind() == ErrorKind::ConnectionRefused ||
1199
e.kind() == ErrorKind::Other ||
0 commit comments