commit | a27a150ea5f946d37e51a03e345115a227816698 | [log] [tgz] |
---|---|---|
author | Tim Peters <tim.peters@gmail.com> | Fri Nov 09 20:59:14 2001 +0000 |
committer | Tim Peters <tim.peters@gmail.com> | Fri Nov 09 20:59:14 2001 +0000 |
tree | 85a2d5b6dbb1c51034fcb5b27c8d50db4abe8ae5 | |
parent | 4279346a9f23a0108714349489b9c763bbbd4e89 [diff] |
open_the_file(): Explicitly set errno to 0 before calling fopen().
diff --git a/Objects/fileobject.c b/Objects/fileobject.c index b4f9e9b..de1a93c 100644 --- a/Objects/fileobject.c +++ b/Objects/fileobject.c
@@ -106,6 +106,7 @@ "file() constructor not accessible in restricted mode"); return NULL; } + errno = 0; #ifdef HAVE_FOPENRF if (*mode == '*') { FILE *fopenRF();