1
我收到用户的报告,说我的应用程序在启动时崩溃。目标C - CLLocationManager崩溃
所以我得到了崩溃报告。用户在iOS 4.1上。
崩溃日志如下:
Thu Nov 17 12:23:49 unknown AppName[1481] <Error>: +[CLLocationManager authorizationStatus]: unrecognized selector sent to class 0x3e2ee618
Thu Nov 17 12:23:49 unknown AppName[1481] <Error>: *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '+[CLLocationManager authorizationStatus]: unrecognized selector sent to class 0x3e2ee618'
似乎无法看到什么错我的代码,这里是我
- (void)locationManager:(CLLocationManager *)manager didFailWithError:(NSError *)error {
// 4.2 and below
NSLog(@"locationManager error = %@", error);
if ([error code] != kCLErrorLocationUnknown) {
[self stopUpdatingLocation:NSLocalizedString(@"Error", @"Error")];
}
}
- (void)locationManager:(CLLocationManager *)manager didChangeAuthorizationStatus:(CLAuthorizationStatus)status
{
// 4.2 & above
NSLog(@"authorization change = %i", status);
}
- (void)stopUpdatingLocation:(NSString *)state {
NSLog(@"stop updatinglocation = %@", self.bestEffortAtLocation);
[locationManager stopUpdatingLocation];
locationManager.delegate = nil;
}
请微启。
谢谢
三通
D'oh,谢谢... – teepusink