Fix windows build.

llvm-svn: 209961
This commit is contained in:
Rafael Espindola 2014-05-31 03:26:57 +00:00
parent a46bdb6d4d
commit 54f41582c2
2 changed files with 2 additions and 3 deletions

View File

@ -426,14 +426,14 @@ error_code sys::ChangeStdinToBinary(){
int result = _setmode( _fileno(stdin), _O_BINARY );
if (result == -1)
return error_code(errno, generic_category());
return make_error_code(errc::success);
return error_code();
}
error_code sys::ChangeStdoutToBinary(){
int result = _setmode( _fileno(stdout), _O_BINARY );
if (result == -1)
return error_code(errno, generic_category());
return make_error_code(errc::success);
return error_code();
}
bool llvm::sys::argumentsFitWithinSystemLimits(ArrayRef<const char*> Args) {

View File

@ -57,7 +57,6 @@ _system_error_category::message(int ev) const {
error_condition
_system_error_category::default_error_condition(int ev) const {
switch (ev) {
MAP_ERR_TO_COND(0, success);
// Windows system -> posix_errno decode table ---------------------------//
// see WinError.h comments for descriptions of errors
MAP_ERR_TO_COND(ERROR_ACCESS_DENIED, permission_denied);