pharo-rdbms / Pharo-SQLite3

Community-owned official SQLite3 binding for Pharo
MIT License
22 stars 20 forks source link

Incorrect finalization of prepared statements #28

Closed gcorriga closed 3 years ago

gcorriga commented 3 years ago

Prepared statements are not finalized correctly.

According to https://www.sqlite.org/c3ref/stmt.html, statements need to be destroyed with a call to sqlite3_finalize(). However this never happens since SQLite3Connection>>finalize: is a no-op.

In addition to this, it should be possible for a user to finalize a statement in a deterministic manner as required by the SQLite3 API. Not being able to do so can cause non-deterministic SQLITE3_BUSY errors that might be difficult to track down.