summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--include/librfid/rfid_reader_cm5121.h4
-rw-r--r--src/ccid/rfid_reader_cm5121_ccid_direct.c4
-rw-r--r--src/rfid_reader_cm5121.c10
-rw-r--r--src/rfid_reader_cm5121_openct.c4
4 files changed, 11 insertions, 11 deletions
diff --git a/include/librfid/rfid_reader_cm5121.h b/include/librfid/rfid_reader_cm5121.h
index 5a1b7c3..e3e64c0 100644
--- a/include/librfid/rfid_reader_cm5121.h
+++ b/include/librfid/rfid_reader_cm5121.h
@@ -13,8 +13,8 @@
extern int
PC_to_RDR_Escape(void *handle,
- const unsigned char *tx_buf, unsigned int tx_len,
- unsigned char *rx_buf, unsigned int *rx_len);
+ const unsigned char *tx_buf, size_t tx_len,
+ unsigned char *rx_buf, size_t *rx_len);
extern const struct rfid_reader rfid_reader_cm5121;
// extern struct rfid_asic_transport cm5121_ccid;
diff --git a/src/ccid/rfid_reader_cm5121_ccid_direct.c b/src/ccid/rfid_reader_cm5121_ccid_direct.c
index 3327a08..9879ccf 100644
--- a/src/ccid/rfid_reader_cm5121_ccid_direct.c
+++ b/src/ccid/rfid_reader_cm5121_ccid_direct.c
@@ -14,8 +14,8 @@
/* this is the sole function required by rfid_reader_cm5121.c */
int
PC_to_RDR_Escape(void *handle,
- const unsigned char *tx_buf, unsigned int tx_len,
- unsigned char *rx_buf, unsigned int *rx_len)
+ const unsigned char *tx_buf, size_t tx_len,
+ unsigned char *rx_buf, size_t *rx_len)
{
int rc;
ccid_driver_t ch = handle;
diff --git a/src/rfid_reader_cm5121.c b/src/rfid_reader_cm5121.c
index 9587272..1514551 100644
--- a/src/rfid_reader_cm5121.c
+++ b/src/rfid_reader_cm5121.c
@@ -67,7 +67,7 @@ int Write1ByteToReg(struct rfid_asic_transport_handle *rath,
{
unsigned char sndbuf[SENDBUF_LEN];
unsigned char rcvbuf[RECVBUF_LEN];
- unsigned int retlen = RECVBUF_LEN;
+ size_t retlen = RECVBUF_LEN;
sndbuf[0] = 0x20;
sndbuf[1] = 0x00;
@@ -96,7 +96,7 @@ static int Read1ByteFromReg(struct rfid_asic_transport_handle *rath,
{
unsigned char sndbuf[SENDBUF_LEN];
unsigned char recvbuf[RECVBUF_LEN];
- unsigned int retlen = sizeof(recvbuf);
+ size_t retlen = sizeof(recvbuf);
sndbuf[0] = 0x20;
sndbuf[1] = 0x00;
@@ -124,7 +124,7 @@ static int ReadNBytesFromFIFO(struct rfid_asic_transport_handle *rath,
{
unsigned char sndbuf[SENDBUF_LEN];
unsigned char recvbuf[0x7f];
- unsigned int retlen = sizeof(recvbuf);
+ size_t retlen = sizeof(recvbuf);
sndbuf[0] = 0x20;
sndbuf[1] = 0x00;
@@ -153,7 +153,7 @@ static int WriteNBytesToFIFO(struct rfid_asic_transport_handle *rath,
{
unsigned char sndbuf[SENDBUF_LEN];
unsigned char recvbuf[0x7f];
- unsigned int retlen = sizeof(recvbuf);
+ size_t retlen = sizeof(recvbuf);
sndbuf[0] = 0x20;
sndbuf[1] = 0x00;
@@ -302,7 +302,7 @@ static int cm5121_enable_rc632(struct rfid_asic_transport_handle *rath)
{
unsigned char tx_buf[1] = { 0x01 };
unsigned char rx_buf[64];
- unsigned int rx_len = sizeof(rx_buf);
+ size_t rx_len = sizeof(rx_buf);
PC_to_RDR_Escape(rath->data, tx_buf, 1, rx_buf, &rx_len);
diff --git a/src/rfid_reader_cm5121_openct.c b/src/rfid_reader_cm5121_openct.c
index 801f076..244ecee 100644
--- a/src/rfid_reader_cm5121_openct.c
+++ b/src/rfid_reader_cm5121_openct.c
@@ -13,8 +13,8 @@ static int slot = 1;
/* this is the sole function required by rfid_reader_cm5121.c */
int
PC_to_RDR_Escape(void *handle,
- const unsigned char *tx_buf, unsigned int tx_len,
- unsigned char *rx_buf, unsigned int *rx_len)
+ const unsigned char *tx_buf, size_t tx_len,
+ unsigned char *rx_buf, size_t *rx_len)
{
int rc;
ct_handle *h = (ct_handle *) handle;
personal git repositories of Harald Welte. Your mileage may vary