mirror of
https://github.com/arduino/Arduino.git
synced 2025-03-13 10:29:35 +01:00
avoid NPE if serial monitor is waiting too long for opening
This commit is contained in:
parent
821c665460
commit
52ef55380d
@ -2442,13 +2442,14 @@ public class Editor extends JFrame implements RunnerListener {
|
||||
}
|
||||
}
|
||||
try {
|
||||
if (serialMonitor != null)
|
||||
serialMonitor.resume(boardPort);
|
||||
if (boardPort == null) {
|
||||
serialMonitor.close();
|
||||
handleSerial();
|
||||
} else {
|
||||
if (serialMonitor != null) {
|
||||
serialMonitor.resume(boardPort);
|
||||
if (boardPort == null) {
|
||||
serialMonitor.close();
|
||||
handleSerial();
|
||||
} else {
|
||||
serialMonitor.resume(boardPort);
|
||||
}
|
||||
}
|
||||
} catch (Exception e) {
|
||||
statusError(e);
|
||||
|
Loading…
x
Reference in New Issue
Block a user