mirror of
https://github.com/azahar-emu/azahar.git
synced 2025-05-08 03:27:55 +03:00
Merge pull request #133 from archshift/sdmc-enabled
Use config files to store whether SDMC is enabled or not, auto-create SDMC dir.
This commit is contained in:
commit
ce8390ac03
8 changed files with 40 additions and 4 deletions
|
@ -191,8 +191,10 @@ bool CreateFullPath(const std::string &fullPath)
|
|||
|
||||
// Include the '/' so the first call is CreateDir("/") rather than CreateDir("")
|
||||
std::string const subPath(fullPath.substr(0, position + 1));
|
||||
if (!FileUtil::IsDirectory(subPath))
|
||||
FileUtil::CreateDir(subPath);
|
||||
if (!FileUtil::IsDirectory(subPath) && !FileUtil::CreateDir(subPath)) {
|
||||
ERROR_LOG(COMMON, "CreateFullPath: directory creation failed");
|
||||
return false;
|
||||
}
|
||||
|
||||
// A safety check
|
||||
panicCounter--;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue