summaryrefslogtreecommitdiff
path: root/Python
diff options
context:
space:
mode:
Diffstat (limited to 'Python')
-rw-r--r--Python/initconfig.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/Python/initconfig.c b/Python/initconfig.c
index 2e3cde83b2..b91d280906 100644
--- a/Python/initconfig.c
+++ b/Python/initconfig.c
@@ -249,6 +249,14 @@ fail:
#undef SET_ITEM_STR
}
+char*
+Py_GETENV(const char *name)
+{
+ if (Py_IgnoreEnvironmentFlag) {
+ return NULL;
+ }
+ return getenv(name);
+}
/* --- PyStatus ----------------------------------------------- */