_NutWIN32getenv()

query the Win32 environment 

Function


SYNOPSIS

#include <nutc.h>

char *_NutWIN32getenv(const char *name);


DESCRIPTION

The NuTCRACKER Platform maintains two distinct environments: the UNIX version, where the keys are case sensitive, and the Win32 version, which is a pass-through to the Win32 functions GetEnvironmentVariable() and SetEnvironmentVariable().

The function _NutWIN32getenv() is a getenv() look-alike that queries the Win32 environment. This function stores the result in a static buffer that is overwritten by subsequent calls. This function is useful for programs that need access to the raw, unconverted Win32 environment variables such as %Path%.


PARAMETERS

name 

Points to the name of the system variable.


RETURN VALUES

If successful, _NutWIN32getenv() returns a pointer to the value of environment variable name. This is a static buffer and is overwritten on a subsequent call to _NutWIN32getenv(). If environment variable name is not defined, _NutWIN32getenv() returns NULL.


CONFORMANCE

PTC MKS Toolkit UNIX APIs extension.


MULTITHREAD SAFETY LEVEL

MT-Safe.


PORTING ISSUES

None.


AVAILABILITY

PTC MKS Toolkit for Professional Developers
PTC MKS Toolkit for Professional Developers 64-Bit Edition
PTC MKS Toolkit for Enterprise Developers
PTC MKS Toolkit for Enterprise Developers 64-Bit Edition


SEE ALSO

Functions:
_NutWIN32putenv(), getenv(), putenv()

Miscellaneous:
environ


PTC MKS Toolkit 10.5 Documentation Build 40.