mirror of
https://github.com/polhenarejos/pico-keys-sdk
synced 2026-05-10 09:18:26 +02:00
Some fixes for emulation.
Signed-off-by: Pol Henarejos <pol.henarejos@cttc.es>
This commit is contained in:
@@ -72,7 +72,7 @@ uint16_t apdu_process(uint8_t itf, const uint8_t *buffer, uint16_t buffer_size)
|
||||
if (buffer_size == 7) {
|
||||
apdu.ne = (apdu.header[5] << 8) | apdu.header[6];
|
||||
if (apdu.ne == 0) {
|
||||
//apdu.ne = 65536; // All underlying architecture assumes payloads are 65535 as max
|
||||
apdu.ne = 65536;
|
||||
}
|
||||
}
|
||||
else {
|
||||
@@ -82,7 +82,7 @@ uint16_t apdu_process(uint8_t itf, const uint8_t *buffer, uint16_t buffer_size)
|
||||
if (apdu.nc + 7 + 2 == buffer_size) {
|
||||
apdu.ne = (apdu.header[buffer_size - 2] << 8) | apdu.header[buffer_size - 1];
|
||||
if (apdu.ne == 0) {
|
||||
//apdu.ne = 65536;
|
||||
apdu.ne = 65536;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user