mirror of
https://github.com/obsproject/obs-studio.git
synced 2024-07-14 23:34:08 +00:00
UI: Use os_mkdirs, remove redundant do_mkdir calls
This commit is contained in:
parent
d3ba8c8af4
commit
af1014471d
|
@ -266,7 +266,7 @@ bool OBSApp::InitGlobalConfigDefaults()
|
|||
|
||||
static bool do_mkdir(const char *path)
|
||||
{
|
||||
if (os_mkdir(path) == MKDIR_ERROR) {
|
||||
if (os_mkdirs(path) == MKDIR_ERROR) {
|
||||
OBSErrorBox(NULL, "Failed to create directory %s", path);
|
||||
return false;
|
||||
}
|
||||
|
@ -278,18 +278,6 @@ static bool MakeUserDirs()
|
|||
{
|
||||
char path[512];
|
||||
|
||||
if (portable_mode) {
|
||||
if (GetConfigPath(path, sizeof(path), "") <= 0)
|
||||
return false;
|
||||
if (!do_mkdir(path))
|
||||
return false;
|
||||
}
|
||||
|
||||
if (GetConfigPath(path, sizeof(path), "obs-studio") <= 0)
|
||||
return false;
|
||||
if (!do_mkdir(path))
|
||||
return false;
|
||||
|
||||
if (GetConfigPath(path, sizeof(path), "obs-studio/basic") <= 0)
|
||||
return false;
|
||||
if (!do_mkdir(path))
|
||||
|
|
Loading…
Reference in a new issue