lrt_set_env_list
| Environment Variable Functions |
Sets a list of environment variables.
void lrt_set_env_list( char **allowedEnv );
| allowedEnv | A list of environment variable strings, in the form of "variable=", terminated with NULL. |
The lrt_set_env_list function sets a list of variables which can then be set by lrt_tuxputenv. After lrt_set_env_listhas been called, the environment variables in the allowedEnv list can be set.
The function does not set values for the variables. Do not add a value after the equal sign. This is a syntax error.
The default list of variables before a call to lrt_set_env_listcontains:
WSNADDR
TUXDIR
FIELDTBLS32,
FLDTBLDIR32
FIELDTBLS
FLDTBLDIR
VIEWDIR32
VIEWFILES32
These settings can be set with lrt_tuxputenv, without calling lrt_set_env_list. However, the default list is replaced by allowedEnv when you call lrt_set_env_list.If allowedEnv does not contain WSNADDR, you will no longer be able to set it.
Return Values
The function is declared as void, so it does not return anything.
Parameterization
You cannot use standard parameterization for any arguments in this function.
Example
In the following example, the lrt_set_env_list function sets the environment variable list from the array env_allow_array.
/* define the array*/
static char *env_allow_array[] = {
"WSNADDR=",
"FLDTBLDIR32=",
"FIELDTBLS32=",
NULL
};
/*set the environment variable list*/
lrt_set_env_list(env_allow_array);

