mac:try a string pointer
This commit is contained in:
@@ -2277,9 +2277,9 @@ void Options::load(bool lightweight)
|
|||||||
int homelength = strlen(homebuf.c_str());
|
int homelength = strlen(homebuf.c_str());
|
||||||
homebuf[homelength-44] = '\0'; // Truncate path to just ${HOME}/Library
|
homebuf[homelength-44] = '\0'; // Truncate path to just ${HOME}/Library
|
||||||
std::string homeconfig{homebuf};
|
std::string homeconfig{homebuf};
|
||||||
std::strcat(homeconfig, "/Application Support/RawTherapee/config");
|
std::strcat(&homeconfig[0], "/Application Support/RawTherapee/config");
|
||||||
path = homebuf.c_str();
|
path = homebuf.c_str();
|
||||||
std::cout<<path<<std::endl;
|
std::cout<<"config="<<path<<std::endl;
|
||||||
#else
|
#else
|
||||||
path = g_getenv("RT_SETTINGS");
|
path = g_getenv("RT_SETTINGS");
|
||||||
#endif
|
#endif
|
||||||
@@ -2328,7 +2328,7 @@ void Options::load(bool lightweight)
|
|||||||
// Modify the path of the cache folder to the one provided in RT_CACHE environment variable. Build the cache folder name in macOS.
|
// Modify the path of the cache folder to the one provided in RT_CACHE environment variable. Build the cache folder name in macOS.
|
||||||
#ifdef __APPLE__
|
#ifdef __APPLE__
|
||||||
std::string homecache{homebuf};
|
std::string homecache{homebuf};
|
||||||
std::strcat(homecache, "/Application Support/RawTherapee/cache");
|
std::strcat(&homecache[0], "/Application Support/RawTherapee/cache");
|
||||||
path = homecache.c_str();
|
path = homecache.c_str();
|
||||||
std::cout<<path<<std::endl;
|
std::cout<<path<<std::endl;
|
||||||
#else
|
#else
|
||||||
|
Reference in New Issue
Block a user