We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent a713df6 commit 6400ec5Copy full SHA for 6400ec5
Modules/_sqlite/blob.c
@@ -122,7 +122,7 @@ blob_seterror(pysqlite_Blob *self, int rc)
122
static PyObject *
123
read_single(pysqlite_Blob *self, Py_ssize_t offset)
124
{
125
- unsigned long buf = 0;
+ unsigned char buf = 0;
126
int rc;
127
Py_BEGIN_ALLOW_THREADS
128
rc = sqlite3_blob_read(self->blob, (void *)&buf, 1, (int)offset);
@@ -132,7 +132,7 @@ read_single(pysqlite_Blob *self, Py_ssize_t offset)
132
blob_seterror(self, rc);
133
return NULL;
134
}
135
- return PyLong_FromUnsignedLong(buf);
+ return PyLong_FromUnsignedLong((unsigned long)buf);
136
137
138
0 commit comments