aboutsummaryrefslogtreecommitdiff
path: root/networking/udhcp/packet.c
diff options
context:
space:
mode:
authorDenys Vlasenko <vda.linux@googlemail.com>2020-10-01 03:07:22 +0200
committerDenys Vlasenko <vda.linux@googlemail.com>2020-10-01 03:07:22 +0200
commit4a0eb0370c4df8ee01973b50bb460560532b79f1 (patch)
treece2324f97b05ae50355961d47dea6cd003a4fc05 /networking/udhcp/packet.c
parentaaa0709e7b39d0dc22ac92443a86c84eaff58679 (diff)
downloadbusybox-4a0eb0370c4df8ee01973b50bb460560532b79f1.tar.gz
gcc-9.x warning fixes
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'networking/udhcp/packet.c')
-rw-r--r--networking/udhcp/packet.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/networking/udhcp/packet.c b/networking/udhcp/packet.c
index 6d4375237..51374646d 100644
--- a/networking/udhcp/packet.c
+++ b/networking/udhcp/packet.c
@@ -164,14 +164,14 @@ int FAST_FUNC udhcp_send_raw_packet(struct dhcp_packet *dhcp_pkt,
packet.udp.len = htons(UDP_DHCP_SIZE - padding);
/* for UDP checksumming, ip.len is set to UDP packet len */
packet.ip.tot_len = packet.udp.len;
- packet.udp.check = inet_cksum((uint16_t *)&packet,
+ packet.udp.check = inet_cksum(&packet,
IP_UDP_DHCP_SIZE - padding);
/* but for sending, it is set to IP packet len */
packet.ip.tot_len = htons(IP_UDP_DHCP_SIZE - padding);
packet.ip.ihl = sizeof(packet.ip) >> 2;
packet.ip.version = IPVERSION;
packet.ip.ttl = IPDEFTTL;
- packet.ip.check = inet_cksum((uint16_t *)&packet.ip, sizeof(packet.ip));
+ packet.ip.check = inet_cksum(&packet.ip, sizeof(packet.ip));
udhcp_dump_packet(dhcp_pkt);
result = sendto(fd, &packet, IP_UDP_DHCP_SIZE - padding, /*flags:*/ 0,