Skip to content

Commit b76af81

Browse files
committed
Merge branch 'feat/disable_ipv4_cli_ext' into 'main'
feat(ext_cli): support iperf when ipv4 is disabled See merge request espressif/esp-thread-br!177
2 parents f632a73 + 294e21e commit b76af81

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

components/esp_ot_cli_extension/src/esp_ot_iperf.c

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -118,12 +118,15 @@ otError esp_ot_process_iperf(void *aContext, uint8_t aArgsLength, char *aArgs[])
118118
}
119119
}
120120
if (client_flag) {
121+
#if CONFIG_LWIP_IPV4
121122
if (cfg.type == IPERF_IP_TYPE_IPV4) {
122123
cfg.destination_ip4 = inet_addr(s_dest_ip_addr);
123124
char ip_addr[50];
124125
strncpy(ip_addr, inet_ntoa(cfg.destination_ip4), sizeof(ip_addr));
125126
otCliOutputFormat("ip:%s\n", ip_addr);
126-
} else {
127+
} else
128+
#endif // CONFIG_LWIP_IPV4
129+
{
127130
cfg.destination_ip6 = s_dest_ip_addr;
128131
otCliOutputFormat("ip:%s\n", cfg.destination_ip6);
129132
}

0 commit comments

Comments
 (0)