Skip to content

Commit

Permalink
fix(mdns): Allow advertizing service with port==0
Browse files Browse the repository at this point in the history
  • Loading branch information
david-cermak committed Jan 15, 2025
1 parent 9537721 commit 827ea65
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion components/mdns/mdns.c
Original file line number Diff line number Diff line change
Expand Up @@ -5895,7 +5895,7 @@ esp_err_t mdns_instance_name_set(const char *instance)
esp_err_t mdns_service_add_for_host(const char *instance, const char *service, const char *proto, const char *host,
uint16_t port, mdns_txt_item_t txt[], size_t num_items)
{
if (!_mdns_server || _str_null_or_empty(service) || _str_null_or_empty(proto) || !port || !_mdns_server->hostname) {
if (!_mdns_server || _str_null_or_empty(service) || _str_null_or_empty(proto) || !_mdns_server->hostname) {
return ESP_ERR_INVALID_ARG;
}

Expand Down

0 comments on commit 827ea65

Please sign in to comment.