projects
/
librfid
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Fix "key format error" on cm5121 (Pierrick Hascoet <pierrick.hascoet@hydromel.net>)
[librfid]
/
src
/
rfid_reader_cm5121_openct.c
diff --git
a/src/rfid_reader_cm5121_openct.c
b/src/rfid_reader_cm5121_openct.c
index
9d96638
..
801f076
100644
(file)
--- a/
src/rfid_reader_cm5121_openct.c
+++ b/
src/rfid_reader_cm5121_openct.c
@@
-2,7
+2,7
@@
#include <stdio.h>
#include <stdio.h>
-#include <rfid/rfid_asic.h>
+#include <
lib
rfid/rfid_asic.h>
#include <openct/openct.h>
/* FIXME: get rid of this global crap. In fact this needs to become part of
#include <openct/openct.h>
/* FIXME: get rid of this global crap. In fact this needs to become part of
@@
-39,18
+39,13
@@
int cm5121_source_init(struct rfid_asic_transport_handle *rath)
if (!h)
return -1;
if (!h)
return -1;
- printf("acquiring card lock\n");
rc = ct_card_lock(h, slot, IFD_LOCK_EXCLUSIVE, &lock);
rc = ct_card_lock(h, slot, IFD_LOCK_EXCLUSIVE, &lock);
- if (rc < 0) {
- fprintf(stderr, "error, no card lock\n");
+ if (rc < 0)
return -1;
return -1;
- }
rc = ct_card_reset(h, slot, atr, sizeof(atr));
rc = ct_card_reset(h, slot, atr, sizeof(atr));
- if (rc < 0) {
- fprintf(stderr, "error, can't reset virtual card\n");
+ if (rc < 0)
return -1;
return -1;
- }
rath->data = h;
rath->data = h;