mirror of
https://github.com/python/cpython.git
synced 2025-07-31 07:04:42 +00:00
open_the_file(): Explicitly set errno to 0 before calling fopen().
This commit is contained in:
parent
4279346a9f
commit
a27a150ea5
1 changed files with 1 additions and 0 deletions
|
@ -106,6 +106,7 @@ open_the_file(PyFileObject *f, char *name, char *mode)
|
|||
"file() constructor not accessible in restricted mode");
|
||||
return NULL;
|
||||
}
|
||||
errno = 0;
|
||||
#ifdef HAVE_FOPENRF
|
||||
if (*mode == '*') {
|
||||
FILE *fopenRF();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue