COMP: Handle windows with hack for now

This commit is contained in:
Andy Cedilnik 2006-03-17 12:24:37 -05:00
parent e9fcafafe5
commit 0addc75520
1 changed files with 11 additions and 0 deletions

View File

@ -1282,7 +1282,18 @@ bool cmSystemTools::PutEnv(const char* value)
bool cmSystemTools::UnsetEnv(const char* value)
{
#ifdef _WIN32
std::string var = value;
std::string::size_type pos = var.find("=");
if ( pos == var.npos )
{
continue;
}
var = var.substr(0, pos+1);
return cmSystemTools::PutEnv(var.c_str());
#else
return unsetenv(value) == 0;
#endif
}
std::vector<std::string> cmSystemTools::GetEnvironmentVariables()