mirror of
https://github.com/RfidResearchGroup/proxmark3.git
synced 2025-02-13 02:34:48 +08:00
Trying C99 dyn structs as suggested by @iceman
This commit is contained in:
parent
263d662783
commit
270afb89aa
1 changed files with 2 additions and 2 deletions
|
@ -1270,10 +1270,10 @@ static void PacketReceived(PacketCommandNG *packet) {
|
|||
LED_B_ON();
|
||||
struct p {
|
||||
uint32_t waittime;
|
||||
uint8_t data[PM3_CMD_DATA_SIZE - sizeof(uint32_t)];
|
||||
uint8_t data[];
|
||||
} PACKED;
|
||||
struct p *payload = (struct p *) &packet->data.asBytes;
|
||||
usart_writebuffer_sync(payload->data, packet->length - sizeof(payload->waittime));
|
||||
usart_writebuffer_sync(payload->data, packet->length - sizeof(payload));
|
||||
uint16_t available;
|
||||
uint16_t pre_available = 0;
|
||||
uint8_t *dest = BigBuf_malloc(USART_FIFOLEN);
|
||||
|
|
Loading…
Reference in a new issue