Issues with attached databases handle from custom Android SQLite package
(1) By omen_wand on 2021-01-14 04:50:32 [source]
We're creating a Android project that relies on a custom built SQLite package a la: https://sqlite.org/android/doc/trunk/www/index.wiki
Where we essentially install a number of hooks to carry out extra functionality in conjunction with vanilla SQLite C calls by the native code in that module.
One such hook is installed for sqlite3_open_v2() such that when it fulfills a certain special condition, it defers to a sub-function that instead returns a handle with two attached database connections (similar to ATTACH). However, when our project attempts to establish an Android connection to that database, it hangs at the native function:
nativeOpen -> int err = int err = sqlite3_open_v2(path.c_str(), &db, sqliteFlags, NULL);
Again, the application continues running but the Java code execution stops period. There is no crash log since it does not crash, and nothing informative shows in Logcat. Does Android forbid being passed a handle with two database connections? What might be causing the issue?
(2) By Larry Brasfield (LarryBrasfield) on 2021-01-14 15:14:09 in reply to 1 [link] [source]
This appears to be a duplicate of Using android AAR with modified sqlite_open_v2() - attach gives problems? If so, it would be a courtesy for you and your cohort to consolidate your inquiry and clues into a single thread rather than creating scatter-shot threads here. I suggest you add your additional clues posted above to that other thread instead of encouraging a pair of parallel discussions.