reader-pcsc: fix verify/modify pinpad commands

The PC/SC v2 part 10 commands for PIN verify and modify were wrong after
a change in pcsc-lite.
See a similar change in http://lists.alioth.debian.org/pipermail/pcsclite-cvs-commit/2013-December/006364.html

Should fix issue #199
This commit is contained in:
Ludovic Rousseau 2014-01-06 15:28:22 +01:00
parent 4ebc506897
commit c6d3b3b086

View File

@ -1393,7 +1393,7 @@ static int part10_build_verify_pin_block(struct sc_reader *reader, u8 * buf, siz
pin_verify->ulDataLength = HOST_TO_CCID_32(offset); /* APDU size */
count = sizeof(PIN_VERIFY_STRUCTURE) + offset -1;
count = sizeof(PIN_VERIFY_STRUCTURE) + offset;
*size = count;
return SC_SUCCESS;
}
@ -1512,7 +1512,7 @@ static int part10_build_modify_pin_block(struct sc_reader *reader, u8 * buf, siz
pin_modify->ulDataLength = HOST_TO_CCID_32(offset); /* APDU size */
count = sizeof(PIN_MODIFY_STRUCTURE) + offset -1;
count = sizeof(PIN_MODIFY_STRUCTURE) + offset;
*size = count;
return SC_SUCCESS;
}