Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit cfcde8c

Browse files
committed
Issue #22218: Fix "comparison between signed and unsigned integers" warning in
Modules/_sqlite/cursor.c.
1 parent f13c46c commit cfcde8c

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

Modules/_sqlite/cursor.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ static pysqlite_StatementKind detect_statement_type(const char* statement)
4646

4747
dst = buf;
4848
*dst = 0;
49-
while (Py_ISALPHA(*src) && dst - buf < sizeof(buf) - 2) {
49+
while (Py_ISALPHA(*src) && (dst - buf) < ((Py_ssize_t)sizeof(buf) - 2)) {
5050
*dst++ = Py_TOLOWER(*src++);
5151
}
5252

0 commit comments

Comments
 (0)