[PECOFF] It's an error if subsystem is not specified.

llvm-svn: 188150
This commit is contained in:
Rui Ueyama 2013-08-12 02:23:16 +00:00
parent d265e88827
commit bf5610cced
1 changed files with 5 additions and 0 deletions

View File

@ -59,6 +59,11 @@ bool PECOFFLinkingContext::validateImpl(raw_ostream &diagnostics) {
return true;
}
if (_subsystem == llvm::COFF::IMAGE_SUBSYSTEM_UNKNOWN) {
diagnostics << "Error: Subsystem is not specified\n";
return true;
}
_reader = createReaderPECOFF(*this);
_writer = createWriterPECOFF(*this);
return false;