Fixed some warnings flagged by IAR C-STAT static analysis tool.

This commit is contained in:
skarg
2016-01-07 21:31:38 +00:00
parent dd0fb9c841
commit 0697065030
16 changed files with 51 additions and 52 deletions
+5 -1
View File
@@ -86,7 +86,11 @@ static uint16_t rs485_turnaround_time(
/* delay after reception before transmitting - per MS/TP spec */
/* wait a minimum 40 bit times since reception */
/* at least 2 ms for errors: rounding, clock tick */
return (2 + ((Tturnaround * 1000UL) / Baud_Rate));
if (Baud_Rate) {
return (2 + ((Tturnaround * 1000UL) / Baud_Rate));
} else {
return 2;
}
}
/*************************************************************************