mirror of
https://github.com/python/cpython.git
synced 2025-08-04 17:08:35 +00:00
Issue #6697: Check that _PyUnicode_AsString() result is not NULL in _sqlite
Strip also some trailing spaces
This commit is contained in:
parent
f6c578328c
commit
8699950b04
4 changed files with 13 additions and 6 deletions
|
@ -83,6 +83,8 @@ PyObject* pysqlite_row_subscript(pysqlite_Row* self, PyObject* idx)
|
|||
return item;
|
||||
} else if (PyUnicode_Check(idx)) {
|
||||
key = _PyUnicode_AsString(idx);
|
||||
if (key == NULL)
|
||||
return NULL;
|
||||
|
||||
nitems = PyTuple_Size(self->description);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue