mirror of
https://github.com/lwip-tcpip/lwip.git
synced 2024-12-25 00:14:02 +00:00
Revert "Fix build warnings in mdns.c introduced in my last commit"
This reverts commit 744e69334d
.
This commit is contained in:
parent
01e227d2c0
commit
3b79c60e41
@ -1292,10 +1292,20 @@ mdns_init_outpacket(struct mdns_outpacket *out, struct mdns_packet *in)
|
|||||||
static void
|
static void
|
||||||
mdns_async_send_outpacket(void *arg)
|
mdns_async_send_outpacket(void *arg)
|
||||||
{
|
{
|
||||||
|
const ip_addr_t *mcast_destaddr;
|
||||||
struct mdns_async_outpacket *outpkt = (struct mdns_async_outpacket *)arg;
|
struct mdns_async_outpacket *outpkt = (struct mdns_async_outpacket *)arg;
|
||||||
struct pbuf *p = outpkt->pbuf;
|
struct pbuf *p = outpkt->pbuf;
|
||||||
/* Send delayed packet */
|
/* Send delayed packet */
|
||||||
LWIP_DEBUGF(MDNS_DEBUG, ("MDNS: Async sending packet len=%"U16_F"\n", p->tot_len));
|
LWIP_DEBUGF(MDNS_DEBUG, ("MDNS: Async sending packet len=%"U16_F"\n", p->tot_len));
|
||||||
|
if (IP_IS_V6_VAL(outpkt->dest_addr)) {
|
||||||
|
#if LWIP_IPV6
|
||||||
|
mcast_destaddr = &v6group;
|
||||||
|
#endif
|
||||||
|
} else {
|
||||||
|
#if LWIP_IPV4
|
||||||
|
mcast_destaddr = &v4group;
|
||||||
|
#endif
|
||||||
|
}
|
||||||
udp_sendto_if(mdns_pcb, p, &outpkt->dest_addr, outpkt->dest_port, outpkt->netif);
|
udp_sendto_if(mdns_pcb, p, &outpkt->dest_addr, outpkt->dest_port, outpkt->netif);
|
||||||
pbuf_free(p);
|
pbuf_free(p);
|
||||||
outpkt->pbuf = NULL;
|
outpkt->pbuf = NULL;
|
||||||
@ -1498,7 +1508,7 @@ mdns_send_outpacket(struct mdns_outpacket *outpkt)
|
|||||||
if (outpkt->answers > 1) {
|
if (outpkt->answers > 1) {
|
||||||
struct mdns_async_outpacket *async_outpkt;
|
struct mdns_async_outpacket *async_outpkt;
|
||||||
|
|
||||||
async_outpkt = (struct mdns_async_outpacket *)mem_malloc(sizeof(struct mdns_async_outpacket));
|
async_outpkt = mem_malloc(sizeof(struct mdns_async_outpacket));
|
||||||
if (async_outpkt) {
|
if (async_outpkt) {
|
||||||
struct pbuf *p = outpkt->pbuf;
|
struct pbuf *p = outpkt->pbuf;
|
||||||
u32_t msecs = 0;
|
u32_t msecs = 0;
|
||||||
|
Loading…
Reference in New Issue
Block a user