wmifinfo: Fix -Wformat compiler warnings.

This commit is contained in:
Doug Torrance 2014-12-08 21:01:54 -06:00 committed by Carlos R. Mafra
parent e6cd763cba
commit e34aacbd37
2 changed files with 3 additions and 2 deletions

View file

@ -65,7 +65,7 @@ int nwn_get_link(char *ifname)
if((inbssid == 1) &&
(strcmp(key, "Quality") == 0)) {
sscanf(val, "%X", &link);
sscanf(val, "%X", (unsigned int *) &link);
link *= 4;
inbssid = 0;
}

View file

@ -512,7 +512,8 @@ int getifinfo(char *ifname, struct ifinfo_t *info)
fseek(froute, 0, 0);
while(fgets(buf, sizeof(buf), froute)) {
sscanf(buf, "%s %x %x", a, &b, &c);
sscanf(buf, "%s %x %x", a, (unsigned int *) &b,
(unsigned int *) &c);
if((strcmp(a, info->id) == 0) && (b == 0)) {
info->gw = c;