|
From: | Dmitry Gutov |
Subject: | bug#23779: 25.0.95; consing "SHELLVAR" onto process-environment doesn't remove it from subprocess env |
Date: | Fri, 17 Jun 2016 15:17:38 +0300 |
User-agent: | Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.2 |
On 06/17/2016 10:11 AM, Eli Zaretskii wrote:
Where does it say that you can use 'cons' or 'push', and only them, to the effect of removing the variable from the environment passed to child processes?
That works with other Emacs features, such as auto-mode-alist.You can also override the values in process-environment using a cons (which strongly suggests the semantics of "first element wins"). Just not "remove" them, currently.
process-environment is just a simple list, so these two functions just _add_ another member to the list, they don't remove the old member.
What would be the point of ever using the "only its name" form if you have to scrub process-environment of all other mentions of this variable?
My reading of the last sentence you cite is that you must manually remove the old member "SHELL=whatever", and _then_ add a member that has no value.
If I've removed all mentions of "GIT_DIR" in there, it's already removed, and the subprocesses shouldn't see it. Why add the new member then?
[Prev in Thread] | Current Thread | [Next in Thread] |