summaryrefslogtreecommitdiff
path: root/src/rfid_layer2_iso14443b.c
diff options
context:
space:
mode:
authorlaforge <laforge@e0336214-984f-0b4b-a45f-81c69e1f0ede>2006-10-14 15:22:36 +0000
committerlaforge <laforge@e0336214-984f-0b4b-a45f-81c69e1f0ede>2006-10-14 15:22:36 +0000
commit36751e15b8ac7a0ed5809385645150ffaaf114d1 (patch)
treef49c8b555c185790462b0a9f47d84156c7bfaef7 /src/rfid_layer2_iso14443b.c
parent9ce76f09417c31a8fc904b67624c0f3b397c21c0 (diff)
- remove prototypes for already-removed _register() functions from headers
- automatically define LIBRFID_STATIC if LIBRFID_FIRMWARE is set - remove any references to printf/snprintf - remove bogus free() in 14443b_init git-svn-id: https://svn.gnumonks.org/trunk/librfid@1905 e0336214-984f-0b4b-a45f-81c69e1f0ede
Diffstat (limited to 'src/rfid_layer2_iso14443b.c')
-rw-r--r--src/rfid_layer2_iso14443b.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/src/rfid_layer2_iso14443b.c b/src/rfid_layer2_iso14443b.c
index d88fee5..34575c5 100644
--- a/src/rfid_layer2_iso14443b.c
+++ b/src/rfid_layer2_iso14443b.c
@@ -173,10 +173,8 @@ transceive_attrib(struct rfid_layer2_handle *h, const unsigned char *inf,
int ret = 0;
DEBUGP("fsd is %u\n", h->priv.iso14443b.fsd);
- if (rx_len >= rx_len-1) {
- perror("rx_len too large\n");
- goto out_attrib;
- }
+ if (rx_len >= rx_len-1)
+ return -EINVAL;
/* initialize attrib frame */
memset(&_attrib_buf, 0, sizeof(_attrib_buf));
@@ -230,7 +228,6 @@ transceive_attrib(struct rfid_layer2_handle *h, const unsigned char *inf,
memcpy(rx_data, rx_buf+1, *rx_len);
out_rx:
- free(rx_buf);
out_attrib:
return ret;
personal git repositories of Harald Welte. Your mileage may vary