Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 04 Sep 2017 00:21:24 +0000
From:      bugzilla-noreply@freebsd.org
To:        freebsd-bugs@FreeBSD.org
Subject:   [Bug 222039] Incorrect 32-bit emulation of SCM_BINTIME and SCM_TIMESTAMP
Message-ID:  <bug-222039-8@https.bugs.freebsd.org/bugzilla/>

next in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D222039

            Bug ID: 222039
           Summary: Incorrect 32-bit emulation of SCM_BINTIME and
                    SCM_TIMESTAMP
           Product: Base System
           Version: CURRENT
          Hardware: Any
                OS: Any
            Status: New
          Severity: Affects Only Me
          Priority: ---
         Component: kern
          Assignee: freebsd-bugs@FreeBSD.org
          Reporter: asomers@FreeBSD.org

I have seen two examples of programs that use SCM_TIMESTAMP and/or SCM_BINT=
IME
that work correctly on amd64 or i386, but fail when the i386 binaries are
executed on an amd64 kernel.  The easiest way to reproduce this problem is:

i386_host $ cd /usr/src/tools/regression/sockets/unix_cmsg
i386_host $ make
i386_host $ ./unix_cmsg
i386_host $ # Observe that everything passes
i386_host $ # somehow transfer the unix_cmsg binary to an amd64 system
amd64_host $ ./unix_cmsg
Running tests for SOCK_STREAM sockets:
  1: Sending, receiving cmsgcred
  2: Receiving sockcred (listening socket)
  3: Receiving sockcred (accepted socket)
  4: Sending cmsgcred, receiving sockcred
  5: Sending, receiving timeval
SERVER: msghdr.msg_flags has MSG_CTRUNC
  6: Sending, receiving bintime
SERVER: msghdr.msg_flags has MSG_CTRUNC
  7: Check cmsghdr.cmsg_len
  8: Check LOCAL_PEERCRED socket option
-- 2 tests failed!
Running tests for SOCK_DGRAM sockets:
  1: Sending, receiving cmsgcred
  2: Receiving sockcred
  3: Sending cmsgcred, receiving sockcred
  4: Sending, receiving timeval
SERVER: msghdr.msg_flags has MSG_CTRUNC
  5: Sending, receiving bintime
SERVER: msghdr.msg_flags has MSG_CTRUNC
  6: Check cmsghdr.cmsg_len
-- 2 tests failed!

--=20
You are receiving this mail because:
You are the assignee for the bug.=



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-222039-8>