|
|
|
Re: [PATCH 4/7] introduce xsetenv globally | |
| [Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] | |
On Fri, Jun 01, 2012 at 02:51:18PM +0200, Ludwig Nussel wrote:
> +++ b/include/env.h
> @@ -4,5 +4,12 @@
> extern void sanitize_env (void);
> extern char *safe_getenv(const char *arg);
>
> +static inline void
> +xsetenv (char const *name, char const *val, int overwrite)
> +{
> + if (setenv (name, val, overwrite) != 0)
> + err (EXIT_FAILURE, _("failed to set the %s environment variable"), name);
> +}
> +
It would be nice to use it also in login.c :-)
Karel
--
Karel Zak <kzak@xxxxxxxxxx>
http://karelzak.blogspot.com
--
To unsubscribe from this list: send the line "unsubscribe util-linux" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
[Site Home] [Netdev] [Ethernet Bridging] [Linux Wireless] [Kernel Newbies] [Memory] [Security] [Linux for Hams] [Netfilter] [Bugtraq] [Rubini] [Photo] [Yosemite] [Yosemite News] [MIPS Linux] [ARM Linux] [Linux RAID] [Linux Admin] [Samba] [Video 4 Linux] [Linux Resources]