mirror of
https://github.com/mik3y/usb-serial-for-android.git
synced 2026-08-11 16:32:53 +00:00
fixed example app crash
This commit is contained in:
+3
-1
@@ -243,8 +243,10 @@ public class TerminalFragment extends Fragment implements SerialInputOutputManag
|
||||
private void disconnect() {
|
||||
connected = false;
|
||||
controlLines.stop();
|
||||
if(usbIoManager != null)
|
||||
if(usbIoManager != null) {
|
||||
usbIoManager.setListener(null);
|
||||
usbIoManager.stop();
|
||||
}
|
||||
usbIoManager = null;
|
||||
try {
|
||||
usbSerialPort.close();
|
||||
|
||||
Reference in New Issue
Block a user