This is an archive of the discontinued LLVM Phabricator instance.

[llvm-objcopy] --dump-section: error if '=' is missing or filename is empty
ClosedPublic

Authored by MaskRay on May 1 2021, 1:18 PM.

Details

Summary

Fix PR45416: the diagnostic when '=' is missing is misleading.
FileOutputBuffer::create returns successfully when the filename is empty
(the temporary file is .tmp%%%%%%%), but FileOutputBuffer::commit will error when
renaming .tmp%%%%%%% to the empty name).

Diff Detail

Event Timeline

MaskRay created this revision.May 1 2021, 1:18 PM
MaskRay requested review of this revision.May 1 2021, 1:18 PM
Herald added a project: Restricted Project. · View Herald TranscriptMay 1 2021, 1:18 PM
jhenderson accepted this revision.May 4 2021, 1:15 AM

Add a link to the PR.

LGTM otherwise.

llvm/tools/llvm-objcopy/CopyConfig.cpp
703

Consider fixing clang-tidy warning whilst you're changing this line.

This revision is now accepted and ready to land.May 4 2021, 1:15 AM
jhenderson added a comment.EditedMay 4 2021, 1:15 AM

Add a link to the PR.

LGTM otherwise.

Apparently, I failed at reading the summary and missed the link there!

MaskRay updated this revision to Diff 342918.May 4 2021, 5:29 PM
MaskRay marked an inline comment as done.

Fix clang-tidy: warning: 'auto Arg' can be declared as 'auto *Arg' [llvm-qualified-auto]

MaskRay edited the summary of this revision. (Show Details)May 4 2021, 5:30 PM
This revision was landed with ongoing or failed builds.May 4 2021, 5:31 PM
This revision was automatically updated to reflect the committed changes.