最近升级了XCode 8 ,使用相机报错:
[access] This app has crashed because it attempted to access privacy-sensitive data without a usage description. The app's Info.plist must contain an NSCameraUsageDescription key with a string value explaining to the user how the app uses this data.
解决方法:在Info.plist配置NSCameraUsageDescription
大概统计了一下需要加的一些字段列在下面:
-
NSContactsUsageDescription -> 通讯录
-
NSMicrophoneUsageDescription -> 麦克风
-
NSPhotoLibraryUsageDescription -> 相册
-
NSCameraUsageDescription -> 相机
-
NSLocationAlwaysUsageDescription -> 地理位置
-
NSLocationWhenInUseUsageDescription -> 地理位置
转自:http://blog.csdn.net/zp511253886/article/details/52584210