Skip to content

Commit f887210

Browse files
committed
Begin session to help parallel usage
IB-8374 Signed-off-by: Raul Metsma <raul@metsma.ee>
1 parent f100e17 commit f887210

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

EstEIDToken/TokenSession.swift

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,6 +79,7 @@ class AuthOperation: TKTokenSmartCardPINAuthOperation {
7979
NSLog("AuthOperation finish Failed to verify PIN blocked")
8080
let msg = String(format: String(localized: "VERIFY_TRY_LEFT"), 0)
8181
EstEIDTokenDriver.showNotification(msg)
82+
self.smartCard?.endSession() // Workaround release card
8283
throw NSError(domain: TKErrorDomain, code: TKError.Code.canceledByUser.rawValue, userInfo: [NSLocalizedDescriptionKey: msg])
8384
case (let sw, _) where (sw & 0xfff0) == 0x63C0:
8485
let triesLeft = Int(sw & 0x000f)
@@ -92,7 +93,7 @@ class AuthOperation: TKTokenSmartCardPINAuthOperation {
9293
}
9394
}
9495
catch {
95-
NSLog("EstEIDToken finish failed")
96+
NSLog("AuthOperation finish failed")
9697
throw error
9798
}
9899
}

0 commit comments

Comments
 (0)