fastfetch: fix compiler warnings

This commit is contained in:
李通洲
2023-12-21 09:52:15 +08:00
parent 72ed11ec9e
commit a1d81b4964
+1 -1
View File
@@ -267,7 +267,7 @@ static void listConfigPaths(void)
FF_LIST_FOR_EACH(FFstrbuf, folder, instance.state.platform.configDirs)
{
bool exists = false;
uint32_t length = folder->length + sizeof("fastfetch");
uint32_t length = folder->length + (uint32_t) strlen("fastfetch") + 1 /* trailing slash */;
ffStrbufAppendS(folder, "fastfetch/config.jsonc");
exists = ffPathExists(folder->chars, FF_PATHTYPE_FILE);
if (!exists)