File tree Expand file tree Collapse file tree 1 file changed +10
-9
lines changed Expand file tree Collapse file tree 1 file changed +10
-9
lines changed Original file line number Diff line number Diff line change @@ -977,11 +977,11 @@ stringio_closed(stringio *self, void *context)
977
977
if (self -> ok <= 0 ) {
978
978
PyErr_SetString (PyExc_ValueError ,
979
979
"I/O operation on uninitialized object" );
980
- goto cleanup ;
980
+ goto exit ;
981
981
};
982
982
result = PyBool_FromLong (self -> closed );
983
983
984
- cleanup :
984
+ exit :
985
985
Py_END_CRITICAL_SECTION ();
986
986
return result ;
987
987
}
@@ -995,15 +995,15 @@ stringio_line_buffering(stringio *self, void *context)
995
995
if (self -> ok <= 0 ) {
996
996
PyErr_SetString (PyExc_ValueError ,
997
997
"I/O operation on uninitialized object" );
998
- goto cleanup ;
998
+ goto exit ;
999
999
};
1000
1000
if (self -> closed ) {
1001
1001
PyErr_SetString (PyExc_ValueError , "I/O operation on closed file" );
1002
- goto cleanup ;
1002
+ goto exit ;
1003
1003
};
1004
1004
result = Py_NewRef (Py_False );
1005
1005
1006
- cleanup :
1006
+ exit :
1007
1007
Py_END_CRITICAL_SECTION ();
1008
1008
return result ;
1009
1009
}
@@ -1017,18 +1017,19 @@ stringio_newlines(stringio *self, void *context)
1017
1017
if (self -> ok <= 0 ) {
1018
1018
PyErr_SetString (PyExc_ValueError ,
1019
1019
"I/O operation on uninitialized object" );
1020
- goto cleanup ;
1020
+ goto exit ;
1021
1021
};
1022
1022
if (self -> closed ) {
1023
1023
PyErr_SetString (PyExc_ValueError , "I/O operation on closed file" );
1024
- goto cleanup ;
1024
+ goto exit ;
1025
1025
};
1026
1026
if (self -> decoder == NULL ) {
1027
- goto cleanup ;
1027
+ result = Py_NewRef (Py_None );
1028
+ goto exit ;
1028
1029
}
1029
1030
result = PyObject_GetAttr (self -> decoder , & _Py_ID (newlines ));
1030
1031
1031
- cleanup :
1032
+ exit :
1032
1033
Py_END_CRITICAL_SECTION ();
1033
1034
return result ;
1034
1035
}
You can’t perform that action at this time.
0 commit comments