environ
Accesses DOS environment variables.
Defined in header <dos.h>
Syntax
extern char * environ[ ];
Remarks
environ is an array of pointers to strings; it is used to access and alter the DOS environment variables. Each string is of the form
envvar = varvalue
where envvar is the name of an environment variable (such as PATH), and varvalue is the string value to which envvar is set (such as C: \BIN; C: \DOS). The string varvalue may be empty.
When a program begins execution, the DOS environment settings are passed directly to the program. Note that env, the third argument to main, is equal to the initial setting of environ.
The environ array can be accessed by getenv; however, the putenv function is the only routine that should be used to add, change or delete the environ array entries. This is because modification can resize and relocate the process environment array, but environ is automatically adjusted so that it always points to the array.
See also
Differences from modern implementations
Nothing recorded yet.
Modern references
These are search links, not yet checked by hand.
Stable link: /3.1/dos.h/environ/
· short form /3.1/environ/