...
Implementation Details
Depending on the implementation, a program may not consistently choose the same value if there are multiple environment variables with the same name. The GNU glibc library attempts to deal with this issue in getenv()
and setenv()
by always using the first variable it comes across, and ignoring the rest. unsetenv()
will remove all the entries matching the variable name. Other implementations are following this lead.
...