diff options
author | Jean Cyr <jcyr@dillobits.com> | 2013-08-30 20:24:14 -0400 |
---|---|---|
committer | Jean Cyr <jcyr@dillobits.com> | 2013-08-30 20:24:14 -0400 |
commit | f246b68c7b53c44ae00e0f3fca724d1fbfab8f5d (patch) | |
tree | 8c205b573aa2fa527b9201d20432260839f72272 /src | |
parent | efca6f2cb1848523969c7f29abba7389e48affbc (diff) | |
download | px4-firmware-f246b68c7b53c44ae00e0f3fca724d1fbfab8f5d.tar.gz px4-firmware-f246b68c7b53c44ae00e0f3fca724d1fbfab8f5d.tar.bz2 px4-firmware-f246b68c7b53c44ae00e0f3fca724d1fbfab8f5d.zip |
Fix parameter range check
Diffstat (limited to 'src')
-rw-r--r-- | src/drivers/stm32/tone_alarm/tone_alarm.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/drivers/stm32/tone_alarm/tone_alarm.cpp b/src/drivers/stm32/tone_alarm/tone_alarm.cpp index a726247d5..262fe6e4c 100644 --- a/src/drivers/stm32/tone_alarm/tone_alarm.cpp +++ b/src/drivers/stm32/tone_alarm/tone_alarm.cpp @@ -874,7 +874,7 @@ ToneAlarm::ioctl(file *filp, int cmd, unsigned long arg) case TONE_SET_ALARM: debug("TONE_SET_ALARM %u", arg); - if (arg <= TONE_NUMBER_OF_TUNES) { + if (arg < TONE_NUMBER_OF_TUNES) { if (arg == 0) { // stop the tune _tune = nullptr; |