Skip to content

Commit 8d33a52

Browse files
committed
Add const qualifier to use_ethernet function argument
1 parent 6a10215 commit 8d33a52

File tree

4 files changed

+5
-5
lines changed

4 files changed

+5
-5
lines changed

src/utility/ota/OTA-portenta-h7.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
* FUNCTION DEFINITION
3636
******************************************************************************/
3737

38-
int portenta_h7_onOTARequest(char const * ota_url, bool use_ethernet)
38+
int portenta_h7_onOTARequest(char const * ota_url, const bool use_ethernet)
3939
{
4040
watchdog_reset();
4141

src/utility/ota/OTA.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ int rp2040_connect_onOTARequest(char const * ota_url);
6363
#endif
6464

6565
#if defined(ARDUINO_PORTENTA_H7_M7) || defined(ARDUINO_NICLA_VISION)
66-
int portenta_h7_onOTARequest(char const * ota_url, bool use_ethernet);
66+
int portenta_h7_onOTARequest(char const * ota_url, const bool use_ethernet);
6767
#endif
6868

6969
#endif /* ARDUINO_OTA_LOGIC_H_ */

src/utility/watchdog/Watchdog.cpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@ static void mbed_watchdog_reset()
122122
}
123123
}
124124

125-
static void mbed_watchdog_enable_network_feed(bool use_ethernet)
125+
static void mbed_watchdog_enable_network_feed(const bool use_ethernet)
126126
{
127127
if(use_ethernet) {
128128
#if defined(ARDUINO_PORTENTA_H7_M7)
@@ -174,7 +174,7 @@ void watchdog_reset()
174174
#endif
175175
}
176176

177-
void watchdog_enable_network_feed(bool use_ethernet)
177+
void watchdog_enable_network_feed(const bool use_ethernet)
178178
{
179179
#ifdef ARDUINO_ARCH_SAMD
180180
samd_watchdog_enable_network_feed();

src/utility/watchdog/Watchdog.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525
#if defined (ARDUINO_ARCH_SAMD) || defined (ARDUINO_ARCH_MBED)
2626
void watchdog_enable();
2727
void watchdog_reset();
28-
void watchdog_enable_network_feed(bool use_ethernet);
28+
void watchdog_enable_network_feed(const bool use_ethernet);
2929
#endif /* (ARDUINO_ARCH_SAMD) || (ARDUINO_ARCH_MBED) */
3030

3131
#ifdef ARDUINO_ARCH_MBED

0 commit comments

Comments
 (0)