mirror of
https://github.com/RPCS3/rpcs3.git
synced 2025-07-04 14:01:25 +12:00
Replace most returns with CHECK_ASSERTION
Also fix some Seek methods return types being unsigned, while returning negative errors. Added the CHECK_ASSERTION macro checks in a couple more places. Simplified CHECK_ASSERTION macro usage.
This commit is contained in:
parent
9c2f48cd1d
commit
5d5a4f804b
14 changed files with 159 additions and 394 deletions
|
@ -10,6 +10,7 @@
|
|||
|
||||
#ifndef _WIN32
|
||||
#include <dirent.h>
|
||||
#include <errno.h>
|
||||
#endif
|
||||
|
||||
#include "rPlatform.h"
|
||||
|
@ -57,14 +58,9 @@ std::string rPlatform::getConfigDir()
|
|||
dir = "./config";
|
||||
dir = dir + "/rpcs3/";
|
||||
|
||||
s32 ret = mkdir(dir.c_str(), 0777);
|
||||
if (ret == EEXIST)
|
||||
if (mkdir(dir.c_str(), 0777) == -1)
|
||||
{
|
||||
LOG_WARNING(HLE, "Configuration directory already exists. (%s)", dir);
|
||||
}
|
||||
else if (ret < 0)
|
||||
{
|
||||
LOG_ERROR(HLE, "An error occured during the creation of the configuration directory. (%d)", ret);
|
||||
printf("An error occured during the creation of the configuration directory. (%d)", errno);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue