Update of /cvsroot/python/python/dist/src/Python In directory usw-pr-cvs1:/tmp/cvs-serv1513 Modified Files: import.c Log Message: imp_load_module(): correct and comment the sense of the test for '+' in the mode (it's forbidden). Index: import.c =================================================================== RCS file: /cvsroot/python/python/dist/src/Python/import.c,v retrieving revision 2.203 retrieving revision 2.204 diff -C2 -d -r2.203 -r2.204 *** import.c 30 May 2002 17:15:25 -0000 2.203 --- import.c 30 May 2002 17:33:07 -0000 2.204 *************** *** 2409,2417 **** &suffix, &mode, &type)) return NULL; ! if (*mode && ! !(*mode == 'r' || *mode == 'U' || strchr(mode, '+'))) { PyErr_Format(PyExc_ValueError, "invalid file open mode %.200s", mode); return NULL; } if (fob == Py_None) --- 2409,2422 ---- &suffix, &mode, &type)) return NULL; ! if (*mode) { ! /* Mode must start with 'r' or 'U' and must not contain '+'. ! Implicit in this test is the assumption that the mode ! may contain other modifiers like 'b' or 't'. */ ! ! if (!(*mode == 'r' || *mode == 'U') || strchr(mode, '+')) { PyErr_Format(PyExc_ValueError, "invalid file open mode %.200s", mode); return NULL; + } } if (fob == Py_None)
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4