1 .\"(c) Copyright 1992 by Panagiotis Tsirigotis
2 .\"All rights reserved. The file named COPYRIGHT specifies the terms
3 .\"and conditions for redistribution.
5 .\" $Id: m_env.3,v 1.1.1.1 2003/02/19 17:29:27 bbraun Exp $
6 .TH ENV 3L "20 October 1992"
8 env_create, env_destroy, env_make, env_addvar, env_addstr, env_remvar, env_lookup, env_getvars -- environment manipulation functions
16 env_h env_create( env )
20 void env_destroy( env )
24 env_h env_make( env_strings )
28 int env_addvar( env, from_env, var )
34 int env_addstr( env, str )
39 int env_remvar( env, var )
44 char **env_getvars( env )
47 This library handles environments. An environment is a set of strings
50 In the following, we will use the term string as a synonym of
51 NUL-terminated array of
55 creates a new environment. The new environment will be empty unless
60 In that case, the new environment will be a duplicate of
62 (i.e. they will contain the same strings).
65 destroys the specified environment.
68 creates a new environment which includes the
71 should be a NULL-terminated array of strings.
74 adds the specified variable
78 The variable value is obtained from the environment
80 If the variable exists already in
82 the old value is replaced with the new value.
85 adds a string of the form
91 removes the specified variable
101 It returns a string of the form
105 is the name of the variable
110 returns a NULL-terminated array of strings of the form
113 In case of error, all calls will place an error code in the global variable
115 Possible error codes:
121 variable is not in environment
124 string is not well-formed (i.e. is not of the form \fIname=value\fR).
155 if the variable is not part of the environment.
158 returns a string on success or