mirror of
https://github.com/RPCS3/rpcs3.git
synced 2025-07-03 21:41:26 +12:00
File: handle EACCES
This commit is contained in:
parent
b407d12ed1
commit
ef1eff6d48
2 changed files with 3 additions and 0 deletions
|
@ -84,6 +84,7 @@ static fs::error to_error(DWORD e)
|
||||||
{
|
{
|
||||||
case ERROR_FILE_NOT_FOUND: return fs::error::noent;
|
case ERROR_FILE_NOT_FOUND: return fs::error::noent;
|
||||||
case ERROR_PATH_NOT_FOUND: return fs::error::noent;
|
case ERROR_PATH_NOT_FOUND: return fs::error::noent;
|
||||||
|
case ERROR_ACCESS_DENIED: return fs::error::acces;
|
||||||
case ERROR_ALREADY_EXISTS: return fs::error::exist;
|
case ERROR_ALREADY_EXISTS: return fs::error::exist;
|
||||||
case ERROR_FILE_EXISTS: return fs::error::exist;
|
case ERROR_FILE_EXISTS: return fs::error::exist;
|
||||||
case ERROR_NEGATIVE_SEEK: return fs::error::inval;
|
case ERROR_NEGATIVE_SEEK: return fs::error::inval;
|
||||||
|
@ -119,6 +120,7 @@ static fs::error to_error(int e)
|
||||||
case ENOENT: return fs::error::noent;
|
case ENOENT: return fs::error::noent;
|
||||||
case EEXIST: return fs::error::exist;
|
case EEXIST: return fs::error::exist;
|
||||||
case EINVAL: return fs::error::inval;
|
case EINVAL: return fs::error::inval;
|
||||||
|
case EACCES: return fs::error::acces;
|
||||||
default: fmt::throw_exception("Unknown system error: %d.", e);
|
default: fmt::throw_exception("Unknown system error: %d.", e);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -466,6 +466,7 @@ namespace fs
|
||||||
inval,
|
inval,
|
||||||
noent,
|
noent,
|
||||||
exist,
|
exist,
|
||||||
|
acces,
|
||||||
};
|
};
|
||||||
|
|
||||||
// Error code returned
|
// Error code returned
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue