[all-commits] [llvm/llvm-project] 96f3a6: [llvm-objcopy] --dump-section: error if '=' is mis...

Fangrui Song via All-commits all-commits at lists.llvm.org
Tue May 4 17:31:15 PDT 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 96f3a6307670bc6c79c44bf01be507dd8a1af30e
      https://github.com/llvm/llvm-project/commit/96f3a6307670bc6c79c44bf01be507dd8a1af30e
  Author: Fangrui Song <i at maskray.me>
  Date:   2021-05-04 (Tue, 04 May 2021)

  Changed paths:
    M llvm/test/tools/llvm-objcopy/ELF/dump-section.test
    M llvm/tools/llvm-objcopy/CopyConfig.cpp

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

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).

Reviewed By: jhenderson

Differential Revision: https://reviews.llvm.org/D101697




More information about the All-commits mailing list