Robin Peng
Robin Peng
Even with an atomic retain count - If the storage is **not** `open_forever()`, one can still run into a problem where the sqlite3* db is not opened. I think that...
> @robin-arcsite can you please provide test code for it? thanks I can reproduce this by reusing @Akster009 's sample code above, simply remove the `open_forever()` line. (Windows 11, Visual...
@fnc12 Yes, I just tried the current `dev` branch. It hits the `prepare_stmt()` function (line 8791) with a NULL `sqlite3* db`.
here's my modified test function: (`open_forever()` line is removed and threads are `join()` ed) ``` void f() { auto db = create_db("D:\\Developer\\Projects\\sample1\\sample1\\my_db.db"); db.sync_schema(); std::thread t1(get_all_tests, &db); std::thread t2(get_all_tests, &db); t1.join();...
@fnc12 I agree that using mutex could be a solution, and I understand your concerns about the performance inpact with that solution. At this point the only advise I have...