Only send "Data Written" events if enabled by user
This commit is contained in:
parent
d03189929b
commit
54fba1c9f4
|
@ -1171,7 +1171,8 @@ public final class SerialPort
|
|||
}
|
||||
case LISTENING_EVENT_DATA_WRITTEN:
|
||||
{
|
||||
userDataListener.serialEvent(new SerialPortEvent(SerialPort.this, LISTENING_EVENT_DATA_WRITTEN));
|
||||
if ((eventFlags & LISTENING_EVENT_DATA_WRITTEN) > 0)
|
||||
userDataListener.serialEvent(new SerialPortEvent(SerialPort.this, LISTENING_EVENT_DATA_WRITTEN));
|
||||
break;
|
||||
}
|
||||
default:
|
||||
|
|
Loading…
Reference in New Issue