mirror of
https://github.com/python/cpython.git
synced 2025-08-31 14:07:50 +00:00
Add -E command line switch (ignore environment variables like PYTHONHOME
and PYTHONPATH).
This commit is contained in:
parent
f973c6d594
commit
7d4bb9f179
12 changed files with 59 additions and 34 deletions
|
@ -14,6 +14,12 @@ extern DL_IMPORT(int) Py_UseClassExceptionsFlag;
|
|||
extern DL_IMPORT(int) Py_FrozenFlag;
|
||||
extern DL_IMPORT(int) Py_TabcheckFlag;
|
||||
extern DL_IMPORT(int) Py_UnicodeFlag;
|
||||
extern DL_IMPORT(int) Py_IgnoreEnvironmentFlag;
|
||||
|
||||
/* this is a wrapper around getenv() the pays attention to
|
||||
Py_IgnoreEnvironmentFlag. It should be used for getting variables like
|
||||
PYTHONPATH and PYTHONHOME from the environment */
|
||||
#define Py_GETENV(s) (Py_IgnoreEnvironmentFlag ? NULL : getenv(s))
|
||||
|
||||
DL_IMPORT(void) Py_FatalError(char *message);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue