Fixed potential illegal read from UART queue after clear.

This commit is contained in:
Florian Nücke
2020-09-19 18:33:33 +02:00
parent 1f99a2eade
commit f0212ddb98

View File

@@ -392,7 +392,7 @@ public final class UART16550A implements Resettable, Steppable, MemoryMappedDevi
}
if (forceClear || (value & UART_FCR_XFR) != 0) {
synchronized (transmitFifo) {
lsr |= UART_LSR_THRE;
lsr |= UART_LSR_THRE | UART_LSR_TEMT;
transmitInterruptPending = true;
transmitFifo.clear();
}