尝试使用Card.io-iOS-SDK扫描卡时,应用程序崩溃。

时间:2016-02-02 07:08:39

标签: ios objective-c swift cardio

我很长时间以来都在使用Card.io,但现在当我点击相机按钮扫描卡片时,它意外地开始崩溃。

以下是崩溃日志。

<Error>: *** Terminating app due to uncaught exception 'NSRangeException', reason: '-[NSTaggedPointerString getCharacters:range:]: Range {0, 7} out of bounds; string length 6'
    *** First throw call stack:
    (0x1845b5900 0x183c23f80 0x1845b5848 0x18459ce88 0x1844a7994 0x18459d634 0x100414aa8 0x1844eda04 0x1004147f4 0x1004153d4 0x10041557c 0x1003e8ea0 0x1892a80c0 0x1892a7cc4 0x189648930 0x189605930 0x189602340 0x189558b70 0x189566030 0x189299c24 0x18456c588 0x18456a32c 0x18456a75c 0x184499680 0x1859a8088 0x189310d90 0x10016de20 0x18403a8b8)
Feb  2 12:15:27 iPhone SpringBoard[54] <Warning>: HW kbd: Failed to set (null) as keyboard focus
Feb  2 12:15:27 iPhone SpringBoard[54] <Warning>: UNNotificationRegistrarConnectionListener connection invalidated
Feb  2 12:15:27 iPhone com.apple.xpc.launchd[1] (UIKitApplication:com.upperlife.instacare[0x4a0a][369]) <Notice>: Service exited due to signal: Abort trap: 6
Feb  2 12:15:27 iPhone SpringBoard[54] <Warning>: Application 'UIKitApplication:com.upperlife.instacare[0x4a0a]' crashed.
Feb  2 12:15:28 iPhone UserEventAgent[23] <Warning>: 215163172432: id=com.upperlife.instacare pid=369, state=0

1 个答案:

答案 0 :(得分:2)

当您使用适用于iOS的旧版Card.io SDK时,这就是iOS 9崩溃的主要原因,它已在5.1.0版本中得到修复。

github中已经提出的问题: - https://github.com/card-io/card.io-iOS-SDK/issues/120

<强>解决: - https://github.com/card-io/card.io-iOS-source/commit/b9b3c0a329b75d048a20190f8843da4f247d755a