With that change, images built with 'lld-link /debug' always have a
debug directory. If no PDB filename was passed on the command line, then
the filename in the executable is empty.
PDB information would never work anyway if the PDB file name is empty,
so go ahead and try DWARF in that case.
llvm-svn: 280410
const codeview::DebugInfo *DebugInfo;
StringRef PDBFileName;
auto EC = CoffObject->getDebugPDBInfo(DebugInfo, PDBFileName);
- if (!EC && DebugInfo != nullptr) {
+ if (!EC && DebugInfo != nullptr && !PDBFileName.empty()) {
using namespace pdb;
std::unique_ptr<IPDBSession> Session;
if (auto Err = loadDataForEXE(PDB_ReaderType::DIA,