Repair MarlinSerial with TX-buffer

These '{' are important to avoid the redefinition of `unsigned char _sreg = SREG;`
at the same level.
Used in
```
#define CRITICAL_SECTION_START  unsigned char _sreg = SREG; cli();
```
2.0.x
AnHardt 8 years ago
parent 6b274e563d
commit 7e36b76af2

@ -244,10 +244,11 @@ void MarlinSerial::flush(void) {
}
tx_buffer.buffer[tx_buffer.head] = c;
CRITICAL_SECTION_START;
tx_buffer.head = i;
SBI(M_UCSRxB, M_UDRIEx);
CRITICAL_SECTION_END;
{ CRITICAL_SECTION_START;
tx_buffer.head = i;
SBI(M_UCSRxB, M_UDRIEx);
CRITICAL_SECTION_END;
}
return;
}

Loading…
Cancel
Save