From: Guy Harris Date: Thu, 23 Oct 2014 22:34:22 +0000 (-0700) Subject: Fix compile errors/warnings. X-Git-Tag: libpcap-1.7.0-bp~1^2~12 X-Git-Url: https://git.tcpdump.org/libpcap/commitdiff_plain/0a5aeb6a0865c8fb2b26b0ec74c72d0bef215d8f Fix compile errors/warnings. --- diff --git a/pcap-linux.c b/pcap-linux.c index 7844ce5c..a48ed40b 100644 --- a/pcap-linux.c +++ b/pcap-linux.c @@ -5530,13 +5530,15 @@ iface_ethtool_get_ts_info(pcap_t *handle, char *ebuf) static int iface_ethtool_get_ts_info(pcap_t *handle, char *ebuf _U_) { + int i; + /* * We don't have an ioctl to use to ask what's supported, * so say we support everything. */ handle->tstamp_type_count = NUM_SOF_TIMESTAMPING_TYPES; handle->tstamp_type_list = malloc(NUM_SOF_TIMESTAMPING_TYPES * sizeof(u_int)); - for (i = 0, j = 0; i < NUM_SOF_TIMESTAMPING_TYPES; i++) + for (i = 0; i < NUM_SOF_TIMESTAMPING_TYPES; i++) handle->tstamp_type_list[i] = sof_ts_type_map[i].pcap_tstamp_val; return 0; }