@@ -776,16 +776,6 @@ stmt_mark_dirty(pysqlite_Statement *self)
776
776
self -> in_use = 1 ;
777
777
}
778
778
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
-
789
779
PyObject *
790
780
_pysqlite_query_execute (pysqlite_Cursor * self , int multiple , PyObject * operation , PyObject * second_argument )
791
781
{
@@ -955,12 +945,12 @@ _pysqlite_query_execute(pysqlite_Cursor* self, int multiple, PyObject* operation
955
945
}
956
946
957
947
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 );
959
949
}
960
950
961
951
if (rc == SQLITE_DONE && !multiple ) {
962
952
if (self -> statement -> is_dml ) {
963
- self -> rowcount = changes (self -> connection -> db );
953
+ self -> rowcount = ( long ) sqlite3_changes (self -> connection -> db );
964
954
}
965
955
stmt_reset (self -> statement );
966
956
Py_CLEAR (self -> statement );
@@ -1137,7 +1127,7 @@ pysqlite_cursor_iternext(pysqlite_Cursor *self)
1137
1127
int rc = stmt_step (stmt );
1138
1128
if (rc == SQLITE_DONE ) {
1139
1129
if (self -> statement -> is_dml ) {
1140
- self -> rowcount = changes (self -> connection -> db );
1130
+ self -> rowcount = ( long ) sqlite3_changes (self -> connection -> db );
1141
1131
}
1142
1132
(void )stmt_reset (self -> statement );
1143
1133
}
0 commit comments