In the following snippet:
let mut accept = sock.listen().unwrap();
futures::join!(
async {
let next = accept.next().await.unwrap();
assert_eq!(next.get_address_family(), sock.get_address_family());
assert_eq!(next.get_keep_alive_enabled(), sock.get_keep_alive_enabled());
assert_eq!(
next.get_keep_alive_idle_time(),
sock.get_keep_alive_idle_time()
);
assert_eq!(
next.get_keep_alive_interval(),
sock.get_keep_alive_interval()
);
assert_eq!(next.get_keep_alive_count(), sock.get_keep_alive_count());
assert_eq!(next.get_hop_limit(), sock.get_hop_limit());
// The following asserts fail.
assert_eq!(
next.get_receive_buffer_size(),
sock.get_receive_buffer_size()
);
assert_eq!(next.get_send_buffer_size(), sock.get_send_buffer_size());
},
async {
client.connect(local_addr).await.unwrap();
}
);
The values for get_receive_buffer_size() and get_send_buffer_size() are different between the listener and the handler socket.
According to the spec:
The following properties are inherited from the listener socket:
address-family
keep-alive-enabled
keep-alive-idle-time
keep-alive-interval
keep-alive-count
hop-limit
receive-buffer-size
send-buffer-size
Platform specific information:
- On ubuntu, only the comparison between
get_send_buffer_size is failing.
- On macOS, both comparisons are failing (
get_receive_buffer_size / get_send_buffer_size)
- On Windows the test behaves as expected.
In the following snippet:
The values for
get_receive_buffer_size()andget_send_buffer_size()are different between the listener and the handler socket.According to the spec:
The following properties are inherited from the listener socket:
address-familykeep-alive-enabledkeep-alive-idle-timekeep-alive-intervalkeep-alive-counthop-limitreceive-buffer-sizesend-buffer-sizePlatform specific information:
get_send_buffer_sizeis failing.get_receive_buffer_size/get_send_buffer_size)