diff options
author | David A. Mellis <d.mellis@arduino.cc> | 2011-09-09 16:24:47 -0400 |
---|---|---|
committer | David A. Mellis <d.mellis@arduino.cc> | 2011-09-09 16:24:47 -0400 |
commit | 023ea285e151a41725b5c072dbf1d7afd09ce966 (patch) | |
tree | 3591dc2b30ae28bf923c9146493f1a267d9b396f /cores/arduino/Stream.h | |
parent | 8b13206e655cd9c1123d842cab1fdd0afd6edc8b (diff) |
Don't consume trailing char in parseInt() and parseFloat (Paul Stoffregen).
http://code.google.com/p/arduino/issues/detail?id=624
Diffstat (limited to 'cores/arduino/Stream.h')
-rw-r--r-- | cores/arduino/Stream.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/cores/arduino/Stream.h b/cores/arduino/Stream.h index 1633f15..3c6d025 100644 --- a/cores/arduino/Stream.h +++ b/cores/arduino/Stream.h @@ -41,7 +41,8 @@ class Stream : public Print long _timeout; // number of milliseconds to wait for the next char before aborting timed read long _startMillis; // used for timeout measurement int timedRead(); // private method to read stream with timeout - int getNextDigit(); // returns the next numeric digit in the stream or -1 if timeout + int timedPeek(); // private method to peek stream with timeout + int peekNextDigit(); // returns the next numeric digit in the stream or -1 if timeout public: virtual int available() = 0; |