Ticket #79 (closed defect: fixed)
Range check error file pwm.c line 79
| Reported by: | rmann | Owned by: | |
|---|---|---|---|
| Priority: | major | Milestone: | |
| Component: | firmware | Keywords: | |
| Cc: |
Description
Here's some context:
int Pwm_Set( int index, int duty ) {
if ( index < 0
index > PWM_COUNT ) return CONTROLLER_ERROR_ILLEGAL_INDEX;
PWM_COUNT is 4, which means this test would allow values 0 - 4 to be passed. Really the range allowed should be 0-3.
Change History
Note: See TracTickets for help on using tickets.Download in other formats:
