Show More
@@ -98,6 +98,7 static inline PyObject *_asciilower(PyOb | |||||
98 | char *str, *newstr; |
|
98 | char *str, *newstr; | |
99 | Py_ssize_t i, len; |
|
99 | Py_ssize_t i, len; | |
100 | PyObject *newobj = NULL; |
|
100 | PyObject *newobj = NULL; | |
|
101 | PyObject *ret = NULL; | |||
101 |
|
102 | |||
102 | str = PyBytes_AS_STRING(str_obj); |
|
103 | str = PyBytes_AS_STRING(str_obj); | |
103 | len = PyBytes_GET_SIZE(str_obj); |
|
104 | len = PyBytes_GET_SIZE(str_obj); | |
@@ -121,10 +122,11 static inline PyObject *_asciilower(PyOb | |||||
121 | newstr[i] = lowertable[(unsigned char)c]; |
|
122 | newstr[i] = lowertable[(unsigned char)c]; | |
122 | } |
|
123 | } | |
123 |
|
124 | |||
124 |
ret |
|
125 | ret = newobj; | |
|
126 | Py_INCREF(ret); | |||
125 | quit: |
|
127 | quit: | |
126 | Py_XDECREF(newobj); |
|
128 | Py_XDECREF(newobj); | |
127 |
return |
|
129 | return ret; | |
128 | } |
|
130 | } | |
129 |
|
131 | |||
130 | static PyObject *asciilower(PyObject *self, PyObject *args) |
|
132 | static PyObject *asciilower(PyObject *self, PyObject *args) |
General Comments 0
You need to be logged in to leave comments.
Login now