Skip to content

Commit

Permalink
Fix compiler warning on HardwareTimer (#2256)
Browse files Browse the repository at this point in the history
Signed-off-by: ldursw <[email protected]>
Co-authored-by: Frederic Pillon <[email protected]>
  • Loading branch information
ldursw and fpistm authored Jan 23, 2024
1 parent 49b8eef commit de1e1c5
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions libraries/SrcWrapper/src/HardwareTimer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -168,6 +168,10 @@ void HardwareTimer::pause()
*/
void HardwareTimer::pauseChannel(uint32_t channel)
{
if ((channel < 1) || (channel > TIMER_CHANNELS)) {
return;
}

int timAssociatedInputChannel;
int LLChannel = getLLChannel(channel);
if (LLChannel == -1) {
Expand Down

0 comments on commit de1e1c5

Please sign in to comment.