FILE *fp;
int depth;
PyObject *readable; /* Stream-like object being read from */
- PyObject *current_filename;
char *ptr;
char *end;
char *buf;
filename = r_object(p);
if (filename == NULL)
goto code_error;
- if (PyUnicode_CheckExact(filename)) {
- if (p->current_filename != NULL) {
- if (!PyUnicode_Compare(filename, p->current_filename)) {
- Py_DECREF(filename);
- Py_INCREF(p->current_filename);
- filename = p->current_filename;
- }
- }
- else {
- p->current_filename = filename;
- }
- }
name = r_object(p);
if (name == NULL)
goto code_error;
assert(fp);
rf.readable = NULL;
rf.fp = fp;
- rf.current_filename = NULL;
rf.end = rf.ptr = NULL;
rf.buf = NULL;
res = r_short(&rf);
long res;
rf.fp = fp;
rf.readable = NULL;
- rf.current_filename = NULL;
rf.ptr = rf.end = NULL;
rf.buf = NULL;
res = r_long(&rf);
PyObject *result;
rf.fp = fp;
rf.readable = NULL;
- rf.current_filename = NULL;
rf.depth = 0;
rf.ptr = rf.end = NULL;
rf.buf = NULL;
PyObject *result;
rf.fp = NULL;
rf.readable = NULL;
- rf.current_filename = NULL;
rf.ptr = (char *)str;
rf.end = (char *)str + len;
rf.buf = NULL;
rf.depth = 0;
rf.fp = NULL;
rf.readable = file;
- rf.current_filename = NULL;
rf.ptr = rf.end = NULL;
rf.buf = NULL;
if ((rf.refs = PyList_New(0)) != NULL) {
PyObject* result;
rf.fp = NULL;
rf.readable = NULL;
- rf.current_filename = NULL;
rf.ptr = s;
rf.end = s + n;
rf.depth = 0;