CppCheck cleanup (#975)
* Add support for inline cppcheck suppressions * Clean out all known cppcheck issues * Terminate toll-gate on found cppcheck issues
This commit is contained in:
committed by
Thomas Mørch
parent
e2ac85afbb
commit
2d5404de97
@@ -30,9 +30,9 @@
|
||||
// private method to read stream with timeout
|
||||
int Stream::timedRead()
|
||||
{
|
||||
int c;
|
||||
_startMillis = millis();
|
||||
do {
|
||||
int c;
|
||||
c = read();
|
||||
if(c >= 0) {
|
||||
return c;
|
||||
@@ -45,9 +45,9 @@ int Stream::timedRead()
|
||||
// private method to peek stream with timeout
|
||||
int Stream::timedPeek()
|
||||
{
|
||||
int c;
|
||||
_startMillis = millis();
|
||||
do {
|
||||
int c;
|
||||
c = peek();
|
||||
if(c >= 0) {
|
||||
return c;
|
||||
@@ -61,8 +61,8 @@ int Stream::timedPeek()
|
||||
// discards non-numeric characters
|
||||
int Stream::peekNextDigit()
|
||||
{
|
||||
int c;
|
||||
while(1) {
|
||||
int c;
|
||||
c = timedPeek();
|
||||
if(c < 0) {
|
||||
return c; // timeout
|
||||
|
||||
Reference in New Issue
Block a user