Crashes in iOS 8.3 simulator

4136
2
05-18-2015 06:24 PM
marius
by
New Contributor III

Hello,

Since iOS 8.3 was released, I started getting lots of crashes in the iOS simulator. I'm using the latest iOS SDK 10.2.4.

Unfortunately, I couldn't figure out a pattern, as the app just crashes from time to time.

Do you have any suggestions on how to debug/address these issues?

Attached are the crash screenshots.

Regards,
Marius

0 Kudos
2 Replies
DiveshGoyal
Esri Regular Contributor

We too have seen intermittent crashes on the simulator in the following ways :

  • Zooming in/out of the map aggressively (iPad 2 simulator only)
  • Calling zoomToEnvelope on the map when the view controller loads
  • Using AutoPan mode to zoom into the device location

The good news is that so far we haven't seen the crash on a device, but we believe this issue stems from a bug in iOS 8. We have reported the issue to Apple  by filing a radar - #18590356 NSURLSession will crash the application.

Following is the code we submitted that reproduces  the crash on iOS 8. We have escalated the issue to Apple through our business contact, but I suggest you also file an independent radar to add more weight to the issue.

while (YES) {
  @autoreleasepool{
  NSURL *url = [NSURL URLWithString:@"http://prod.lists.apple.com/archives/macnetworkprog/2014/Oct/msg00001.html"];
  NSURLSessionConfiguration *config = [NSURLSessionConfiguration ephemeralSessionConfiguration];
  NSURLSession *session = [NSURLSession sessionWithConfiguration:config delegate:self delegateQueue:nil];

  NSURLSessionDataTask *task =
  [session dataTaskWithURL:url
  completionHandler: ^(NSData *data, NSURLResponse *response, NSError *error) {
  NSLog(@"response: %@", response);
  }];

  [task resume];
  [task cancel];

  // *** It is this call to finishTasksAndInvalidate that seems to trigger the crash.
  // If I comment it out, no crash.
  //[session finishTasksAndInvalidate];
  [session invalidateAndCancel];
  }
}

0 Kudos
DiveshGoyal
Esri Regular Contributor

This will be fixed with the upcoming 10.2.5 release.