iOS 5 Core Data freeze

前端 未结 7 918
清歌不尽
清歌不尽 2021-01-30 22:48

I try to do the following simple thing:

NSArray * entities = [context executeFetchRequest:inFetchRequest error:&fetchError];

Nothing fancy.

7条回答
  •  一个人的身影
    2021-01-30 23:09

    I had the same issue. If you run under the debugger and when the app "hangs" stop th app (use the "pause" button on the debugger. If you're at the executeFetchRequest line, then check the context variable. If it has a ivar _objectStoreLockCount and its greater than 1, then its waiting on a lock on the associated store.

    Somewhere you're creating a race condition on your associated store.

提交回复
热议问题