Skip to content

Commit

Permalink
coap_join_mcast_group_intf: fix interface selection on windows
Browse files Browse the repository at this point in the history
  • Loading branch information
anyc authored and mrdeep1 committed Oct 10, 2024
1 parent 8e407cc commit 7b4a20f
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion src/coap_net.c
Original file line number Diff line number Diff line change
Expand Up @@ -4706,7 +4706,14 @@ coap_join_mcast_group_intf_lkd(coap_context_t *ctx, const char *group_name,
}
}
}
#endif /* ! _WIN32 */
#else /* _WIN32 */
/*
* On Windows this function ignores the ifname variable so we unset this
* variable on this platform in any case in order to enable the interface
* selection from the bind address below.
*/
ifname = 0;
#endif /* _WIN32 */

/* Add in mcast address(es) to appropriate interface */
for (ainfo = resmulti; ainfo != NULL; ainfo = ainfo->ai_next) {
Expand Down

0 comments on commit 7b4a20f

Please sign in to comment.