Closed
Description
In rollup #72681, the long-linker-command-lines test failed on macOS x86_64-apple with:
error: could not exec the linker `/Users/runner/runners/2.168.2/work/1/s/build/x86_64-apple-darwin/test/run-make-fulldeps/long-linker-command-lines/long-linker-command-lines/foo`
|
= note: nul byte found in provided data
= note: "/Users/runner/runners/2.168.2/work/1/s/build/x86_64-apple-darwin/test/run-make-fulldeps/long-linker-command-lines/long-linker-command-lines/foo" "-m64" "-L" "/Users/runner/runners/2.168.2/w...
error: aborting due to previous error
', foo.rs:76:13
Which means that rustc attempted to invoke a linker, but incorrectly provided a string with a null byte to a Command
through arg
, cwd
, env
.
Hypothetical reproduction steps (would be nice to attempt to reproduce on macOS):
$ cd src/test/run-make-fulldeps/long-linker-command-lines
$ rustc -gO foo.rs
# NOTE: Expects TMPDIR environment variable to be set.
$ while ./foo; do :; done