Commit b2f92c3a authored by Jaromir Koncicky's avatar Jaromir Koncicky Committed by Bernd Eckenfels

Fix unsigned sscanf format

After coverity tool scan, some warnings about signed/unsigned conflicts in
sscanf format string were found. Not a serious problem, but better to be
correct.
parent 49329153
......@@ -491,7 +491,7 @@ static int do_tunnels_list(struct ip_tunnel_parm *p)
fclose(fp);
return -1;
}
if (sscanf(ptr, "%ld%ld%ld%ld%ld%ld%ld%*d%ld%ld%ld%ld%ld%ld%ld",
if (sscanf(ptr, "%lu%lu%lu%lu%lu%lu%lu%*u%lu%lu%lu%lu%lu%lu%lu",
&rx_bytes, &rx_packets, &rx_errs, &rx_drops,
&rx_fifo, &rx_frame, &rx_multi,
&tx_bytes, &tx_packets, &tx_errs, &tx_drops,
......
......@@ -1603,7 +1603,7 @@ static int ipx_info(void)
/* eat line */;
while (fgets(buf, 255, f) != NULL) {
sscanf(buf, "%s %s %lX %lX %d %d",
sscanf(buf, "%s %s %lX %lX %u %u",
sad, dad, &txq, &rxq, &state, &uid);
if ((st = rindex(sad, ':'))) {
*st++ = '\0';
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment