Skip to content

CMSG_NXTHDR hits a Bus Error on sparc64-unknown-linux-gnu #1239

Open
@asomers

Description

@asomers
Contributor

PR #1235 adds a new test program to ensure that the cmsg(3) family of functions are correctly implemented on all targets. However, when run in QEMU CMSG_NXTHDR hits a Bus Error. This could be an error in libc's CMSG_NXTHDR implementation for that platform, or it could be an error in Linux's definition of the macro (doesn't work on unaligned buffers or something like that). Less likely would be an error in QEMU. Lacking access to sparc hardware, I didn't investigate further.

https://travis-ci.com/rust-lang/libc/jobs/175199673

Activity

added a commit that references this issue on May 24, 2019
f87d34d
gnzlbg

gnzlbg commented on May 24, 2019

@gnzlbg
Contributor

This reproduces on master, that is, updating the Debian version did not fix this (it did fix the s390x issue).

Chances are, there is a bug in our implementation.

gnzlbg

gnzlbg commented on May 24, 2019

@gnzlbg
Contributor

I'm also seeing sometimes a:

running 5 tests
test t::test_cmsg_data ... ok
error: process didn't exit successfully: `qemu-arm -L /musl-arm /checkout/target/arm-unknown-linux-musleabihf/debug/deps/cmsg-7238071f2e3df703` (signal: 11, SIGSEGV: invalid memory reference)
The command "if [[ $TRAVIS_OS_NAME = "linux" ]] && [[ $BUILD_ONLY != "1" ]]; then sh ci/run-docker.sh $TARGET; else sh ci/run.sh $TARGET; fi" exited with 101.

seg fault on the arm build jobs in the cmsg tests. Restarting the build job fixes the issue, but it might mean that something fishy is going on there.

added this to the 1.x milestone on Aug 29, 2024
added
E-mediumE-medium Call for participation: Medium difficulty. Experience needed to fix: Intermediate.
and removed on Aug 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    E-mediumE-medium Call for participation: Medium difficulty. Experience needed to fix: Intermediate.

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

      Development

      No branches or pull requests

        Participants

        @asomers@gnzlbg@tgross35

        Issue actions

          CMSG_NXTHDR hits a Bus Error on sparc64-unknown-linux-gnu · Issue #1239 · rust-lang/libc