mirror of
https://github.com/python/cpython.git
synced 2026-01-06 15:32:22 +00:00
Rip out the file object's implementation.
Fixed test_import.py while I was at it. However, there's still a problem in import.c -- get_file() can leak a FILE struct (not a file descriptor though). I'm not sure how to fix this; closing the FILE* closes the file descriptor, and that's the wrong thing to do when there's still a Python file object keeping the file descriptor open. I also would rather not mess with dup(), as it won't port to Windows.
This commit is contained in:
parent
2d5c219fe0
commit
da5b8f2d28
14 changed files with 106 additions and 2537 deletions
|
|
@ -9,7 +9,6 @@ extern "C" {
|
|||
|
||||
PyAPI_FUNC(PyObject *) PySys_GetObject(char *);
|
||||
PyAPI_FUNC(int) PySys_SetObject(char *, PyObject *);
|
||||
PyAPI_FUNC(FILE *) PySys_GetFile(char *, FILE *);
|
||||
PyAPI_FUNC(void) PySys_SetArgv(int, char **);
|
||||
PyAPI_FUNC(void) PySys_SetPath(char *);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue