Page MenuHomeFreeBSD

strip/objcopy: handle empty file as unknown
ClosedPublic

Authored by emaste on Oct 25 2021, 8:10 PM.
Tags
None
Referenced Files
Unknown Object (File)
Tue, May 20, 8:24 AM
Unknown Object (File)
Tue, May 20, 5:53 AM
Unknown Object (File)
Tue, May 13, 7:09 PM
Unknown Object (File)
Wed, May 7, 8:34 PM
Unknown Object (File)
Apr 20 2025, 10:46 PM
Unknown Object (File)
Apr 19 2025, 1:39 PM
Unknown Object (File)
Apr 17 2025, 12:47 AM
Unknown Object (File)
Apr 14 2025, 8:03 AM
Subscribers

Details

Summary

Previously strip reported a somewhat cryptic strip: elf_begin() failed: Invalid argument for an empty file. Instead handle it as we do with an unknown file format.

LLVM reports error: 'file': The file was not recognized as a valid object file for both empty and unknown files. GNU strip produces no output for empty files.

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable