Private copy of the environment variables. More...
#include <stdbool.h>
Go to the source code of this file.
Functions | |
void | mutt_envlist_free (void) |
Free the private copy of the environment. More... | |
char ** | mutt_envlist_getlist (void) |
Get the private environment. More... | |
void | mutt_envlist_init (char *envp[]) |
Create a copy of the environment. More... | |
bool | mutt_envlist_set (const char *name, const char *value, bool overwrite) |
Set an environment variable. More... | |
bool | mutt_envlist_unset (const char *name) |
Unset an environment variable. More... | |
Private copy of the environment variables.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program. If not, see http://www.gnu.org/licenses/.
Definition in file envlist.h.
void mutt_envlist_free | ( | void | ) |
char ** mutt_envlist_getlist | ( | void | ) |
void mutt_envlist_init | ( | char * | envp[] | ) |
Create a copy of the environment.
envp | Environment variables |
Definition at line 56 of file envlist.c.
bool mutt_envlist_set | ( | const char * | name, |
const char * | value, | ||
bool | overwrite | ||
) |
Set an environment variable.
name | Name of the variable |
value | New value |
overwrite | Should the variable be overwritten? |
true | Success: variable set, or overwritten |
false | Variable exists and overwrite was false |
It's broken out because some other parts of neomutt (filter.c) need to set/overwrite environment variables in EnvList before calling exec().
Definition at line 85 of file envlist.c.
bool mutt_envlist_unset | ( | const char * | name | ) |
Unset an environment variable.
name | Variable to unset |
true | Success: Variable unset |
false | Error: Variable doesn't exist |
Definition at line 132 of file envlist.c.