]>
git.ipfire.org Git - thirdparty/util-linux.git/blob - include/env.h
1 #ifndef UTIL_LINUX_ENV_H
2 #define UTIL_LINUX_ENV_H
7 extern void sanitize_env(void);
8 extern char *safe_getenv(const char *arg
);
11 #ifndef XSETENV_EXIT_CODE
12 # define XSETENV_EXIT_CODE EXIT_FAILURE
15 static inline void xsetenv(char const *name
, char const *val
, int overwrite
)
17 if (setenv(name
, val
, overwrite
) != 0)
18 err(XSETENV_EXIT_CODE
, _("failed to set the %s environment variable"), name
);
21 #endif /* UTIL_LINUX_ENV_H */