http://www.python.org/dev/buildbot/all/builders/x86 FreeBSD 7.2 3.x/builds/2129/steps/test/logs/stdio """ ====================================================================== FAIL: testRecvmsgTrunc (test.test_socket.RecvmsgUDPTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/usr/home/db3l/buildarea/3.x.bolen-freebsd7/build/Lib/test/test_socket.py", line 1666, in testRecvmsgTrunc self.checkFlags(flags, eor=False) File "/usr/home/db3l/buildarea/3.x.bolen-freebsd7/build/Lib/test/test_socket.py", line 1354, in checkFlags self.assertEqual(flags & mask, checkset & mask) AssertionError: 0 != 16 ====================================================================== FAIL: testRecvmsgTrunc (test.test_socket.RecvmsgIntoUDPTest) ---------------------------------------------------------------------- Traceback (most recent call last): File "/usr/home/db3l/buildarea/3.x.bolen-freebsd7/build/Lib/test/test_socket.py", line 1666, in testRecvmsgTrunc self.checkFlags(flags, eor=False) File "/usr/home/db3l/buildarea/3.x.bolen-freebsd7/build/Lib/test/test_socket.py", line 1354, in checkFlags self.assertEqual(flags & mask, checkset & mask) AssertionError: 0 != 16 """ This fails because MSG_TRUNC isn't always set in msg_flags when receiving a truncated datagram with recvmsg(). It's a known kernel bug (http://svnweb.freebsd.org/base?view=revision&revision=211030), fixed in FreeBSD 8 (and the test indeed passes on the FreeBSD 8 buildbot). The patch attached skips the test on FreeBSD < 8 (and introduces @support.requires_freebsd_version).
@requires_freebsd_version should be factorized with @requires_linux_version. Can we workaround FreeBSD (< 8) bug in C/Python? Or should we remove the function on FreeBSD < 8?
> @requires_freebsd_version should be factorized with > @requires_linux_version. Patches attached. > Can we workaround FreeBSD (< 8) bug in C/Python? Not really. > Or should we remove the function on FreeBSD < 8? There's really no reason to do that (and it's really a minor bug).