View | Details | Raw Unified | Return to bug 180291
Collapse All | Expand All

(-)/usr/ports/security/openct/files/patch-ctapi.c (+15 lines)
Line 0 Link Here
1
--- src/ctapi/ctapi.c	2006-04-25 23:58:06.000000000 +0200
2
+++ src/ctapi/ctapi.c	2013-07-05 10:08:41.000000000 +0200
3
@@ -562,7 +562,11 @@
4
 	ct->next = cardTerminals;
5
 	cardTerminals = ct;
6
 	ct->cwd = &ct->mf;
7
-	ct_reader_info(pn, &info);
8
+	if (ct_reader_info(pn, &info) < 0) { 
9
+		free(ct);
10
+		ct_error("ct_reader_info failed\n");
11
+		return ERR_INVALID;
12
+	}
13
 	ct->mf.id = 0x3f00;
14
 	ct->mf.gen = dir;
15
 	ct->mf.dir[0] = &ct->mf;

Return to bug 180291