App crashing when taking multiple photos

Hello,

I have an app under development that uses the onboard camera to capture images. The app behaves very similarly to the camera app, in that there is a button to capture images and a horizontal listview below it to show a preview of all captured images.

The app works fine when taking 5-6 images, but when the image count reaches 15-18 during the same session, the app crashes with the below error.

[SOServiceConnection] <SOServiceConnection: 0x28363a9c0>: XPC connection interrupted

I am unable to decipher the error code and hence figure out a solution to the problem.

I am assuming that it has something to do with the preview images or the number of images occupying the RAM.

Any help in this regard will be highly appreciated.

App crashing when taking multiple photos
 
 
Q