2017-06-21 56 views
-2

崩潰的問題,我所面臨的崩潰問題在我們的應用中無處不在,我沒有找到任何解決方案,可以建議我如何解決死機問題,它隨機崩潰在整個應用程序。你如何找到應用

Terminating app due to uncaught exception 'NSGenericException', reason: '* Collection was mutated while being enumerated.' * First throw call stack: (0x18ff7efe0 0x18e9e0538 0x18ff7ea30 0x19639c4d4 0x19639c738 0x19639c8c8 0x1004511e0 0x100450b10 0x10063aee8 0x1006336a8 0x1005b0b04 0x1005929a0 0x1005ed8b4 0x1017284fc 0x1931905dc 0x19319048c 0x1901ebb9c 0x18ff15960 0x18ff2dae4 0x18ff2d284 0x18ff2ad98 0x18fe5ada4 0x1918c4074 0x196115058 0x1001886dc 0x18ee6959c) libc++abi.dylib: terminating with uncaught exception of type NSException

navView=[[UIView alloc]initWithFrame:CGRectMake(0, 0, self.view.frame.size.width,70)]; 
[self.view addSubview:navView]; 
[mapView clear]; 
mapView = [GMSMapView mapWithFrame:CGRectMake(0,70, self.view.frame.size.width,-70) camera:camera]; 
mapView.delegate = self; 
NSBundle *mainBundle = [NSBundle mainBundle]; 
NSURL *styleUrl = [mainBundle URLForResource:@"customMapsJson" withExtension:@"json"]; 
NSError *error; GMSMapStyle *style = [GMSMapStyle styleWithContentsOfFileURL:styleUrl error:&error]; 
[self.view addSubview:mapView]; 
+0

請添加一些代碼 –

+0

navView = [[UIView的頁頭] initWithFrame:方法CGRectMake(0,0,self.view.frame.size.width,70) ]。 [self.view addSubview:navView]; [mapView clear]; mapView = [GMSMapView mapWithFrame:CGRectMake(0,70,self.view.frame.size.width,-70)camera:camera]; mapView.delegate = self; NSBundle * mainBundle = [NSBundle mainBundle]; NSURL * styleUrl = [mainBundle URLForResource:@「customMapsJson」withExtension:@「json」]; NSError *錯誤; GMSMapStyle * style = [GMSMapStyle styleWithContentsOfFileURL:styleUrl error:&error]; [self.view addSubview:mapView]; –

+0

@matloob它發生的整個應用程序我沒有使用任何額外的代碼。 –

回答

-1

瞭解隨機崩潰,您必須實施火力地堡碰撞分析。您可以通過Firebase控制檯查看所有細節的崩潰問題。

請參考下面的鏈接: -

https://firebase.google.com/docs/crash/