diff options
author | Cristian Maglie <c.maglie@arduino.cc> | 2015-11-11 16:28:48 +0100 |
---|---|---|
committer | Cristian Maglie <c.maglie@arduino.cc> | 2015-11-11 16:28:48 +0100 |
commit | 7bd71f04b0ad70ffb8470fb77052b7f4e0d5b91f (patch) | |
tree | 7246f20b7b04cf54ba6cee72846eb5bffac8859c /libraries/SoftwareSerial/SoftwareSerial.cpp | |
parent | ab82f330b56783704260effc94408a6f30c759e9 (diff) |
SoftwareSerial: fix flush() behaviour
Fix #4029
Diffstat (limited to 'libraries/SoftwareSerial/SoftwareSerial.cpp')
-rw-r--r-- | libraries/SoftwareSerial/SoftwareSerial.cpp | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/libraries/SoftwareSerial/SoftwareSerial.cpp b/libraries/SoftwareSerial/SoftwareSerial.cpp index 80df664..0a16ff7 100644 --- a/libraries/SoftwareSerial/SoftwareSerial.cpp +++ b/libraries/SoftwareSerial/SoftwareSerial.cpp @@ -469,13 +469,7 @@ size_t SoftwareSerial::write(uint8_t b) void SoftwareSerial::flush()
{
- if (!isListening())
- return;
-
- uint8_t oldSREG = SREG;
- cli();
- _receive_buffer_head = _receive_buffer_tail = 0;
- SREG = oldSREG;
+ // There is no tx buffering, simply return
}
int SoftwareSerial::peek()
|