◐ Shell
clean mode source ↗

bpo-39413: Use _wputenv(), not SetEnvironmentVariableW() by vstinner · Pull Request #18107 · python/cpython

Don't implement os.unsetenv() in C using
SetEnvironmentVariableW(name, NULL) anymore, but implement it in
Python as os.putenv(name, ""). _wputenv() is preferred since it
updates the CRT, whereas SetEnvironmentVariableW(name, NULL) does
not.

Replace also lambda functions with regular functions to get named
functions, to ease debug.

https://bugs.python.org/issue39413