Small syntax fix

This commit is contained in:
Michiel Broek 2007-09-24 18:54:05 +00:00
parent 66d636d5a2
commit e14923889f

View File

@ -81,7 +81,7 @@ static int scan_dir(int (*fn)(faddr *, char, int, char *), char *dname, int ispo
strncat(fname,de->d_name,PATH_MAX-strlen(fname)-2);
if ((strcasecmp(de->d_name+9,"pnt") == 0) && !ispoint) {
sscanf(de->d_name,"%04x%04x",&t_net,&t_node);
sscanf(de->d_name,"%04hx%04hx",&t_net,&t_node);
addr.net = t_net;
addr.node = t_node;
if ((rc = scan_dir(fn, fname, 1)))
@ -103,10 +103,10 @@ static int scan_dir(int (*fn)(faddr *, char, int, char *), char *dname, int ispo
(strcasecmp(de->d_name+8,".req") == 0) ||
(strcasecmp(de->d_name+8,".pol") == 0)) {
if (ispoint) {
sscanf(de->d_name,"%08x", &t_point);
sscanf(de->d_name,"%08hx", &t_point);
addr.point = t_point;
} else {
sscanf(de->d_name,"%04x%04x", &t_net,&t_node);
sscanf(de->d_name,"%04hx%04hx", &t_net,&t_node);
addr.net = t_net;
addr.node = t_node;
}