core: fix nullptr comparison in system-path.cc
This commit is contained in:
@@ -318,10 +318,10 @@ MakeTemporaryDirectoryName()
|
||||
char* path = nullptr;
|
||||
|
||||
path = std::getenv("TMP");
|
||||
if (!path || std::strlen(path) == 0)
|
||||
if (!path || std::strlen(path) == 0)
|
||||
{
|
||||
path = std::getenv("TEMP");
|
||||
if (path || std::strlen(path) == 0)
|
||||
if (!path || std::strlen(path) == 0)
|
||||
{
|
||||
path = const_cast<char*>("/tmp");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user