SQLITE3_FINALIZE(3) | Library Functions Manual | SQLITE3_FINALIZE(3) |
sqlite3_finalize
—
sqlite3_finalize
(sqlite3_stmt
*pStmt);
The sqlite3_finalize(S) routine can be called at any point during the life cycle of prepared statement S: before statement S is ever evaluated, after one or more calls to sqlite3_reset(), or after any call to sqlite3_step() regardless of whether or not the statement has completed execution.
Invoking sqlite3_finalize() on a NULL pointer is a harmless no-op.
The application must finalize every prepared statement in order to avoid resource leaks. It is a grievous error for the application to try to use a prepared statement after it has been finalized. Any use of a prepared statement after it has been finalized can result in undefined and undesirable behavior such as segfaults and heap corruption.
December 19, 2018 | NetBSD 9.2 |