mirror of
https://port.numenaute.org/aleajactaest/khanat-opennel-code.git
synced 2024-12-15 14:08:42 +00:00
Fixed: getTemporaryDirectory() under Linux
This commit is contained in:
parent
e77337c1c8
commit
3c54adb709
1 changed files with 9 additions and 3 deletions
|
@ -1727,10 +1727,16 @@ std::string CFileContainer::getTemporaryDirectory()
|
|||
static std::string path;
|
||||
if (path.empty())
|
||||
{
|
||||
std::string tempDir = getenv("TEMP");
|
||||
const char *temp = getenv("TEMP");
|
||||
const char *tmp = getenv("TMP");
|
||||
|
||||
if (tempDir.empty())
|
||||
tempDir = getenv("TMP");
|
||||
std::string tempDir;
|
||||
|
||||
if (temp)
|
||||
tempDir = temp;
|
||||
|
||||
if (tempDir.empty() && tmp)
|
||||
tempDir = tmp;
|
||||
|
||||
#ifdef NL_OS_UNIX
|
||||
if (tempDir.empty())
|
||||
|
|
Loading…
Reference in a new issue