ericsink / SQLitePCL.raw

A Portable Class Library (PCL) for low-level (raw) access to SQLite
Apache License 2.0
512 stars 106 forks source link

SQLitePCLRaw.bundle_e_sqlcipher error on MacOS 10.15.3 #555

Closed haitien9696 closed 9 months ago

haitien9696 commented 9 months ago

I have a dotnet application and I used SQLitePCLRaw.bundle_e_sqlcipher to access database (sqlite with password). It worked on MacOS 10.15.7 but cannot open sqlite connection on MacOS 10.15.3.

when I open my application, I will open sqlite connection and insert data to database. however, after "Connection.Open();" invoking, my app has been crashed, no exception throwed. So I don't know what happened.

if (Connection.State != ConnectionState.Open)
Connection.Open();
var result = await Connection.QueryAsync<TModel>(sql, obj);
return result.ToList();

I got error (by mac) bellow: Thread 0 Crashed:: Dispatch queue: com.apple.main-thread 0 libe_sqlcipher.dylib 0x00000001283f77f2 pthreadMutexAlloc + 18 1 libe_sqlcipher.dylib 0x00000001283df703 sqlite3MutexAlloc + 19 2 libe_sqlcipher.dylib 0x00000001283df505 sqlite3_initialize + 53 3 libe_sqlcipher.dylib 0x00000001283f4a3c openDatabase + 60 4 libe_sqlcipher.dylib 0x00000001283f4ec9 sqlite3_open_v2 + 9 5 ??? 0x000000012dae7e66 0 + 5061377638 6 ??? 0x000000012dae7d7e 0 + 5061377406 ...

Idk why it not working. Anyone can explain or know reason? Tks for reading!!!