1. 程式人生 > >ios10相機等崩潰

ios10相機等崩潰

iOS10閃退 崩潰1:

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檔案 新增一個“NSContactsUsageDescription ”的Key,Value新增一個描述。

需要在應用的info.plist里加入(使用source code模式):

<key>NSCameraUsageDescription</key>    
<string>cameraDesciption</string>
<key>NSContactsUsageDescription</key>
<string>contactsDesciption</string>
<key>NSMicrophoneUsageDescription</key>
<string>microphoneDesciption</string
>
<key>NSPhotoLibraryUsageDescription</key> <string>photoLibraryDesciption</string>


文/某個胖子(簡書作者)
原文連結:http://www.jianshu.com/p/ec15dadd38f3
著作權歸作者所有,轉載請聯絡作者獲得授權,並標註“簡書作者”。