mirror of
https://git.rwth-aachen.de/acs/public/villas/node/
synced 2025-03-09 00:00:00 +01:00
lib/ips/fifo: use std:min in favor of old macro
This commit is contained in:
parent
44e78643ea
commit
687f1e5bba
1 changed files with 2 additions and 2 deletions
|
@ -108,7 +108,7 @@ size_t Fifo::write(const void *buf, size_t len)
|
|||
size_t Fifo::read(void *buf, size_t len)
|
||||
{
|
||||
size_t nextlen = 0;
|
||||
uint32_t rxlen;
|
||||
size_t rxlen;
|
||||
|
||||
auto intc = reinterpret_cast<InterruptController*>(dependencies["intc"]);
|
||||
|
||||
|
@ -119,7 +119,7 @@ size_t Fifo::read(void *buf, size_t len)
|
|||
|
||||
/* Get length of next frame */
|
||||
rxlen = XLlFifo_RxGetLen(&xFifo);
|
||||
nextlen = MIN(rxlen, len);
|
||||
nextlen = std::min(rxlen, len);
|
||||
|
||||
/* Read from FIFO */
|
||||
XLlFifo_Read(&xFifo, buf, nextlen);
|
||||
|
|
Loading…
Add table
Reference in a new issue