FMDB is crashing in iOS10

188 views
Skip to first unread message

amit mundra

unread,
Oct 6, 2016, 4:50:11 AM10/6/16
to FMDB
Hi,
My FMDatabase.m is crashing many time after upgrading to iOS 10, Please look into log and help me

#3. Crashed: com.apple.root.user-initiated-qos
0  libsqlite3.dylib               0x1c107532 (null) + 3157
1  libsqlite3.dylib               0x1c0fa2eb (null) + 5986
2  libsqlite3.dylib               0x1c0f8d8d sqlite3_step + 516
3  connecta6                      0x238a25 -[FMResultSet next] (FMResultSet.m:151)
9  connecta6                      0x72b670 SyncBL.(callBackgroundSync(SyncBL) -> (Bool, isRegionChanged : Bool) -> ()).(closure #1) (SyncBL.swift:199)
10 libdispatch.dylib              0x1b321097 _dispatch_call_block_and_release + 10
11 libdispatch.dylib              0x1b32fc5b _dispatch_root_queue_drain + 836
12 libdispatch.dylib              0x1b32f8b7 _dispatch_worker_thread3 + 106
13 libsystem_pthread.dylib        0x1b4d5947 _pthread_wqthread + 1168
14 libsystem_pthread.dylib        0x1b4d549c start_wqthread + 8

--

#0. com.apple.main-thread
0  libsqlite3.dylib               0x1c0f79c0 (null) + 66097
1  libsqlite3.dylib               0x1c0ea7b5 (null) + 12326
2  libsqlite3.dylib               0x1c0ea7b5 (null) + 12326
3  libsqlite3.dylib               0x1c0d247d (null) + 16416
4  libsqlite3.dylib               0x1c0cfeaf (null) + 6738
5  libsqlite3.dylib               0x1c0cf569 (null) + 4364
6  libsqlite3.dylib               0x1c0ced25 (null) + 2248
7  libsqlite3.dylib               0x1c0cea99 (null) + 1596
8  libsqlite3.dylib               0x1c119e73 sqlite3_prepare_v2 + 42
9  connecta6                      0x2b3f03 -[FMDatabase executeQuery:withArgumentsInArray:orDictionary:orVAList:] (FMDatabase.m:784)
10 connecta6                      0x2b45cb -[FMDatabase executeQuery:withArgumentsInArray:] (FMDatabase.m:924)
11 connecta6                      0x9cd1e0 DatabaseOps.executeQuery(String, arguments : [AnyObject]...) -> FMResultSet? (DatabaseOps.swift:371)

Gus Mueller

unread,
Oct 6, 2016, 12:13:55 PM10/6/16
to fm...@googlegroups.com
On Oct 6, 2016, at 1:50 AM, amit mundra <amit...@gmail.com> wrote:

My FMDatabase.m is crashing many time after upgrading to iOS 10, Please look into log and help me

Looks like you are using FMDatabase on two threads at the same time, which is a bad idea.

You should look into FMDatabaseQueue.

-gus
Reply all
Reply to author
Forward
0 new messages