Skip to content

Commit d7b9a21

Browse files
authored
Merge pull request #303 from Cherisher/patch-1
fixed get_ext_iface
2 parents c905489 + cdbb9bd commit d7b9a21

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/util.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -254,7 +254,7 @@ get_ext_iface(void)
254254
}
255255
while (!feof(input)) {
256256
/* XXX scanf(3) is unsafe, risks overrun */
257-
if ((fscanf(input, "%15s %*s %15s %*s %*s %*s %*s %*s %*s %*s %*s\n", device, gw) == 2)
257+
if ((fscanf(input, "%15s %15s %*s %*s %*s %*s %*s %*s %*s %*s %*s\n", device, gw) == 2)
258258
&& strcmp(gw, "00000000") == 0) {
259259
free(gw);
260260
debug(LOG_INFO, "get_ext_iface(): Detected %s as the default interface after trying %d", device, i);

0 commit comments

Comments
 (0)