Skip to content

Commit

Permalink
AP_Networking: fixed build with gcc 11.x
Browse files Browse the repository at this point in the history
  • Loading branch information
tridge committed Nov 13, 2023
1 parent 725735a commit 12c82b4
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions libraries/AP_Networking/AP_Networking_tests.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ void AP_Networking::test_UDP_client(void)
while (true) {
hal.scheduler->delay(100);
char *s = nullptr;
asprintf(&s, "hello %u", unsigned(AP_HAL::millis()));
IGNORE_RETURN(asprintf(&s, "hello %u", unsigned(AP_HAL::millis())));
sock->send((const void*)s, strlen(s));
free(s);
uint8_t buf[128] {};
Expand Down Expand Up @@ -89,7 +89,7 @@ void AP_Networking::test_TCP_client(void)
while (true) {
hal.scheduler->delay(100);
char *s = nullptr;
asprintf(&s, "hello %u", unsigned(AP_HAL::millis()));
IGNORE_RETURN(asprintf(&s, "hello %u", unsigned(AP_HAL::millis())));
sock->send((const void*)s, strlen(s));
free(s);
uint8_t buf[128] {};
Expand Down

0 comments on commit 12c82b4

Please sign in to comment.