From 6fa16ea77fa9d1a08cf696f40fae8c07603b94d8 Mon Sep 17 00:00:00 2001 From: Mike Black W9MDB Date: Sun, 7 May 2023 17:38:45 -0500 Subject: [PATCH] Fix mingw compile warning https://github.com/Hamlib/Hamlib/issues/695 --- src/multicast.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/multicast.c b/src/multicast.c index edf3faa29..07fd910c3 100644 --- a/src/multicast.c +++ b/src/multicast.c @@ -306,7 +306,7 @@ int multicast_init(RIG *rig, char *addr, int port) // Join the multicast group if (setsockopt(rig->state.multicast->sock, IPPROTO_IP, IP_ADD_MEMBERSHIP, - &rig->state.multicast->mreq, sizeof(rig->state.multicast->mreq)) < 0) + (char*)&rig->state.multicast->mreq, sizeof(rig->state.multicast->mreq)) < 0) { rig_debug(RIG_DEBUG_ERR, "%s: setsockopt: %s\n", __func__, strerror(errno)); return -RIG_EIO; @@ -333,7 +333,7 @@ void multicast_close(RIG *rig) // Leave the multicast group if ((retval = setsockopt(rig->state.multicast->sock, IPPROTO_IP, - IP_DROP_MEMBERSHIP, &rig->state.multicast->mreq, + IP_DROP_MEMBERSHIP, (char*)&rig->state.multicast->mreq, sizeof(rig->state.multicast->mreq))) < 0) { rig_debug(RIG_DEBUG_ERR, "%s: setsockopt: %s\n", __func__, strerror(errno));