summaryrefslogtreecommitdiff
path: root/pcap-dlpi.c
diff options
context:
space:
mode:
authorGuy Harris <gharris@steve.local>2009-07-02 12:28:51 -0700
committerGuy Harris <gharris@steve.local>2009-07-02 12:28:51 -0700
commitdcf1642930024cdc15528bfc3452a3fa4c6af27a (patch)
tree694410820d85655ed98dabe572aa3260297e0cba /pcap-dlpi.c
parentfb62fdb90234348c721558893fc9fa8cf0f97183 (diff)
downloadlibpcap-dcf1642930024cdc15528bfc3452a3fa4c6af27a.tar.gz
dlp->dl_length might be an unsigned long; cast it to unsigned long and
print it with %lu, so the code works regardless of whether it's an unsigned int or an unsigned long.
Diffstat (limited to 'pcap-dlpi.c')
-rw-r--r--pcap-dlpi.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/pcap-dlpi.c b/pcap-dlpi.c
index 335f1c7e..16fbfff5 100644
--- a/pcap-dlpi.c
+++ b/pcap-dlpi.c
@@ -1491,8 +1491,8 @@ get_dlpi_ppa(register int fd, register const char *device, register int unit,
}
if (ctl.len < dlp->dl_length) {
snprintf(ebuf, PCAP_ERRBUF_SIZE,
- "get_dlpi_ppa: hpppa ack too small (%d < %d)",
- ctl.len, dlp->dl_length);
+ "get_dlpi_ppa: hpppa ack too small (%d < %lu)",
+ ctl.len, (unsigned long)dlp->dl_length);
free(ppa_data_buf);
return (PCAP_ERROR);
}