@@ -7395,7 +7395,9 @@ def test_send_recv_fds_with_addrs(self):
73957395 self ._test_pipe (fds [0 ], wfd , MSG )
73967396
73977397 @requireAttrs (socket , "MSG_PEEK" )
7398- @unittest .skipUnless (sys .platform in ("linux" , "android" ), "works on Linux" )
7398+ @unittest .skipUnless (sys .platform in ("linux" , "android" , "darwin" ),
7399+ "MSG_PEEK with SCM_RIGHTS not known to work on this "
7400+ "platform" )
73997401 def test_recv_fds_peek (self ):
74007402 rfd , wfd = os .pipe ()
74017403 self .addCleanup (os .close , rfd )
@@ -7408,7 +7410,7 @@ def test_recv_fds_peek(self):
74087410
74097411 # peek message on sock2
74107412 peek_len = len (MSG ) // 2
7411- msg , fds , flags , addr = socket .recv_fds (sock2 , peek_len , 1 ,
7413+ msg , fds , flags , addr = socket .recv_fds (sock2 , peek_len , 2 ,
74127414 flags = socket .MSG_PEEK )
74137415 self ._cleanup_fds (fds )
74147416
@@ -7421,7 +7423,7 @@ def test_recv_fds_peek(self):
74217423 self ._test_pipe (fds [0 ], wfd , MSG )
74227424
74237425 # will raise BlockingIOError if MSG_PEEK didn't work
7424- msg , fds , flags , addr = socket .recv_fds (sock2 , len (MSG ), 1 )
7426+ msg , fds , flags , addr = socket .recv_fds (sock2 , len (MSG ), 2 )
74257427 self ._cleanup_fds (fds )
74267428
74277429 self .assertEqual (msg , MSG )
0 commit comments