[llvm-objcopy] [COFF] Fix writing object files without symbols/string table
commit240fa2a2e33ddeba7b13f051157b05889ffa6e19
authorMartin Storsjo <martin@martin.st>
Fri, 11 Jan 2019 13:47:37 +0000 (11 13:47 +0000)
committerMartin Storsjo <martin@martin.st>
Fri, 11 Jan 2019 13:47:37 +0000 (11 13:47 +0000)
treeca26b2e8bba330a3b6e5cac72ab6de4ab99cdf88
parente711cf76da982c217632e2aa527b367bd7f7e1c5
[llvm-objcopy] [COFF] Fix writing object files without symbols/string table

Previously, this was broken - by setting PointerToSymbolTable to zero
but still actually writing the string table length, the object file
header was corrupted.

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@350926 91177308-0d34-0410-b5e6-96231b3b80d8
test/tools/llvm-objcopy/COFF/Inputs/no-symbols.yaml [new file with mode: 0644]
test/tools/llvm-objcopy/COFF/basic-copy.test
tools/llvm-objcopy/COFF/Writer.cpp