Skip to content

Commit

Permalink
Merge pull request #344 from pennam/fix_warnings
Browse files Browse the repository at this point in the history
Fix compilation warnings
  • Loading branch information
pennam committed Nov 17, 2022
2 parents 90508ac + 5ab7d89 commit 03fa885
Show file tree
Hide file tree
Showing 6 changed files with 11 additions and 8 deletions.
3 changes: 1 addition & 2 deletions src/tls/BearSSLClient.h
Original file line number Diff line number Diff line change
Expand Up @@ -90,9 +90,8 @@ class BearSSLClient : public Client {
Client* _client;
const br_x509_trust_anchor* _TAs;
int _numTAs;
GetTimeCallbackFunc _get_time_func;

bool _noSNI;
GetTimeCallbackFunc _get_time_func;

br_ec_private_key _ecKey;
br_x509_certificate _ecCert;
Expand Down
2 changes: 0 additions & 2 deletions src/tls/profile/aiotc_profile.c
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,6 @@ void aiotc_client_profile_init(br_ssl_client_context *cc, br_x509_minimal_contex
BR_TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256
};

int id;

/*
* Reset client context and set supported versions from TLS-1.0
* to TLS-1.2 (inclusive).
Expand Down
6 changes: 3 additions & 3 deletions src/tls/utility/Cert.h
Original file line number Diff line number Diff line change
Expand Up @@ -147,12 +147,12 @@ class ArduinoIoTCloudCertClass {
byte data[CERT_COMPRESSED_CERT_SLOT_LENGTH + CERT_SERIAL_NUMBER_LENGTH + CERT_AUTHORITY_KEY_ID_LENGTH];
} _compressedCert;

/* only raw EC X Y values 64 byte */
const byte * _publicKey;

byte * _certBuffer;
int _certBufferLen;

/* only raw EC X Y values 64 byte */
const byte * _publicKey;

int versionLength();
int issuerOrSubjectLength(const CertInfo& issuerOrSubjectData);
int sequenceHeaderLength(int length);
Expand Down
5 changes: 5 additions & 0 deletions src/utility/ota/OTA-samd.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,12 @@ int samd_onOTARequest(char const * ota_url)

/* Perform the reset to reboot to SxU. */
NVIC_SystemReset();

return static_cast<int>(OTAError::None);
#endif /* OTA_STORAGE_SNU */

(void)ota_url;
return static_cast<int>(OTAError::DownloadFailed);
}

#endif /* ARDUINO_ARCH_SAMD */
2 changes: 1 addition & 1 deletion src/utility/time/NTPUtils.h
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ class NTPUtils
static int const MAX_NTP_PORT = 65535;
#endif
static unsigned long const NTP_TIMEOUT_MS = 1000;
static char constexpr * NTP_TIME_SERVER = "time.arduino.cc";
static constexpr const char * NTP_TIME_SERVER = "time.arduino.cc";

static void sendNTPpacket(UDP & udp);
};
Expand Down
1 change: 1 addition & 0 deletions src/utility/watchdog/Watchdog.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -173,6 +173,7 @@ void watchdog_reset()
void watchdog_enable_network_feed(const bool use_ethernet)
{
#ifdef WIFI_HAS_FEED_WATCHDOG_FUNC
(void)use_ethernet;
WiFi.setFeedWatchdogFunc(watchdog_reset);
#endif

Expand Down

0 comments on commit 03fa885

Please sign in to comment.