235b09c3dbc2a911c48639c01cbfe5b3447d635f hiram Wed Nov 23 16:21:51 2022 -0800 fixup correct argument to sendto() function as found on BSD system on Mac laptops refs #29651 diff --git src/lib/rudp.c src/lib/rudp.c index 05aee73..dd278a0 100644 --- src/lib/rudp.c +++ src/lib/rudp.c @@ -467,31 +467,31 @@ } if (readSize < sizeof(*head)) { warn("rudpRecieve truncated message"); continue; } if (head->type != rudpData) { if (head->type != rudpAck) warn("skipping non-data message %d in rudpReceive", head->type); continue; } ackHead = *head; ackHead.type = rudpAck; err = sendto(ru->socket, &ackHead, sizeof(ackHead), 0, - (struct sockaddr *)&sai, sizeof(sai)); + (struct sockaddr *)&sai, getSockSize6n4(&sai)); if (err < 0) { warn("problem sending ack in rudpRecieve: %s", strerror(errno)); } readSize -= sizeof(*head); if (readSize > bufSize) { warn("read more bytes than have room for in rudpReceive"); readSize = bufSize; } memcpy(messageBuf, head+1, readSize); /* check for duplicate packet */ if (!ru->recvHash) { /* take advantage of new auto-expanding hashes */