4

I am facing a pretty odd issue with my users: for some reason I cannot identify so far, my app is crashing at some point when the Bluetooth connection is still active (my app is a Central Manager that connects to external Peripherals).

The crash doesn't seem related to the BT connection but regardless of that, the connection stays up forever after the app crashes.

I'd like to make sure the connection won't last forever or that it will be terminated in case the app is forcefully closed by the OS or by any exception. In these cases, the app won't reach applicationWillTerminate, so I am not sure on what I can do anymore to make sure the connection will drop.

Any suggestion on what I can do to make sure the connection will be dropped at some point?

marcelosalloum
  • 3,481
  • 4
  • 39
  • 63
  • This seems to be apple's problem, not yours.. – enapupe Apr 18 '17 at 22:07
  • It is indeed Apple's issue. I came to an hypothesis: I should create two `CBCentralManagers`, one for usual connection and another one for only state preservation. Not sure when I'll have the time to make this huge refactor though =( – marcelosalloum Apr 27 '17 at 18:14

0 Answers0