Logo Search packages:      
Sourcecode: ardour version File versions

std::string Glib::getenv ( const std::string &  variable,
bool &  found 
)

Returns the value of an environment variable. The name and value are in the GLib file name encoding. On Unix, this means the actual bytes which might or might not be in some consistent character set and encoding. On Windows, it is in UTF-8. On Windows, in case the environment variable's value contains references to other environment variables, they are expanded.

Parameters:
variable The environment variable to get.
Return values:
found true Whether the environment variable has been found.
Returns:
The value of the environment variable, or "" if not found.

Definition at line 68 of file miscutils.cc.

{
  const char *const value = g_getenv(variable.c_str());
  found = (value != 0);
  return (value) ? std::string(value) : std::string();
}


Generated by  Doxygen 1.6.0   Back to index