Author David.Edelsohn
Recipients David.Edelsohn
Date 2013-06-26.22:18:43
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1372285124.04.0.171759538272.issue18308@psf.upfronthosting.co.za>
In-reply-to
Content
The current arguments to checkRecvmsgAddress() are the sockaddrs, so it does not know the protocol family. One potential patch to infer the family and apply the correct test is:

diff -r 035d8fed07ad Lib/test/test_socket.py
--- a/Lib/test/test_socket.py   Tue Jun 25 22:54:35 2013 +0200
+++ b/Lib/test/test_socket.py   Wed Jun 26 15:16:31 2013 -0700
@@ -1809,7 +1809,10 @@
     def checkRecvmsgAddress(self, addr1, addr2):
         # Called to compare the received address with the address of
         # the peer.
-        self.assertEqual(addr1, addr2)
+        if len(addr1) > 3 or len(addr2) > 3:
+            self.assertEqual(addr1[:-1], addr2[:-1])
+        else:
+            self.assertEqual(addr1, addr2)
 
     # Flags that are normally unset in msg_flags
     msg_flags_common_unset = 0
History
Date User Action Args
2013-06-26 22:18:44David.Edelsohnsetrecipients: + David.Edelsohn
2013-06-26 22:18:44David.Edelsohnsetmessageid: <1372285124.04.0.171759538272.issue18308@psf.upfronthosting.co.za>
2013-06-26 22:18:44David.Edelsohnlinkissue18308 messages
2013-06-26 22:18:43David.Edelsohncreate