Search code examples
iosobjective-cgoogle-mapsios8gmsmapview

Google SDK crashes in iOS 8 and above


I imported the latest GoogleMaps framework in my application. In .m file, I do import #import <GoogleMaps/GoogleMaps.h> and in viewDidLoad:, I create the map with line

    GMSMapView *mapView = [GMSMapView mapWithFrame:CGRectMake(0.0f, 0.0f, 320.0f, 428.0f) camera:nil];
    [self.view addSubview:mapView];

No time before the mapView loads the map tiles, the application crashes with EXC_BAD_ACCESS(code=1, address=0x11f0)

But the same works after in release mode. No crash is observed in release mode and the mapView works fine. Only in debugging mode, the app crashes and leaves no hint.

This happens in iOS versions 8 and above 8. Debugging works fine without crash on iOS 7.

This is something fishy. Any approach that I could figure it out?


Solution

  • With respect to @ztan's comment, adding CocoaPods solved the problem