1
0
mirror of https://github.com/gryf/wmaker.git synced 2026-01-04 04:44:16 +01:00

WUtil: New function wuserdatapath() to get path for application data

Returns the path in the user's GNUstep library: ~/GNUstep/Library
This commit is contained in:
John D Pell
2021-08-08 09:36:17 +02:00
committed by Carlos R. Mafra
parent 7e1cdf2d59
commit 1e45ff2305
2 changed files with 14 additions and 0 deletions

View File

@@ -81,6 +81,19 @@ const char *wusergnusteppath()
return path;
}
const char *wuserdatapath(void)
{
static char *path = NULL;
if (path)
/* Value have been already computed, re-use it */
return path;
path = wstrconcat(wusergnusteppath(), "/" USERDATA_SUBDIR);
return path;
}
char *wdefaultspathfordomain(const char *domain)
{
char *path;