* Dmitry Kovalenko:
> + {
> + char s[] = "LOCPATH=/usr/share/locale";
> + int const r = putenv (s);
> +
> + if (r != 0)
> + {
> + printf ("putenv failed: %m\n");
> + exit (EXIT_FAILURE);
And this creates a use-after free bug. You need to use the string
literal directly, or: static const char s[] = …
Thanks,
Florian