updated initCacheDir

This commit is contained in:
Linus Dierheimer
2021-05-08 16:56:37 +02:00
parent c749763f05
commit e4a61c3572
+2
View File
@@ -76,6 +76,8 @@ static void initCacheDir(FFstate* state)
ffStrbufAppendS(&state->cacheDir, state->passwd->pw_dir);
ffStrbufAppendS(&state->cacheDir, "/.cache/");
}
else if(state->cacheDir.chars[state->cacheDir.length - 1] != '/')
ffStrbufAppendC(&state->cacheDir, '/');
mkdir(state->cacheDir.chars, S_IRWXU | S_IXGRP | S_IRGRP | S_IXOTH | S_IROTH); //I hope everybody has a cache folder but whow knews