mirror of
https://github.com/ArduPilot/ardupilot
synced 2025-02-22 15:53:56 -04:00
HAL_AVR: fixed a warning
This commit is contained in:
parent
f3f703a6d8
commit
8d901b3f5a
@ -142,7 +142,7 @@ bool AVRConsoleDriver::Buffer::allocate(uint16_t size) {
|
||||
uint8_t shift;
|
||||
/* Hardcoded max size of 1024. sue me. */
|
||||
for ( shift = 1;
|
||||
( 1 << shift ) < 1024 && ( 1 << shift) < size;
|
||||
( 1U << shift ) < 1024 && ( 1U << shift) < size;
|
||||
shift++
|
||||
) ;
|
||||
uint16_t tmpmask = (1 << shift) - 1;
|
||||
|
Loading…
Reference in New Issue
Block a user