Thanks to visit codestin.com Credit goes to github.com
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 9a68f8c commit e69a08eCopy full SHA for e69a08e
1 file changed
Modules/main.c
@@ -132,6 +132,16 @@ static void RunStartupFile(PyCompilerFlags *cf)
132
(void) PyRun_SimpleFileExFlags(fp, startup, 0, cf);
133
PyErr_Clear();
134
fclose(fp);
135
+ } else {
136
+ int save_errno;
137
+
138
+ save_errno = errno;
139
+ PySys_WriteStderr("Could not open PYTHONSTARTUP\n");
140
+ errno = save_errno;
141
+ PyErr_SetFromErrnoWithFilename(PyExc_IOError,
142
+ startup);
143
+ PyErr_Print();
144
+ PyErr_Clear();
145
}
146
147
0 commit comments