I created a pretty simple app that uses MapKit and GoogleMaps frameworks and tried to switch between the two maps. I am using ARC (ios 6.1) and Google Maps SDK for iOS version: 1.1.1.2311. After a couple of switches the app crashes with [EAGLContext setCurrentContext:]
– always in the MapKit code. There was some suggestions in a previous thread - to try setting [EAGLContext setCurrentContext:nil]
at various places but it doesn’t help.
stack trace:
Exception Type: EXC_BAD_ACCESS (SIGSEGV)
Exception Codes: KERN_INVALID_ADDRESS at 0x0000000c
Crashed Thread: 0
Thread 0 name: Dispatch queue: com.apple.main-thread
Thread 0 Crashed:
0 OpenGLES 0x33beeb12 +[EAGLContext setCurrentContext:] + 74
1 VectorKit 0x383cada4 -[VGLGPU setPaused:] + 120
2 VectorKit 0x383bad70 -[VKMainLoop updateLinkState] + 492
3 VectorKit 0x383c7334 -[VKAnimation startWithStepHandler:completionHandler:] + 112
4 VectorKit 0x383d657a -[VKBuildingFootprintMapModel _reloadStyleAnimated:] + 474
5 VectorKit 0x383d6398 -[VKBuildingFootprintMapModel setActive:] + 84
6 VectorKit 0x383d5ef4 -[VKModelObject setSupermodel:] + 44
7 VectorKit 0x383d624a -[VKModelObject insertSubmodel:atIndex:] + 142
8 VectorKit 0x383d615a -[VKMapRasterizer addSubmodel:] + 322
9 VectorKit 0x383d5cb4 -[VKMapModel addSubmodel:] + 136
10 VectorKit 0x383cf1c4 -[VKMapModel forceMapType:] + 1532
11 VectorKit 0x383cc568 -[VKMapModel initWithTransform:shouldRasterize:] + 2016
12 VectorKit 0x383cbd80 -[VKMapModel initShouldRasterize:] + 36
13 VectorKit 0x383c9678 -[VKMapCanvas initWithFrame:shouldRasterize:] + 356
14 VectorKit 0x383c930e -[VKMapView initWithFrame:andGlobe:shouldRasterize:] + 642
15 MapKit 0x33599320 -[MKMapView _commonInitAndEnableLoading:fromIB:] + 720
16 MapKit 0x33598e9c -[MKMapView initWithFrame:] + 252
17 saTest 0x00017e2a -[AppleMapCtl loadView] (AppleMapCtl.m:27)