Skip to content

Commit 228ef69

Browse files
fixup! defining a wrapper connection handler with the objective of being generic
1 parent 29b52d6 commit 228ef69

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

src/GenericConnectionHandler.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
#include "GenericConnectionHandler.h"
2020
#include "Arduino_ConnectionHandler.h"
2121

22-
void GenericConnectionHandler::updateSetting(const models::NetworkSetting& s) {
22+
bool GenericConnectionHandler::updateSetting(const models::NetworkSetting& s) {
2323
// FIXME do not allocate a conn handler when update settings cannot work
2424
switch(s.type) {
2525
#if defined(BOARD_HAS_WIFI)
@@ -66,10 +66,10 @@ void GenericConnectionHandler::updateSetting(const models::NetworkSetting& s) {
6666

6767
default:
6868
Debug.print(DBG_ERROR, "Network adapter not supported by this platform: %d", s.type);
69-
return;
69+
return false;
7070
}
7171
_interface = s.type;
72-
_ch->updateSetting(s);
72+
return _ch->updateSetting(s);
7373
}
7474

7575
NetworkConnectionState GenericConnectionHandler::update_handleInit() {

src/GenericConnectionHandler.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ class GenericConnectionHandler : public ConnectionHandler
4242
Client & getClient() override;
4343
UDP & getUDP() override;
4444

45-
void updateSetting(const models::NetworkSetting& s) override;
45+
bool updateSetting(const models::NetworkSetting& s) override;
4646

4747
protected:
4848

0 commit comments

Comments
 (0)