tools/llvm-xray: Avoid std::errc::protocol_* to appease mingw, like r285261.

They are oriented from winsock and mingw doesn't import them.

llvm-svn: 291636
This commit is contained in:
NAKAMURA Takumi 2017-01-11 01:06:57 +00:00
parent ebde3653ef
commit def5109392
3 changed files with 3 additions and 3 deletions

View File

@ -195,7 +195,7 @@ static CommandRegistration Unused(&Convert, []() -> Error {
return joinErrors(
make_error<StringError>(
Twine("Failed loading input file '") + ConvertInput + "'.",
std::make_error_code(std::errc::protocol_error)),
std::make_error_code(std::errc::executable_format_error)),
std::move(Err));
raw_fd_ostream OS(ConvertOutput, EC,

View File

@ -254,7 +254,7 @@ InstrumentationMapExtractor::InstrumentationMapExtractor(std::string Filename,
make_error<StringError>(
Twine("Cannot load YAML instrumentation map from '") +
Filename + "'.",
std::make_error_code(std::errc::wrong_protocol_type)),
std::make_error_code(std::errc::executable_format_error)),
std::move(E));
});
break;

View File

@ -123,7 +123,7 @@ Error llvm::xray::NaiveLogLoader(StringRef Data, XRayFileHeader &FileHeader,
default:
return make_error<StringError>(
Twine("Unknown record type '") + Twine(int{Type}) + "'",
std::make_error_code(std::errc::protocol_error));
std::make_error_code(std::errc::executable_format_error));
}
Record.FuncId = RecordExtractor.getSigned(&OffsetPtr, sizeof(int32_t));
Record.TSC = RecordExtractor.getU64(&OffsetPtr);