@@ -776,16 +776,6 @@ stmt_mark_dirty(pysqlite_Statement *self)
776776 self -> in_use = 1 ;
777777}
778778
779- static inline sqlite3_int64
780- changes (sqlite3 * db )
781- {
782- #if SQLITE_VERSION_NUMBER >= 3037000
783- return sqlite3_changes64 (db );
784- #else
785- return (sqlite3_int64 )sqlite3_changes (db );
786- #endif
787- }
788-
789779PyObject *
790780_pysqlite_query_execute (pysqlite_Cursor * self , int multiple , PyObject * operation , PyObject * second_argument )
791781{
@@ -955,12 +945,12 @@ _pysqlite_query_execute(pysqlite_Cursor* self, int multiple, PyObject* operation
955945 }
956946
957947 if (self -> statement -> is_dml && rc == SQLITE_DONE && multiple ) {
958- self -> rowcount += changes (self -> connection -> db );
948+ self -> rowcount += ( long ) sqlite3_changes (self -> connection -> db );
959949 }
960950
961951 if (rc == SQLITE_DONE && !multiple ) {
962952 if (self -> statement -> is_dml ) {
963- self -> rowcount = changes (self -> connection -> db );
953+ self -> rowcount = ( long ) sqlite3_changes (self -> connection -> db );
964954 }
965955 stmt_reset (self -> statement );
966956 Py_CLEAR (self -> statement );
@@ -1137,7 +1127,7 @@ pysqlite_cursor_iternext(pysqlite_Cursor *self)
11371127 int rc = stmt_step (stmt );
11381128 if (rc == SQLITE_DONE ) {
11391129 if (self -> statement -> is_dml ) {
1140- self -> rowcount = changes (self -> connection -> db );
1130+ self -> rowcount = ( long ) sqlite3_changes (self -> connection -> db );
11411131 }
11421132 (void )stmt_reset (self -> statement );
11431133 }
0 commit comments