diff options
Diffstat (limited to 'Source/cmExportCommand.cxx')
-rw-r--r-- | Source/cmExportCommand.cxx | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/Source/cmExportCommand.cxx b/Source/cmExportCommand.cxx index 3cb575e..fc62492 100644 --- a/Source/cmExportCommand.cxx +++ b/Source/cmExportCommand.cxx @@ -327,11 +327,10 @@ void cmExportCommand::StorePackageRegistryDir(std::string const& package, fname += "/cmake/packages/"; fname += package; #else - const char* home = cmSystemTools::GetEnv("HOME"); - if (!home) { + std::string fname; + if (!cmSystemTools::GetEnv("HOME", fname)) { return; } - std::string fname = home; cmSystemTools::ConvertToUnixSlashes(fname); fname += "/.cmake/packages/"; fname += package; |