Skip to content

Commit b4d345c

Browse files
committed
Ignore some uds tests
1 parent f874e10 commit b4d345c

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

library/std/src/os/unix/net/addr.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -240,7 +240,7 @@ impl SocketAddr {
240240

241241
// macOS seems to return a len of 16 and a zeroed sun_path for unnamed addresses
242242
if len == 0
243-
|| (cfg!(not(any(target_os = "linux", target_os = "android")))
243+
|| (cfg!(not(any(target_os = "linux", target_os = "android", target_os = "cygwin")))
244244
&& self.addr.sun_path[0] == 0)
245245
{
246246
AddressKind::Unnamed

library/std/src/os/unix/net/tests.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -289,6 +289,7 @@ fn test_unix_datagram() {
289289

290290
#[test]
291291
#[cfg_attr(target_os = "android", ignore)] // Android SELinux rules prevent creating Unix sockets
292+
#[cfg_attr(target_os = "cygwin", ignore)] // Cygwin autobinds an address
292293
fn test_unnamed_unix_datagram() {
293294
let dir = tmpdir();
294295
let path1 = dir.path().join("sock1");
@@ -307,6 +308,7 @@ fn test_unnamed_unix_datagram() {
307308

308309
#[test]
309310
#[cfg_attr(target_os = "android", ignore)] // Android SELinux rules prevent creating Unix sockets
311+
#[cfg_attr(target_os = "cygwin", ignore)] // Cygwin fails to determine the addr type from recvfrom
310312
fn test_unix_datagram_connect_to_recv_addr() {
311313
let dir = tmpdir();
312314
let path1 = dir.path().join("sock1");
@@ -332,6 +334,7 @@ fn test_unix_datagram_connect_to_recv_addr() {
332334

333335
#[test]
334336
#[cfg_attr(target_os = "android", ignore)] // Android SELinux rules prevent creating Unix sockets
337+
#[cfg_attr(target_os = "cygwin", ignore)] // Cygwin autobinds an address
335338
fn test_connect_unix_datagram() {
336339
let dir = tmpdir();
337340
let path1 = dir.path().join("sock1");

0 commit comments

Comments
 (0)