Skip to content

Commit e777360

Browse files
committed
fix inconsistent error handling in receive method
1 parent 39715ab commit e777360

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

android/app/src/main/java/betaflight/configurator/plugin/SocketPlugin.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -121,6 +121,8 @@ public void receive(PluginCall call) {
121121
ret.put("data", data);
122122
call.resolve(ret);
123123
} catch (Exception e) {
124+
closeResources();
125+
isConnected = false;
124126
call.reject("Receive failed: " + e.getMessage());
125127
}
126128
});

0 commit comments

Comments
 (0)