Merge pull request #29 from AlanAtWork/master

Throw std::system_error
This commit is contained in:
mandreyel 2018-10-26 08:57:27 +02:00 committed by GitHub
commit a345b8b92d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 4 deletions

View File

@ -112,7 +112,7 @@ public:
{ {
std::error_code error; std::error_code error;
map(path, offset, length, error); map(path, offset, length, error);
if(error) { throw error; } if(error) { throw std::system_error(error); }
} }
/** /**
@ -123,7 +123,7 @@ public:
{ {
std::error_code error; std::error_code error;
map(handle, offset, length, error); map(handle, offset, length, error);
if(error) { throw error; } if(error) { throw std::system_error(error); }
} }
/** /**

View File

@ -96,7 +96,7 @@ public:
{ {
std::error_code error; std::error_code error;
map(path, offset, length, error); map(path, offset, length, error);
if(error) { throw error; } if(error) { throw std::system_error(error); }
} }
/** /**
@ -107,7 +107,7 @@ public:
{ {
std::error_code error; std::error_code error;
map(handle, offset, length, error); map(handle, offset, length, error);
if(error) { throw error; } if(error) { throw std::system_error(error); }
} }
/** /**