SQLite Forum

Documentation improvement: sqlite3_close_v2
Login
To the kind sqlite3 community,

It is written that:
"If sqlite3_close_v2() is called on a database connection that still has outstanding prepared statements, BLOB handles, and/or sqlite3_backup objects then it returns SQLITE_OK and the deallocation of resources is deferred until all prepared statements, BLOB handles, and sqlite3_backup objects are also destroyed."
-- https://www.sqlite.org/c3ref/close.html

The question here is: does sqlite3_close_v2() hang until these resources are cleaned up? Or does it immediately return and should I wait before terminating my program (via exit() or otherwise)?

Key takeaways from this seem to be:
* The documentation should be improved to state the blocking policy of sqlite3_close_v2() under "outstanding prepared statements" conditions.
* Perhaps the documentation may benefit from more traditional manpage-like "return value" sections? (Wiser minds may correct this one.)

Kind regards,
Anon.