From 208df89ab0f404144c1bd7175089e95050012d5c Mon Sep 17 00:00:00 2001 From: Dong Heng Date: Fri, 5 Mar 2021 16:33:42 +0800 Subject: [PATCH] netutils/dhcpd: Fix printf format error based on different chip arches --- netutils/dhcpd/dhcpd.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/netutils/dhcpd/dhcpd.c b/netutils/dhcpd/dhcpd.c index 494e60e2b..09ec03970 100644 --- a/netutils/dhcpd/dhcpd.c +++ b/netutils/dhcpd/dhcpd.c @@ -892,7 +892,7 @@ static inline int dhcpd_openresponder(void) int sockfd; int ret; - ninfo("Responder: %08lx\n", ntohl(g_state.ds_serverip)); + ninfo("Responder: %08" PRIx32 "\n", ntohl(g_state.ds_serverip)); /* Create a socket to listen for requests from DHCP clients */ @@ -1480,7 +1480,7 @@ static inline int dhcpd_openlistener(FAR const char *interface) g_state.ds_serverip = ((FAR struct sockaddr_in *) &req.ifr_addr)->sin_addr.s_addr; - ninfo("serverip: %08lx\n", ntohl(g_state.ds_serverip)); + ninfo("serverip: %08" PRIx32 "\n", ntohl(g_state.ds_serverip)); /* Bind the socket to a local port. We have to bind to INADDRY_ANY to * receive broadcast messages.